my pictures on another server(was doing it in 1.3.2) my pictures on another server(was doing it in 1.3.2)
 

News:

CPG Release 1.6.27
change DB IP storage fields to accommodate IPv6 addresses
remove use of E_STRICT (PHP 8.4 deprecated)
update README to reflect new website
align code with new .com CPG website
correct deprecation in captcha

Main Menu

my pictures on another server(was doing it in 1.3.2)

Started by mbu10, April 18, 2006, 01:30:55 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

mbu10

well i was running 1.3.2 and decided to do a upgrade to newest one
anyway i used to run a modified code in the function.php so that all the pictures were stored on my other web server(but no php support)
but have massive bandwidth
looking to get this config back in could some one help me
i tried swopping the functions file over but that did not work
thanks

saw this in the code looks like could be changed any way how

// Return the url for a picture, allows to have pictures spreaded over multiple servers

/**
* get_pic_url()
*
* Return the url for a picture
*
* @param array $pic_row
* @param string $mode
* @param boolean $system_pic
* @return string
**/

function& get_pic_url(&$pic_row, $mode,$system_pic = false)
{
        global $CONFIG,$THEME_DIR;

        static $pic_prefix = array();
        static $url_prefix = array();

        if (!count($pic_prefix)) {
                $pic_prefix = array(
                        'thumb' => $CONFIG['thumb_pfx'],
                        'normal' => $CONFIG['normal_pfx'],
                        'fullsize' => ''
                );

                $url_prefix = array(
                        0 => $CONFIG['fullpath'],
                );
        }

        $mime_content = cpg_get_type($pic_row['filename']);
        $pic_row = array_merge($pic_row,$mime_content);

        $filepathname = null;

mbu10

well i have manged to alter the code so that ,my full size pictures are on another server and my thumbnails are as well
but have not manged to figure out yet how to move the normal ones
bit of help on this last bit would be good
thanks

arthurn

That would be great for me too! Can you tell me how you did that?
thanks.

Joachim Müller