Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 Design and Graphics Discussions
  #1  
Old 06-21-2011, 09:46 AM
Spinball's Avatar
Spinball Spinball is offline
 
Join Date: Feb 2002
Location: Telford, England
Posts: 705
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Convert buttons to text - multiquote problem

Hello,
I don't think I will have a problem replacing buttons with links which are stuled to look like buttons, but I am struggling with the Multiquote button.
This threadhttps://vborg.vbsupport.ru/showthread.php?p=1604783#post1604783
offers an answer which doesn't work.
Code:
<a href="$post[replylink]" rel="nofollow" onclick="return false"><span style="color:<if condition="$show['multiquote_selected']">green<else />red</if>;" id="mq_$post[postid]">$vbphrase[multi_quote_this_message]"</span></a>
The javascript - wherever it is - doesn't want to work on the <span.

Any help appreciated.
Thanks
Reply With Quote
  #2  
Old 06-24-2011, 07:02 AM
Spinball's Avatar
Spinball Spinball is offline
 
Join Date: Feb 2002
Location: Telford, England
Posts: 705
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok I've examined the Javascript and established that it's the function which uses the img tag content which won't work on a span.
I'm surprised there isn't a resource on here which has already been created to help people wanting to do this.
Also somewhat disappointed (though not entirely surprised) at the lack of response to my thread.
Reply With Quote
  #3  
Old 06-27-2011, 12:21 AM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I could respond but I wouldn't have anything of value to add- JavaScript isn't one of my strong points.
Reply With Quote
  #4  
Old 06-27-2011, 06:49 AM
Spinball's Avatar
Spinball Spinball is offline
 
Join Date: Feb 2002
Location: Telford, England
Posts: 705
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I compromised and used buttons in the end.
Is there a decent forum out there where I could get a better response to this or is vBulletin dead?
Reply With Quote
  #5  
Old 06-27-2011, 08:55 AM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Spinball View Post
I compromised and used buttons in the end.
Is there a decent forum out there where I could get a better response to this or is vBulletin dead?
vBulletin's not dead... The obvious answer is if you don't get a lot of responses what you're asking is either:

1) A lot harder to do than you think it is
and/or
2) No one else really thinks it's worth the effort

I'd say this is probably a combination of both- is it really that big a deal to change multi-quote to text? A small 4 color gif file will load just as fast even on a mobile browser and work just fine as is- probably look better too.

That combined with the fact good javascript programmers are much more rare on this site than good php programmers probably has a lot to do with it.
Reply With Quote
  #6  
Old 06-27-2011, 09:37 AM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I got it working.

Guess I picked up more about javascript than I though.

Open your vbulletin_multi_quote.js file

find:

Code:
(D,"img")
replace with:
Code:
(D,"span")
find:
Code:
{A.src=A.src.replace(/\/multiquote_off\.([a-zA-Z0-9]+)$/,"/multiquote_on.$1")}
replace with:
Code:
{A.textContent = "MultiQuote On";A.style.color = "green";}
find:
Code:
{A.src=A.src.replace(/\/multiquote_on\.([a-zA-Z0-9]+)$/,"/multiquote_off.$1")}
replace with:
Code:
{A.textContent= "MultiQuote Off";A.style.color = "red";}

I used the replacement instead of what you put in your first post:
Code:
<a href="$post[replylink]" rel="nofollow" onclick="return false"><span style="color:red;" id="mq_$post[postid]">$vbphrase[multi_quote_this_message]</span></a>
Reply With Quote
  #7  
Old 11-18-2013, 08:21 PM
Motasm Motasm is offline
 
Join Date: Sep 2012
Posts: 2
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thank you
Reply With Quote
Reply

Thread Tools
Display Modes

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 05:37 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.04061 seconds
  • Memory Usage 2,222KB
  • Queries Executed 13 (?)
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
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (8)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (7)post_thanks_box
  • (7)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (7)post_thanks_postbit_info
  • (7)postbit
  • (7)postbit_onlinestatus
  • (7)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_postinfo_query
  • fetch_postinfo
  • 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
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete