vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Disable [IMG] In [QUOTE] Tags (https://vborg.vbsupport.ru/showthread.php?t=77173)

Zero Tolerance 02-27-2005 10:00 PM

Disable [IMG] In [QUOTE] Tags
 
Modification made by request, this modification will disable all [IMG] tags within quote tags, leaving them as URL's instead.

Example:
This:
Quote:

This is my avatar: http://gzevolution.net/pic/sk_avy.jpg
Would Be Changed To:
Quote:

This is my avatar: http://gzevolution.net/pic/sk_avy.jpg
Only 1 file to edit, real easy :)

Enjoy,

- Zero Tolerance

Protoman 02-28-2005 01:38 AM

very simple. 30 second install. thanks!

nexialys 02-28-2005 01:41 AM

/me likes filters !!!

Oblivion Knight 02-28-2005 06:38 AM

You're on a roll again ZT, another excellent little mod.. :)

Works perfectly.

Phalynx 02-28-2005 09:05 AM

Great, thanks!

hollyboy 02-28-2005 11:19 AM

nice hack, I've installed it thanks ;)

reteep 02-28-2005 11:52 AM

Cool, installed!

S@NL - BlackBik 02-28-2005 08:29 PM

Just what I was looking for :)

Thanks a lot ZT/

Crapaddict 03-02-2005 02:49 PM

on my board I have created an imgthumb custombbcode [img4], wich displays all images with the width="100" parameter.
I assume i could easily replace the url tag in this hack with my own img4 tag?
Or should i rename my img4 tag, since img4 also contains the plain img tag (when you drop the number 4), which is exactly what this hack searches for....
If this would work, all images inside quotes would be displayed as thumbnails :)

edit:
hmz... it doesn't :P
Might be nice if anyone could make it work, though :rolleyes:

PIKenPIK 03-12-2005 02:58 PM

Thanks ... installed :D

Acers 03-18-2005 01:35 PM

Just what i needed.... this is super stuff

Mosh 04-09-2005 05:05 PM

Hey ZT, thanks for this, less than 30 sec to do and upload :)

akanevsky 04-16-2005 12:06 PM

Good job! Installed.

PIKenPIK 04-22-2005 05:13 PM

Excellent .... /me clicks Install !!

again :squareeyed: after a reinstall of 3.07

MP3 04-29-2005 05:51 AM

Cool, installed!

Casperddc 05-14-2005 06:38 PM

Thanks man - just installed it. Wanted this for awhile now!

akanevsky 10-22-2005 06:21 PM

Come on dude, please port it tyvm

J82980BA3E43 11-10-2005 07:55 AM

Can someone help me please where i put this script to Vbulletin 3.5 gold please :disappointed:

almqdad 11-16-2005 11:28 AM

hh

does it work with

vBulletin Version 3.0.8

hollyboy 11-22-2005 02:37 PM

this dont work for vb 3.5 :(

dmark101 12-14-2005 05:54 PM

Quote:

Originally Posted by hollyboy
this dont work for vb 3.5 :(

can someone PM the guy who made the hack and see if it can be done for vB 3.5.x?

:)

Scootro 03-13-2006 08:46 PM

Thanks. Installed.

The Fathom 06-28-2006 04:12 PM

Will this work in 3.5 too?

Protonus 08-19-2006 07:52 AM

I would love to see this ported to 3.6!

masalaman 09-01-2006 03:14 AM

We have to do this a bit different in 3.6.0.

1). Open "includes/class_bbcode.php"

2). Find function handle_bbcode_quote

3). Within function "handle_bbcode_quote" find the line below. This line is there at several places so make sure you found the right one.

eval('$html = "' . fetch_template($template) . '";');

4). Add the code below right after the above line.

Code:

                //### HACK BEGIN - Turn [img] to [url]
                if ($this->contains_bbcode_img_tags($html))
                {
                        $html = preg_replace('#\[img\]\s*(https?://([^<>*"]+|[a-z0-9/\\._\- !]+))\[/img\]#iUe', "\$this->handle_bbcode_url(str_replace('\\\"', '\"', '\\1'), '')", $html);
                }
                //### HACK END


Protonus 09-07-2006 06:50 AM

