[Solved]: link in the descriptiontext of an album [Solved]: link in the descriptiontext of an album
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

[Solved]: link in the descriptiontext of an album

Started by doggystyle, July 19, 2004, 06:36:42 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

doggystyle

i would like to change that a link wich is clicked in the description text of an album opens in the same window and not in a new one. wich file i have to modify?

greets

doggy

Joachim Müller

edit displayimage.php, find        $pic_html = "<a href=\"{$picture_url}\" target=\"_blank\" class=\"document_link\"><img src=\"".$pic_thumb_url."\" border=\"0\" class=\"image\" /></a>\n<br />";and replace with        $pic_html = "<a href=\"{$picture_url}\" class=\"document_link\"><img src=\"".$pic_thumb_url."\" border=\"0\" class=\"image\" /></a>\n<br />";

GauGau

doggystyle


Nibbler


doggystyle

edited line nr. 197 but the html source still shows a "_blank" in the album and picture description.

http://galerie.domnights.de/

thx

Joachim Müller

OK, this is bbcode - edit include/functions-inc.php, find        $ret = preg_replace("#([\n ])([a-z]+?)://([a-z0-9\-\.,\?!%\*_\#:;~\\&$@\/=\+]+)#i", "\\1<a href=\"\\2://\\3\" target=\"_blank\">\\2://\\3</a>", $ret);
        $ret = preg_replace("#([\n ])www\.([a-z0-9\-]+)\.([a-z0-9\-.\~]+)((?:/[a-z0-9\-\.,\?!%\*_\#:;~\\&$@\/=\+]*)?)#i", "\\1<a href=\"http://www.\\2.\\3\\4\" target=\"_blank\">www.\\2.\\3\\4</a>", $ret);
and replace with        $ret = preg_replace("#([\n ])([a-z]+?)://([a-z0-9\-\.,\?!%\*_\#:;~\\&$@\/=\+]+)#i", "\\1<a href=\"\\2://\\3\">\\2://\\3</a>", $ret);
        $ret = preg_replace("#([\n ])www\.([a-z0-9\-]+)\.([a-z0-9\-.\~]+)((?:/[a-z0-9\-\.,\?!%\*_\#:;~\\&$@\/=\+]*)?)#i", "\\1<a href=\"http://www.\\2.\\3\\4\">www.\\2.\\3\\4</a>", $ret);
, find                $bbcode_tpl['url']  = '<span class="bblink"><a href="{URL}" target="_blank">{DESCRIPTION}</a></span>';and replace with                $bbcode_tpl['url']  = '<span class="bblink"><a href="{URL}">{DESCRIPTION}</a></span>';

GauGau

doggystyle