Site Info Open forum for the discussion of the S2K International site and organization. If you like what we're doing, post it here. If you don't, post it here too. Get answers to site related questions.

How to link pictures?

Thread Tools
 
Old Mar 22, 2008 | 01:40 PM
  #1  
RedUn's Avatar
Thread Starter
Registered User
 
Joined: Feb 2006
Posts: 2,699
Likes: 1
From: North West
Default How to link pictures?

Hi,

I've searched everywhere before I made a new thread but I'm just having no luck

How do I link a picture from my gallery on here to another site so it shows as an image not a URL?

I've played around with all sorts and still can't figure it out.

TIA
Rick
Reply
Old Mar 24, 2008 | 03:12 AM
  #2  
AquilaEagle's Avatar
Administrator
Gold Member (Premium)
20 Year Member
Liked
Loved
Community Favorite
 
Joined: Jan 2002
Posts: 95,183
Likes: 69
From: Heath & Reach, Beds, UK
Default

Rick click on the picture until you JUST get the pic, I think it is 3 clicks in all. Use that URL.

Some sites (other fora) sometimes don't like it as it is a dynamic url. Show me which pic you want as an example and I can demo.
Reply
Old Mar 24, 2008 | 09:41 AM
  #3  
RedUn's Avatar
Thread Starter
Registered User
 
Joined: Feb 2006
Posts: 2,699
Likes: 1
From: North West
Default

Tried that Ian, I've tried the URL from the window that opens up when you do 3 full clicks with still no luck.

Any out of my gallery will do.

This is what I have used on another site with no luck without the spaces obviously

[ I M G ]https://www.s2ki.com/forums/index.php?act=module&module=gallery&cmd=viewimage& img=508626[ / I M G ]
Reply
Old Mar 24, 2008 | 09:45 AM
  #4  
RedUn's Avatar
Thread Starter
Registered User
 
Joined: Feb 2006
Posts: 2,699
Likes: 1
From: North West
Default

Obviously that works on here but on another site it doesn't seem to see image 508626 as a picture and just posts the url like above, I guess it's because theres no .jpg on the end but even adding one on doesn't do anything
Reply
Old Mar 24, 2008 | 10:07 AM
  #5  
AquilaEagle's Avatar
Administrator
Gold Member (Premium)
20 Year Member
Liked
Loved
Community Favorite
 
Joined: Jan 2002
Posts: 95,183
Likes: 69
From: Heath & Reach, Beds, UK
Default

Yep. it will be the way the other site is configured catch me on msn
Reply
Old Mar 24, 2008 | 10:17 AM
  #6  
AquilaEagle's Avatar
Administrator
Gold Member (Premium)
20 Year Member
Liked
Loved
Community Favorite
 
Joined: Jan 2002
Posts: 95,183
Likes: 69
From: Heath & Reach, Beds, UK
Default

OK here is the answer

They are using phpbb (which is horrid, but free )

phpbb doesn't allow dynamic images to be posted in [img] tags, only static ones (with certain extensions like .jpg .gif .phg etc...)

But it isn't that hard to change it to make php as an allowed extension.

The person who takes care of the site will need to do the following to enable it:

search for this line in includes/bbcode.php

Code:
// [img]image_url_here[/img] code..
$text = preg_replace("#\[img\]((http|ftp|https|ftps)://)([^ \?&=\#\"\n\r\t<]*?(\.(jpg|jpeg|gif|png)))\[/img\]#sie", "'[img:$uid]\\1' . str_replace(' ', '%20', '\\3') . '[/img:$uid]'", $text);
and add php as extension to the regular expression:
Code:
// [img]image_url_here[/img] code..
$text = preg_replace("#\[img\]((http|ftp|https|ftps)://)([^ \?&=\#\"\n\r\t<]*?(\.(jpg|jpeg|gif|png|php)))\[/img\]#sie", "'[img:$uid]\\1' . str_replace(' ', '%20', '\\3') . '[/img:$uid]'", $text);
HTH
Reply
Old Mar 24, 2008 | 10:32 AM
  #7  
RedUn's Avatar
Thread Starter
Registered User
 
Joined: Feb 2006
Posts: 2,699
Likes: 1
From: North West
Default

Cheers Ian, i'll get onto it

Rick
Reply
Related Topics
Thread
Thread Starter
Forum
Replies
Last Post
Bakafish
Site Info
2
Feb 21, 2012 10:43 AM
TheStoat
Site Info
3
Dec 11, 2007 07:00 PM
Zeph
Site Info
9
Jan 18, 2006 12:14 PM
Mindcore
Site Info
6
Feb 12, 2003 04:51 PM
Eze8199
Site Info
2
Jun 15, 2001 04:09 PM




All times are GMT -8. The time now is 11:47 AM.