About URLs in Coppermine About URLs in Coppermine
 

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

About URLs in Coppermine

Started by cdrake, April 07, 2005, 12:16:59 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

cdrake

Ive noticed that it produces urls like displayimage.php?pos=-2722 and ?album=50&pos=34 which both go to the same page. If I delete an image from an image from an album, with the url then change to ?album=50&pos=33 & displayimage.php?pos=-2721? Or would they remain the same?

If they change is there a way to make it where they will not and can you force coppermine to use either displayimage.php?pos=-2722 or ?album=50&pos instead of using both?

Thanks.

kmax

If you delete an image from an album, the url that is shown as 'displayimage.php?album=50&pos=34' will indeed change for images that were after the one you deleted in the album.  In that case the pos value is the image's relative position in the album.  However, the url formed as 'displayimage.php?pos=-2721' will not change no matter what is done in deleting other images.  In this case the pos value in the url is actually the unique picture id which is unique throughout the gallery and will not change.  If you want to have a link to a particular image to put elsewhere on your site or to post on other sites, use the 'displayimage.php?pos=-2721' format since it will not change. 

cdrake

#2
How can you change coppermine to just use 'displayimage.php?pos=-2721'?

I tried changing {LINK_TGT} to '{LINK_TGT}' => "displayimage.php?pos=-".$CURRENT_PIC_DATA['pid']."", but it just returns links like http://www.drakeshangout.com/gallery/displayimage.php?pos=-

"displayimage.php?pos=-$pic_id", doesnt work either.

kmax

Not exactly sure why you are wanting to do this.  The method you are trying to use could be made to work so that it would get the pic id properly, however I am unsure if it would break anything further along as users continued viewing other images and such.  I will defer to someone who has more experience with the Coppermine code on the question of changing something like this so as not to give you bad information. 

cdrake

#4
I am wanting to do this so there will only be one link to an image and improved search engine ranking. Also when other websites/forums post a link they always copy the address bar and paste it but if i ever delete an image then the link will point to something else.

cdrake

How could it be "made" to work?

Joachim Müller

currently: not at all, unless you sacrifice all meta albums. There's a reason why pics can be accessed using two different ways in the URL. We would have removed the option if it was that easy anyway.

Joachim