Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Mozilla/Firefox users: Search when editing templates Details »»
Mozilla/Firefox users: Search when editing templates
Version: 1.00, by sv1cec sv1cec is offline
Developer Last Online: Mar 2022 Show Printable Version Email this Page

Version: 3.0.7 Rating:
Released: 06-27-2005 Last Update: Never Installs: 25
 
No support by the author.

I am not sure if this is a real hack, so moderators, please feel free to remove it, if you do not consider it worthy.

I am an avid Mozilla user, having IE only for testing my forums, so I never use IE in the admincp. However, I was given access to a site, in which, for some reason, I had to use IE to access its admincp. I noticed that while editing a template, there was a "Search" box at the bottom of the form. That same box, didn't show up when using Firefox!

So I started asking around and I was told that this works only in IE. Then, when vB 3.5 came out, I noticed that the search function, was present in Firefox as well. Puzzled, I posted a question in vB.com, and the answer I got said to upload the clientscript/vbulletin_templatemgr.js, to get the same functionality.

Well, I did but nothing changed. So then I compared the file includes/adminfunctions_template.php and noticed some small differences. I incorporated them in vb 3.0.7 adminfunctions_template.php and voila, I got the search working fine.

If you are not in a hurry to update to vb 3.5 and if you want that functionality, edit your includes/adminfunctions_template.php and find:

PHP Code:
function print_template_javascript()
{
    global 
$stylevar$vbphrase$vboptions;

    
print_phrase_ref_popup_javascript();

    echo 
'<script type="text/javascript" src="../clientscript/vbulletin_templatemgr.js"></script>';

    
print_label_row(iif(is_browser('ie'), $vbphrase['search_in_template'], $vbphrase['additional_functions']), iif(is_browser('ie'), '
    <input type="text" class="bginput" name="string" accesskey="t" value="' 
htmlspecialchars_uni($GLOBALS['searchstring']) . '" size="20" onChange="n=0;" tabindex="1" /> 
replace that with:

PHP Code:
function print_template_javascript()
{
    global 
$stylevar$vbphrase$vboptions;

    
print_phrase_ref_popup_javascript();

    echo 
'<script type="text/javascript" src="../clientscript/vbulletin_templatemgr.js"></script>';

    
print_label_row(iif(is_browser('ie') OR is_browser('mozilla''20040707'), $vbphrase['search_in_template'], $vbphrase['additional_functions']), iif(is_browser('ie') OR is_browser('mozilla''1.7'), '
    <input type="text" class="bginput" name="string" accesskey="t" value="' 
htmlspecialchars_uni($GLOBALS['searchstring']) . '" size="20" onChange="n=0;" tabindex="1" /> 
With only this change, the search is working OK for me, but if you have problems, try uploading the clientscript/vbulletin_templatemgr.js from vb 3.5. It was not needed in my case, and it does not seem to have any differences that can affect the search, but I am not an expert in js.

Rgds

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 06-28-2005, 03:48 PM
Freezerator Freezerator is offline
 
Join Date: Nov 2001
Location: Den Haag
Posts: 197
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

HoTM

Nice hack, really handy.
Reply With Quote
  #13  
Old 06-28-2005, 03:59 PM
TheComputerGuy's Avatar
TheComputerGuy TheComputerGuy is offline
 
Join Date: Oct 2001
Location: TX
Posts: 580
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

sweet deal
Reply With Quote
  #14  
Old 06-28-2005, 08:49 PM
DS MrSinister DS MrSinister is offline
 
Join Date: Dec 2002
Location: the burgh
Posts: 553
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank You Thank You u made my life soooooooooo much better.. WHat a great hack.




Clicks Install
Reply With Quote
  #15  
Old 06-28-2005, 10:52 PM
Littlebit's Avatar
Littlebit Littlebit is offline
 
Join Date: Nov 2001
Posts: 313
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks a bunch!
Reply With Quote
  #16  
Old 06-28-2005, 10:55 PM
iceman-x iceman-x is offline
 
Join Date: Nov 2002
Location: NOrWAY
Posts: 46
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thanks you, wery nice, i have ben missing it for some time.
Reply With Quote
  #17  
Old 06-28-2005, 10:56 PM
Adrian Schneider's Avatar
Adrian Schneider Adrian Schneider is offline
 
Join Date: Jul 2004
Posts: 2,528
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great minds think alike
https://vborg.vbsupport.ru/showthread.php?t=81936

Thanks
Reply With Quote
  #18  
Old 06-29-2005, 01:40 AM
Picside Picside is offline
 
Join Date: Jun 2005
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

awesome! i always thought that was weird not to be able to search with the VB editor. thanks!
Reply With Quote
  #19  
Old 06-29-2005, 03:49 AM
Adrian Schneider's Avatar
Adrian Schneider Adrian Schneider is offline
 
Join Date: Jul 2004
Posts: 2,528
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

But it's not a template mod.
Reply With Quote
  #20  
Old 06-29-2005, 04:28 AM
yoyoyoyo's Avatar
yoyoyoyo yoyoyoyo is offline
 
Join Date: Dec 2004
Location: USA
Posts: 1,612
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by TheSpecialist
But it's not a template mod.
I was actually replying to the wrong thread .. oops. Thanks for this one, too
Reply With Quote
  #21  
Old 06-29-2005, 11:30 AM
mkdevo mkdevo is offline
 
Join Date: May 2004
Location: CT, USA
Posts: 269
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

wow.. as a firefox user, i never even knew this existed! thanks!
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:34 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05355 seconds
  • Memory Usage 2,316KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete