MyBB Community Forums

Full Version: Some JavaScript Not Working
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Some JavaScript is not working on my site, for example, the reputation, quick edit, etc. For the quick edit, you can click on the edit button and the option to go to either full edit or quick edit pops up, but quick edit doesn't go anywhere.

Some details: I just changed my theme to a custom theme, and I'm using the EXACT headerinclude I was using for the past few months with no problems on the old theme. Any ideas how to fix this?
Please take a look at this thread:
http://community.mybb.com/thread-127961....it+problem

Please post again if it helped you solve your issue.
(2012-11-10, 04:03 AM)Nobby Wrote: [ -> ]Please take a look at this thread:
http://community.mybb.com/thread-127961....it+problem

Please post again if it helped you solve your issue.

That didn't help, thanks for your reply though.
Bump, still having this issue. Sad
Its definitely a conflict.

Headerinclude is not only the place where the library gets included, it may be any template that loads everytime (like header etc).

Take a look at view-source to make sure you are not loading 2 or more different versions of jQ library. (You stated noConflict is in your template and doesn't resolve the issue).

May be a link to your site can make the things easier.
(2012-11-19, 08:29 AM)effone Wrote: [ -> ]Its definitely a conflict.

Headerinclude is not only the place where the library gets included, it may be any template that loads everytime (like header etc).

Take a look at view-source to make sure you are not loading 2 or more different versions of jQ library. (You stated noConflict is in your template and doesn't resolve the issue).

May be a link to your site can make the things easier.

http://forumhour.com
Username: aud_test
Pass: test123

Let me know what you find. Please and thank you. Smile
Well I've not found anything that is not working there, my bad.

Looking at your headerinclude, I saw:

<script type="text/javascript">$.noConflict();</script>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js"></script>

I suggest you to change this two lines to:


<script type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"></script>
<script type="text/javascript">
if (typeof jQuery == 'undefined') {
    document.write(unescape("%3Cscript src='http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js' type='text/javascript'%3E%3C/script%3E"));
}
</script>
<script type="text/javascript">jQuery.noConflict();</script>

1. I've set the code to load the latest library, if you want - use v1.5 as you are using.
2. Added a fallback CDN, you can skip it.
3. [Important] Don't use jQ shorthand ($), use the phase 'jQuery' instead.
4. [Important] Watch the statement sequence. jQuery.noConflict(); must be declared after loading the library, not before.

Make the changes and see what happens.
Hmm... I appreciate your efforts, but it's still not working. For example, multi-quote won't work. When you click on the Edit button, the Quick and Full options come up, but clicking on Quick Edit does nothing.

Here's my full headerinclude template.

<link href='http://forumhour.info/css/sky/style.css' rel='stylesheet' type='text/css'>
<!--[if lte IE 9]>
	<link type="text/css" rel="stylesheet" href="{$theme['imgdir']}/ie.css" />
<![endif]-->
<link rel="alternate" type="application/rss+xml" title="{$lang->latest_threads} (RSS 2.0)" href="{$mybb->settings['bburl']}/syndication.php" />
<link rel="alternate" type="application/atom+xml" title="{$lang->latest_threads} (Atom 1.0)" href="{$mybb->settings['bburl']}/syndication.php?type=atom1.0" />
<meta http-equiv="Content-Type" content="text/html; charset={$charset}" />
<meta http-equiv="Content-Script-Type" content="text/javascript" />
<script type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"></script>
<script type="text/javascript">
if (typeof jQuery == 'undefined') {
    document.write(unescape("%3Cscript src='http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js' type='text/javascript'%3E%3C/script%3E"));
}
</script>
<script type="text/javascript" src="{$theme['imgdir']}/tipsy/javascripts/jquery.tipsy.js"></script>
<script type="text/javascript">jQuery.noConflict();</script>
<script type="text/javascript" src="{$theme['imgdir']}/tipsy/javascripts/tooltip.js"></script>
<script type="text/javascript" src="http://forumhour.info/jscripts/combined.js"></script>
<script type="text/javascript">
<!--
	var cookieDomain = "{$mybb->settings['cookiedomain']}";
	var cookiePath = "{$mybb->settings['cookiepath']}";
	var cookiePrefix = "{$mybb->settings['cookieprefix']}";
	var deleteevent_confirm = "{$lang->deleteevent_confirm}";
	var removeattach_confirm = "{$lang->removeattach_confirm}";
	var loading_text = '{$lang->ajax_loading}';
	var saving_changes = '{$lang->saving_changes}';
	var use_xmlhttprequest = "{$mybb->settings['use_xmlhttprequest']}";
	var my_post_key = "{$mybb->post_code}";
	var imagepath = "{$theme['imgdir']}";
// -->
</script>
{$newpmmsg}
<script language="javascript" type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/myadvertisements.js"></script>
Bump, I'm still having some issues.
I have similiar issues. SadI posted them in this Topic:

http://community.mybb.com/thread-53553-p...#pid944199

Originally because I started noticing certain things not working properly anymore, when I noticed that this plugin didn't work anymore.

I really don't know what to do anymore. I am no coder, means I am no good with these things. I would really appreciate any help you can give me to solve this. Sad

Please

Thanks in advance.

Wolfseye