I have a gallery site (http://terborch.cyberspeed.org/gallery/index.php ) and I want to
have users be able to be able to link the pics there to
there site/forum/blog etc kinda like on:
http://imageshack.us . The gallery I'm using is http://coppermine-gallery.net/
and it uses PHP & MYSQL. Here is part of the displayimage.php code that while display the image and info.
Code:
// Create the absolute URL for display in info
$info[$lang_picinfo['URL']] = '<a href="' . $CONFIG["ecards_more_pic_target"] .
(substr($CONFIG["ecards_more_pic_target"], -1) == '/' ? '' : '/') .basename($_SERVER['PHP_SELF']) . "?pos=-$CURRENT_PIC_DATA[pid]" . '" >' . $CONFIG["ecards_more_pic_target"] .
(substr($CONFIG["ecards_more_pic_target"], -1) == '/' ? '' : '/') . basename($_SERVER['PHP_SELF']) . "?pos=-$CURRENT_PIC_DATA[pid]" . '</a>';
// with subdomains the variable is $_SERVER["SERVER_NAME"]
does not return the right value instead of using a new config variable I reused $CONFIG["ecards_more_pic_target"]
no trailing slash in the configure
// Create the add to fav link
$ref = $REFERER ? "&ref=$REFERER" : '';
if (!in_array($CURRENT_PIC_DATA['pid'], $FAVPICS)) {
$info[$lang_picinfo['addFavPhrase']] = "
<a href=\"addfav.php?pid=" . $CURRENT_PIC_DATA['pid'] . $ref . "\" >" . $lang_picinfo['addFav'] . '</a>';
} else {
$info[$lang_picinfo['addFavPhrase']] = "
<a href=\"addfav.php?pid=" . $CURRENT_PIC_DATA['pid'] . $ref . "\" >" . $lang_picinfo['remFav'] . '</a>';
}
Here is a imageshack.us code to show what I want to add/integrate into the code above. Code:
</p><input type="text" onClick='highlight(this);' style="width: 500px" size="70" value="<a href="http://img220.imageshack.us/my.php?image=downloadwwwyg0.gif" target="_blank"><img
src="http://img220.imageshack.us/img220/4869/downloadwwwyg0.th.gif" border="0"
alt="Free
Image Hosting at www.ImageShack.us" /></a>" /> Thumbnail for Websites <br /><input type="text" onClick='highlight(this);'
style="width: 500px" size="70" value="[URL=http://img220.imageshack.us/my.php?image=downloadwwwyg0.gif]
[IMG]http://img220.imageshack.us/img220/4869/downloadwwwyg0.th.gif[/IMG][/URL]" />
Thumbnail for forums (1)<br /><input type="text" onClick='highlight(this);' style="width: 500px" size="70" value="[url=http://img220.imageshack.us/my.php?image=downloadwwwyg0.gif]
[img=http://img220.imageshack.us/img220/4869/downloadwwwyg0.th.gif][/url]" /> Thumbnail for forums (2)<br /><input type="text" onClick='highlight(this);' style="width: 300px" size="70"
value="Thanks to ImageShack for [URL=http://imageshack.us]Free Image Hosting[/URL]" /> Link back to ImageShack or use the
<a href="http://reg.imageshack.us/content.php?page=linkto">
<b>banners and buttons</b>
Can anyone help?
Edited by Terborch (Sun Nov 18 2007 09:49 PM)