Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 01-11-2012, 01:31 AM
thecore762 thecore762 is offline
 
Join Date: Jul 2008
Posts: 510
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Need assistance with jQuery+Prototype.js conflict.

Hey guys, I need some help.
The mod developer is somewhat busy in life and too busy to fix his paid products...(I know sad no?)

Currently the donation system uses prototype.js and I currently run jQuery on my forums page.
The donation bar will not load showing the progression.
See here: http://www.47r-squad.com/forum.php
See front page: http://www.47r-squad.com that's how it supposed to work.

These are the mods I currently use that are conflicting:
- https://vborg.vbsupport.ru/showthread.php?t=276419
- https://vborg.vbsupport.ru/showthrea...light=awcoding

Your assistance will be greatly appreciated.
Reply With Quote
  #2  
Old 01-11-2012, 01:50 AM
LifesGreatestGift's Avatar
LifesGreatestGift LifesGreatestGift is offline
 
Join Date: Jul 2009
Location: Louisville, KY USA
Posts: 885
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

What is causing your issue is that you are running the tooltip mod. You just need to change the code for the jQuery to use noconflict

In your tooltip mod code change it to
HTML Code:
<script>    
$.noConflict();
jQuery("#scanudesc a[title]").tooltip({    
position: "bottom right",    
effect: "slide"    
});    
</script>
and see if that fixes the issue.

EDIT

whats weird is the jQuery tooltip code is embedded and called for every forum you have. Bad coding. It should have been called in the head due to it not having dynamic content.
Attached Images
File Type: jpg Untitled.jpg (35.9 KB, 0 views)
Reply With Quote
  #3  
Old 01-11-2012, 01:57 AM
LifesGreatestGift's Avatar
LifesGreatestGift LifesGreatestGift is offline
 
Join Date: Jul 2009
Location: Louisville, KY USA
Posts: 885
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

<a href="https://vborg.vbsupport.ru/showthread.php?t=276419&highlight=description" target="_blank">https://vborg.vbsupport.ru/showt...ht=description</a>

It actually looks like he has his JS wrapped around a couple conditionals in the plugins.
Reply With Quote
  #4  
Old 01-11-2012, 02:01 AM
thecore762 thecore762 is offline
 
Join Date: Jul 2008
Posts: 510
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by LifesGreatestGift View Post
What is causing your issue is that you are running the tooltip mod. You just need to change the code for the jQuery to use noconflict

In your tooltip mod code change it to
HTML Code:
<script>    
$.noConflict();
jQuery("#scanudesc a[title]").tooltip({    
position: "bottom right",    
effect: "slide"    
});    
</script>
and see if that fixes the issue.

EDIT

whats weird is the jQuery tooltip code is embedded and called for every forum you have. Bad coding. It should have been called in the head due to it not having dynamic content.
Hmmm, should I try the following or it would be no help?
Reply With Quote
  #5  
Old 01-11-2012, 02:03 AM
LifesGreatestGift's Avatar
LifesGreatestGift LifesGreatestGift is offline
 
Join Date: Jul 2009
Location: Louisville, KY USA
Posts: 885
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

if you edit the actual plugin in the admincp and make the changes to both instances (because he is using a if else conditional) it should work.

It appears it's in the
HTML Code:
			<title>Code replace</title>
			<hookname>parse_templates</hookname>
plugin for the product.

--------------- Added [DATE]1326251138[/DATE] at [TIME]1326251138[/TIME] ---------------

Code:
<vb:if condition="$forum[islastshown]">
<script>   
$("#scanudesc a[title]").tooltip({   
position: "bottom right",   
effect: "slide"   
});   
</script></vb:if><vb:else />
<script>   
$("#scanudesc a[title]").tooltip({   
position: "bottom right",   
effect: "slide"   
});   
</script>
</vb:if>
The code could use some work.

--------------- Added [DATE]1326251193[/DATE] at [TIME]1326251193[/TIME] ---------------

Although its possible it won't work because the prototype code is called before the jQuery....
Reply With Quote
  #6  
Old 01-11-2012, 02:21 AM
HMBeaty's Avatar
HMBeaty HMBeaty is offline
 
Join Date: Sep 2005
Posts: 4,141
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by LifesGreatestGift View Post
Code:
<vb:if condition="$forum[islastshown]">
<script>   
$("#scanudesc a[title]").tooltip({   
position: "bottom right",   
effect: "slide"   
});   
</script></vb:if><vb:else />
<script>   
$("#scanudesc a[title]").tooltip({   
position: "bottom right",   
effect: "slide"   
});   
</script>
</vb:if>
The code could use some work.
lol no kidding! I'm curious if that part of it even works like it should since the way the conditional is written is wrong
Reply With Quote
  #7  
Old 01-11-2012, 02:26 AM
LifesGreatestGift's Avatar
LifesGreatestGift LifesGreatestGift is offline
 
Join Date: Jul 2009
Location: Louisville, KY USA
Posts: 885
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hope all goes well Glad I could help, btw for future onlookers

the code needed to be changed from
HTML Code:
<script>    
$("#scanudesc a[title]").tooltip({    
position: "bottom right",    
effect: "slide"    
});    
</script>
TO
HTML Code:
<script>    
$.noConflict();
jQuery("#scanudesc a[title]").tooltip({    
position: "bottom right",    
effect: "slide"    
});    
</script>
--------------- Added [DATE]1326252531[/DATE] at [TIME]1326252531[/TIME] ---------------

Quote:
Originally Posted by HMBeaty View Post
lol no kidding! I'm curious if that part of it even works like it should since the way the conditional is written is wrong
Apparently (at least on the forum in question) the script code was hard-coded into the
forumhome_forumbit_level2_post
template. but it is also inside the plugin but it was disabled.
Reply With Quote
Благодарность от:
thecore762
  #8  
Old 01-11-2012, 02:30 AM
thecore762 thecore762 is offline
 
Join Date: Jul 2008
Posts: 510
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you for fixing it for me
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 09:28 AM.


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.07983 seconds
  • Memory Usage 2,265KB
  • Queries Executed 14 (?)
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
  • (2)bbcode_code
  • (5)bbcode_html
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (8)post_thanks_box
  • (1)post_thanks_box_bit
  • (8)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (8)post_thanks_postbit_info
  • (8)postbit
  • (1)postbit_attachment
  • (8)postbit_onlinestatus
  • (8)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
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • postbit_attachment
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete