Some PHP Moidifcation issues Some PHP Moidifcation issues
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Some PHP Moidifcation issues

Started by BenWells, March 22, 2005, 07:37:25 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

BenWells

Hey all,

First, thanks for the great looking work on this script, from what I've seen so far it's great.  I've got in installed, and am currently trying to integrate my site's header.php

I made my own theme folder, copied the files from an existing theme, and made the changes liste :  http://coppermine.sourceforge.net/faq.php#customHeader

Unforutunately after I make the changes listed there, I end up with the following error:  Parse error: parse error, unexpected '(', expecting ',' or ';' in /hsphere/local/home2/benjamin/ofuabduction.com/album/themes/ofu/theme.php on line 821

any thoughts?  If you need to see the site in question, see http://www.ofuabduction.com/index.php  and the header can be found @ http://www.ofuabduction.com/includes/header.php

Thanks,

Ben

kegobeer

Posting a link to the header doesn't really help, especially since the error is in your theme.php file.  (Can't see the code anyway, since the php is executed)  Post a few lines above and a few lines below line 821 in your theme.php file.  If that's the custom header section, just post the entire custom header section.
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

BenWells

Hmmm, ok, the issue that doesn't add up is that line 821 wasn't modified, the only modifcations I made were exactly as lited on the above FAQ link.   Here are the lines around 821:

<!-- BEGIN input_box_no_smilies -->
                                <input type="text" class="textinput" id="message" name="msg_body"  maxlength="{MAX_COM_LENGTH}" style="width: 100%;" />
<!-- END input_box_no_smilies -->


The custom header section is line 944, but I'll show you how it reads anyway:

function pageheader($section, $meta = '')
{
   global $CONFIG, $THEME_DIR;
   global $template_header, $lang_charset, $lang_text_dir;

   if(empty($custom_header)){
      include('http://www.ofuabduction.com/includes/header.php');
      static $custom_header = ob_get_contents();
      ob_clean();
   }

   header('P3P: CP="CAO DSP COR CURa ADMa DEVa OUR IND PHY ONL UNI COM NAV INT DEM PRE"');
   user_save_profile();

   $template_vars = array(
      '{LANG_DIR}' => $lang_text_dir,
      '{TITLE}' => $CONFIG['gallery_name'].' - '.$section,
      '{CHARSET}' => $CONFIG['charset'] == 'language file' ? $lang_charset : $CONFIG['charset'],
      '{META}' => $meta,
      '{GAL_NAME}' => $CONFIG['gallery_name'],
      '{GAL_DESCRIPTION}' => $CONFIG['gallery_description'],
      '{MAIN_MENU}' => theme_main_menu(),
      '{ADMIN_MENU}' => theme_admin_mode_menu(),
      '{CUSTOM_HEADER}' => $custom_header,
   );

   echo template_eval($template_header, $template_vars);
}




Thanks,

Ben

kegobeer

Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots