Home   News  Product reviews  Website reviews  Forums   Competitions  Subscribe 


Web Building >> Web design & build
 |  Print Topic
Jump to first unread post. Pages: 1
Terborch
regular


Reg'd: Thu
Posts: 29
Linking pics from a gallery site to a forum
      #372655 - Sun Nov 18 2007 09:36 PM

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 ? "&amp;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="&lt;a href="http://img220.imageshack.us/my.php?image=downloadwwwyg0.gif" target="_blank"&gt;&lt;img
src="http://img220.imageshack.us/img220/4869/downloadwwwyg0.th.gif" border="0"
alt="Free
Image Hosting at www.ImageShack.us" /&gt;&lt;/a&gt;" /> 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)


Post Extras: Print Post   Remind Me!   Notify Moderator  
predator
regular


Reg'd: Sun
Posts: 533
Re: Linking pics from a gallery site to a forum [Re: Terborch]
      #372700 - Mon Nov 19 2007 11:09 AM

Its a bit fiddly but it is possible for users to do it. In firefox right click the image and select properties and it gives you the full URL for the image.



Post Extras: Print Post   Remind Me!   Notify Moderator  
dandesign
regular


Reg'd: Tue
Posts: 32
Loc: South Yorkshire
Re: Linking pics from a gallery site to a forum [Re: predator]
      #372776 - Mon Nov 19 2007 08:54 PM

Quote:

Its a bit fiddly but it is possible for users to do it. In firefox right click the image and select properties and it gives you the full URL for the image.






I agree. That is a LOT of code when it could be made so much more simple, well said!


Post Extras: Print Post   Remind Me!   Notify Moderator  
Pages: 1

Rate this topic

Jump to


Extra information
0 registered and 5 anonymous users are browsing this forum.

Moderator:  putasolutions, Joe_London, greysts, bricat, Nanook, Hello_There, John_McKenna, Mouse, TheFatControlleR, kimhollamby 


Print Topic

Forum Permissions
      You cannot start new topics
      You cannot reply to topics
      HTML is disabled
      Mark-up is enabled

Rating:
Topic views: 0

Contact Us | Privacy statement Main website