Masalaman: Thank you so much for taking the time to work on this. I tried your above steps and unfortunatly cannot get it to work. It seems to do nothing difference to new or existing quotes containing [img] tags :-( Nothing seems broke, just doesn't work. I made sure that I added the code you list right after the existing command you mention, while in the correct function. It all looks good. I see no other mentions of the quote function elsewhere in this file either...

Is there something I have to do to "activate" this per se? I would think it would work on th fly... Let me know if I'm missing something, thanks!

Protonus 09-20-2006 06:53 PM

bump? Anyone know how to get this to work in 3.6.0? The above hack didnt' work when I tried it.

indiancinema 10-21-2006 12:38 AM

any updates

masalaman 10-25-2006 03:29 AM

It works fine for me. Images in quote are shown as just hyperlinks on my forum. Protonus, have you copied the code multiple times? It must be copied after every instance of the line below.

eval('$html = "' . fetch_template($template) . '";');

indiancinema 10-25-2006 11:11 PM

working thank u

Protonus 11-07-2006 06:26 AM

Quote:

Originally Posted by masalaman
It works fine for me. Images in quote are shown as just hyperlinks on my forum. Protonus, have you copied the code multiple times? It must be copied after every instance of the line below.

eval('$html = "' . fetch_template($template) . '";');

Well your first set of instructions makes it sound like you should only copy it once? But I went a head now and copied it after all lines specified (I found 4 instances of that line.). It doesn't seem to have had any effect... Does it matter that I use the legacy postbit? I'm grasping at straws here. Any other ideas? Things I can check? Something? :D

dmark101 11-09-2006 10:31 PM

Quote:

Originally Posted by masalaman
It works fine for me. Images in quote are shown as just hyperlinks on my forum. Protonus, have you copied the code multiple times? It must be copied after every instance of the line below.

eval('$html = "' . fetch_template($template) . '";');

thank you. the code worked perfectly. :)

Protonus 11-20-2006 07:31 PM

dmark and anyone else getitng this working.. are you using the legacy postbit? I'm still baffled why this doesn't work for me.

Protonus 12-01-2006 05:19 PM

Still don't have this working... Any thoughts?

Protonus 12-16-2006 07:30 PM

Updated the board to 3.6.4 today, tried to do this hack again STILL cant' get it to work. I'm at a loss, I don't get why it's not working?! I pasted in the code after every instance of the above noted line. I can post up my file if someone wants to take a look at it, I tried to post it here but it's too long...

Raptor 01-11-2007 01:25 AM

Quote:

Originally Posted by masalaman (Post 1065331)
We have to do this a bit different in 3.6.0.

1). Open "includes/class_bbcode.php"

2). Find function handle_bbcode_quote

3). Within function "handle_bbcode_quote" find the line below. This line is there at several places so make sure you found the right one.

eval('$html = "' . fetch_template($template) . '";');

4). Add the code below right after the above line.

Code:

                //### HACK BEGIN - Turn [img] to [url]
                if ($this->contains_bbcode_img_tags($html))
                {
                        $html = preg_replace('#\[img\]\s*(https?://([^<>*"]+|[a-z0-9/\\._\- !]+))\[/img\]#iUe', "\$this->handle_bbcode_url(str_replace('\\\"', '\"', '\\1'), '')", $html);
                }
                //### HACK END


100% works perfect with 3.6.4 - thanks !

tankaya61 01-14-2007 04:29 PM

Quote:

Originally Posted by Raptor (Post 1155941)
100% works perfect with 3.6.4 - thanks !


how use 3.6.4
can you say us?
it doesn't work 3.6.4 !

Zia 02-25-2007 03:15 AM

any one describe the total process for use at vb3.6.4 ?

TIA

Zia 03-04-2007 04:46 PM

helo any one...can say the process for
vb3.6.5 ?

Zia 03-13-2007 01:07 PM

found it in 3 places

Quote:

$template = $this->printable ? 'bbcode_quote_printable' : 'bbcode_quote';
eval('$html = "' . fetch_template($template) . '";');
return $html;

------
Quote:

$code = preg_replace('/&amp;#([0-9]+);/', '&#$1;', $code); // allow unicode entities back through
$code = str_replace(array('[', ']'), array('[', ']'), $code);
$template = $this->printable ? 'bbcode_php_printable' : 'bbcode_php';
eval('$html = "' . fetch_template($template) . '";');
return $html;
--------
Quote:

eval('$html = "' . fetch_template($template) . '";');
return $html;
actually where it needed to put or every palces?


All times are GMT. The time now is 04:49 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01331 seconds
  • Memory Usage 1,791KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (10)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete