Advanced search  

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]

Pages: [1]   Go Down

Author Topic: "Bookmark Image" fix?  (Read 3306 times)

0 Members and 1 Guest are viewing this topic.

alphasix

  • Coppermine newbie
  • Offline Offline
  • Posts: 1
"Bookmark Image" fix?
« on: November 29, 2003, 02:20:48 am »

I am using the PHP-Nuke coppermine 1.2RC4 version on a BSD box with Apache (I'm not sure any of that will make a difference, but included just in case.)

Anyway, since upgrading to 1.2 I have had problems with the "Bookmark Image" link in that is would send a broken URL for the picture due to a malformed HTTP link, it would look something like this:

Code: [Select]
http://www.mysite.commodules.php?name=coppermine&file=displayimage&pos=-128

instead of:

Code: [Select]
http://www.mysite.com[b]/[/b]modules.php?name=coppermine&file=displayimage&pos=-128

I finally interested enough to attempt to remedy this:

in displayimage.php look for the following (line 290 for me)
Code: [Select]
$info["URL"] = <<<JSCT
<a href="{$CONFIG["ecards_more_pic_target"]}$CPG_URL&file=displayimage&pos=-{$CURRENT_PIC_DATA["pid"]}"
onClick="addBookmark('{$CURRENT_PIC_DATA["filename"]}','{$CONFIG["ecards_more_pic_target"]}$CPG_URL&file=displayimage&pos=-{$CURRENT_PIC_DATA["pid"]}');return false">{$lang_picinfo"bookmark_page"]}</a>
JSCT;


and change it to the following:

Code: [Select]

                    $info["URL"] = <<<JSCT
<a href="{$CONFIG["ecards_more_pic_target"]}/$CPG_URL&file=displayimage&pos=-{$CURRENT_PIC_DATA["pid"]}"
onClick="addBookmark('{$CURRENT_PIC_DATA["filename"]}','{$CONFIG["ecards_more_pic_target"]}/$CPG_URL&
file=displayimage&pos=-{$CURRENT_PIC_DATA["pid"]}');return false">{$lang_picinfo["bookmark_page"]}</a>
JSCT;


The only changes I made to the code: I added the "/" before $CPG_URL in both occurences.


Has anyone else had this problem with Bookmarking images?
Logged

DJMaze

  • VIP
  • Coppermine addict
  • ***
  • Offline Offline
  • Posts: 831
    • Dragonfly CMS
"Bookmark Image" fix?
« Reply #1 on: November 29, 2003, 03:29:09 am »

Nope because our ecards_more_pic_target in the coppermine config has a "/" at the end so our config screen should say:

http://www.mysite.com/

and not like yours:

http://www.mysite.com
Logged
There are 2 kinds of users in this world: satisfied and complainers.
Why do we never hear something from the satisfied users?
http://coppermine-gallery.net/forum/index.php?topic=24315.0
Pages: [1]   Go Up
 

Page created in 0.017 seconds with 19 queries.