Previous Thread
Next Thread
Print Thread
Rate Thread
#283146 01/18/2005 1:15 PM
Joined: Dec 2004
Posts: 36
N
nosleep Offline OP
Junior Member
OP Offline
Junior Member
N
Joined: Dec 2004
Posts: 36
some users complain that links structured like the example below will not show the image, but the full url only.

Question: is there any way that I could make image links like this show the actual image on 6.5 ? I would be most grateful for a solution.

[image]http://chatmenude.com/plaza/gallery/wm.php?pid=5595&mode=fullsize[/im
age]

The image shows fine when called in a browser window, but not between the [image] tags.

Last edited by nosleep; 01/18/2005 1:16 PM.

nosleep
Sponsored Links
Joined: Aug 2004
Posts: 173
D
Member
Offline
Member
D
Joined: Aug 2004
Posts: 173
[image][/image]

Your closing tag is wrong. It needs to be as above

Joined: Dec 2004
Posts: 36
N
nosleep Offline OP
Junior Member
OP Offline
Junior Member
N
Joined: Dec 2004
Posts: 36
[img]http://chatmenude.com/plaza/gallery/wm.php?pid=5595&mode=fullsize[/img]

no, that is not the reason. See yourself.


nosleep
Joined: Aug 2004
Posts: 173
D
Member
Offline
Member
D
Joined: Aug 2004
Posts: 173
[]http://www.parentforum.org/images/eric.gif[/]

The above works


I think you have link pictures disabled. I can't remember how to change that, I will try and find out if no one else answer before me

Last edited by dparvin; 01/19/2005 2:50 AM.
Joined: Jul 2001
Posts: 808
Coder
Offline
Coder
Joined: Jul 2001
Posts: 808
.php is not a image you try to display a script generated image, not the image itself.

Sponsored Links
Joined: Dec 2004
Posts: 36
N
nosleep Offline OP
Junior Member
OP Offline
Junior Member
N
Joined: Dec 2004
Posts: 36
yes, the link is php, and not an image. But that link displays fine in a phpbb2 forum and shows the image. There must be a way to have that working in UBB too?


nosleep
Joined: Aug 2004
Posts: 173
D
Member
Offline
Member
D
Joined: Aug 2004
Posts: 173
This is what I see when I look at the properties of that picture

Code
 The image “http://chatmenude.com/plaza/gallery/wm.php?pid=5595&mode=fullsize” cannot be displayed, because it contains errors. 


Do you have another picture?

Joined: Dec 2004
Posts: 36
N
nosleep Offline OP
Junior Member
OP Offline
Junior Member
N
Joined: Dec 2004
Posts: 36


nosleep
Joined: Sep 2003
Posts: 488
Code Monkey
Offline
Code Monkey
Joined: Sep 2003
Posts: 488
Yeah you'll need to hack Threads for that. Here's what you do...

In ubbt.inc.php:

CHANGE THIS:

Code
    // ---------------------<br />    // Convert image markup <br />       if ($config['allowimages']) {<br />          if (!preg_match("/(\[IMG\]|\[{$ubbt_lang['TEXT_IMAGE']}\])(.*?)(\?|\"|')(.*?)(\[\/IMG\]|\[\/{$ubbt_lang['TEXT_IMAGE']}\])/",$Body)) {<br />             $Body = preg_replace("/(\[IMG\]|\[{$ubbt_lang['TEXT_IMAGE']}\])http([^\[]*)\.(gif|jpg|png)(\[\/IMG\]|\[\/{$ubbt_lang['TEXT_IMAGE']}\])/i","<img src=\"http\\2.\\3\">",$Body);<br />          }<br />       }  


TO THIS:

Code
    // ---------------------<br />    // Convert image markup <br />       if ($config['allowimages']) {<br />          if (!preg_match("/(\[IMG\]|\[{$ubbt_lang['TEXT_IMAGE']}\])(.*?)(\"|')(.*?)(\[\/IMG\]|\[\/{$ubbt_lang['TEXT_IMAGE']}\])/",$Body)) {<br />             $Body = preg_replace("/(\[IMG\]|\[{$ubbt_lang['TEXT_IMAGE']}\])http([^\[]*)\.(.*?)(\[\/IMG\]|\[\/{$ubbt_lang['TEXT_IMAGE']}\])/i","<img src=\"http\\2.\\3\">",$Body);<br />          }<br />       }  

Joined: Dec 2004
Posts: 36
N
nosleep Offline OP
Junior Member
OP Offline
Junior Member
N
Joined: Dec 2004
Posts: 36
absolutely wonderful Twisty, I owe you one. Works great


nosleep
Sponsored Links
Joined: Nov 2001
Posts: 10,369
I type Like navaho
Offline
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Ack - be dealthy careful with that.... allowing people to link to scripts is a big security risk. That's why threads restricts it to real .gif, .jpg and .png files. This site was hacked last week as a result of something similar.


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
badfrog
badfrog
somewhere on the coast of Maine
Posts: 94
Joined: March 2007
Forum Statistics
Forums63
Topics37,557
Posts293,856
Members13,847
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,819
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 70
Gizmo 16
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2021 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Snapshot build 20210915)
Responsive Width:

PHP: 7.3.29 Page Time: 0.019s Queries: 37 (0.011s) Memory: 0.8342 MB (Peak: 0.9034 MB) Data Comp: Zlib Server Time: 2021-11-27 05:49:43 UTC
Valid HTML 5 and Valid CSS