Problem with Index.php Problem with Index.php
 

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

Problem with Index.php

Started by Vujo91, April 18, 2006, 07:21:15 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Vujo91

Hello!

I'm install cpg1.4.4 and I have one problem!  http://www.beyonce-photos.com

I put index.htm to be first page and rename index.php to index1.php and, in admin mod, I setup first (home page) for coppermine is index1.php!

Everything work good except one thing!  :'(

When I go to view picture  (displayimage.php)  when click on menu up of pic, that call index.phpxxxx and "The page cannot be displayed"

How can I solve this problem?  Please help me!!

Thanks a lot!!           


Sorry for my English
Best DJ ...ever

Stramm

index.php is still hardcoded into functions.inc.php, moving this thread to the bugs board

fix:
in functions.inc.php find
        // Add the Home link  to breadcrumb
        $breadcrumb_links[0] = '<a href="index.php">'.$lang_list_categories['home'].'</a>';
        $BREADCRUMB_TEXTS[0] = $lang_list_categories['home'];

        $cat_order = 1;
        foreach ($category_array as $category)
        {
            $breadcrumb_links[$cat_order] = "<a href=\"index.php?cat={$category[0]}\">{$category[1]}</a>";
            $BREADCRUMB_TEXTS[$cat_order] = $category[1];
            $cat_order += 1;
        }

and replace with
        // Add the Home link  to breadcrumb
        $breadcrumb_links[0] = '<a href="'.$CONFIG['home_target'].'">'.$lang_list_categories['home'].'</a>';
        $BREADCRUMB_TEXTS[0] = $lang_list_categories['home'];

        $cat_order = 1;
        foreach ($category_array as $category)
        {
            $breadcrumb_links[$cat_order] = "<a href=\"".$CONFIG['home_target']."?cat={$category[0]}\">{$category[1]}</a>";
            $BREADCRUMB_TEXTS[$cat_order] = $category[1];
            $cat_order += 1;
        }

Vujo91


    Thanks a lot!   Now work great!!


   kiss  ::)
Best DJ ...ever

Vujo91

#3
Hey!  :o :o

I found new problem!   Help me!!!   In Menu Album list is steal linked on index.php not on index1.php

Look on the picture from attachmant!

Help me to solving this problem!!  Thanks a lot!   ;)
Best DJ ...ever

Stramm

hmm... after having a closer look... I've seen that this'll mean modifiying code all over the place.
Refering to the docs the functionality of 'URL of your home page' is not top change coppermine's index but where the 'home' button is linking to.

Still it's possible to modify the code so this function is setting coppemine's index. For that search all occurances of 'index.php' in the code and replace them with '$CONFIG['home_target']'
if index.php is in an heredoc (<<<) you may wish to put $CONFIG['home_target'] in brackets ({})

make backups of the files you modify and test after each modification. Good luck

Joachim Müller

this is not an actual bug imo. The user-settable "home" link can be anything, it is not related to the breadcrumb nav.

@Vujo91: use .htaccess to make another file the index file in coppermine's folder. Leave coppermine as is.

Vujo91

Quote from: GauGau on April 19, 2006, 10:09:20 AM
this is not an actual bug imo. The user-settable "home" link can be anything, it is not related to the breadcrumb nav.

@Vujo91: use .htaccess to make another file the index file in coppermine's folder. Leave coppermine as is.

I put .htaccess in root and solve the problem!!

Thanks a lot everyone!
Best DJ ...ever