forum.coppermine-gallery.net

Support => cpg1.5.x Support => cpg1.5 miscellaneous => Topic started by: steveski on October 15, 2010, 12:59:19 am

Title: Force absolute URLs for thumbnails.php
Post by: steveski on October 15, 2010, 12:59:19 am
Is there a way to force all thumbnail URLs to be absolute and not relative?  Not sure which file/template to change to do this.  (I realize it is probably a hack).

I want it to be

src="http://www.noizemag.com/photos/albums/2010_Events/MRNY_BBCM/thumb_mrny_bbcm2010_07_5949.jpg"

instead of

src = "albums/2010_Events/MRNY_BBCM/thumb_mrny_bbcm2010_07_5949.jpg"
Title: Re: Force absolute URLs for thumbnails.php
Post by: Αndré on October 15, 2010, 11:05:25 am
Open include/functions.inc.php, find
Code: [Select]
$pic_url = get_pic_url($row, 'thumb');and replace with
Code: [Select]
$pic_url = $CONFIG['ecards_more_pic_target'].get_pic_url($row, 'thumb');
Title: Re: Force absolute URLs for thumbnails.php
Post by: steveski on October 15, 2010, 05:23:04 pm
Thank you!  Worked perfectly.  This also fixes the Facebook problem of not embedding photo thumbnails when linking to a Coppermine album from Facebook.
Title: Re: Force absolute URLs for thumbnails.php
Post by: Αndré on October 15, 2010, 05:46:19 pm
Please mark your thread as solved: http://forum.coppermine-gallery.net/index.php/topic,55415.msg270631.html#msg270631