mCustomScrollbar function not found - javascript

I don't know if this is common behaviour or if I'm the only one having this ..
Here is my situation:
I have been using the mCustomScrollbar plugin for a long time for my drop down and it was amazing. Now I have more divs to apply the same plugin on, but the surprise is I'm always getting the following JS error
Uncaught TypeError: undefined is not a function
and started to have unstable behaviour for the drop down (sometimes I get the scroll bar and sometimes I don't).
I don't know what code to include to make it more clear. Is there something I'm missing? what could be the problem?
Thanks in advance

Related

jQuery issues with kwicks accordion

I'm working on a dev Wordpress site here: http://dev.completehcforwomen.com/ and for some reason I cannot get the Accordion on the home page to function. It appears to me that it is possibly related to a jQuery conflict as in the console I get this issue: Uncaught TypeError:
jQuery(...).kwicks is not a function
for which I have found this in the page:
jQuery('.kwicks').kwicks({
max : 930,
spacing : 0
});
I'm not a jQuery programmer but have been known to fix a couple things at random but this one is eluding me. Does anyone have any suggestions on what might be wrong here and what I should do to fix it?
Thanks,
Looking at your webpage, It looks that you missed to include https://raw.github.com/jmar777/kwicks/v2.2.1/jquery.kwicks.min.js

Dropdown menu on mobile not working

I have a toggle dropdown menu button that appears on smaller resolutions/devices, but for some reason it isnt working. When clicked, nothing appears/shows.
Most likely there is something missing (JS function that makes it open maybe). Copying entire code doesn't make too much sense to me, so I am just using some of it:
http://goo.gl/TNixQe
UPDATE
True about responsive design. Now I noticed it (but did you say about it in your question? nope.).
When I tried to resize window firebug had found this error:
This error appears in js_func.js file in 9 row. Are you sure you link libraries correctly? JS can't find uniform() function.
Possibly this error is appearing, because all your instructions are in simple function. Try to add them to onload handler. Possibly browser try to load this instructions before uniform library had been loaded.
I meant this:
$(document).ready(function()
{
// use `uniform()` function on elements
}
OLD ANSWER
It is simple drop-down menu, based on lists. It is working throw hover handlers.
You can't do 'hover' on your mobile device. You can tap on screen only.
If you want users with gadgets use your site, you have to create menu espesially for gadgets.
Small trick, which helped me (because I am lazy :)) is to assign javascript:void(0); to 1 level buttons hrefs. This worked on SGS2 and Xperia Z1, but I am not sure it will work everywhere. With that trick, a man will tap on menu button and drop-down menu will appear.
You have a javascript error on line 9 of js_func.js:
Uncaught TypeError: Object [object Object] has no method 'uniform'
This will be causing any code below it not to be run.
Could it be a missing plugin on the mobile version?
A quick google suggests that the issue is with your jquery verison, they say to downgrade to 1.8.3.
In your case you are using 1.8.2, so try upgrade to 1.8.3.

Calling a function in an iFrame in IE9

I have a problem that is specific to IE9.
We are using Autodesk MapGuide which has a framework of several nested Framesets. I am trying to call a Javascript function that sits within an IFrame that is within the top level frameset. (Please I dont want to discuss the merits or otherwise of framestes here.)
I have adapted some code I found in another thread using Jquery
window.top.$("#MyIframe")[0].contentWindow.MyFunction();
This works perfectly in IE7 and IE8, but as soon as I try it in IE9 I get the following error:
TypeError: Unable to get value of the property 'contentWindow': object
is null or undefined
I suspect that it is struggling with the framesets and can't find '#MyIframe'.
Is there some other format I can try to get around this? Many thanks in advance for your help.

Uncaught TypeError ONLY in Chrome

I#ve a very strange problem calling a simple function in JavaScript.
Just for example, even a simple:
click
or:
click
gives me an Uncaught TypeError: object is not a function.
But ONLY in Chrome and ONLY on my Notebook. On my Workstation (same system, exactly same Chrome Version) and in every single other browser this line works as expected.
Im Working with JS since a few years, but this error drives me nuts since days.
The Website comes with scriptaculous and some handwritten JS, but nothing really special.
scriptaculous works well, JS-Console shows no errors except the one #Chrome on my Notebook.
Anyone of you ever had this before?
I#ve really no idea whats going on.
My suggestion is to assign it via javascript and not like an inline attribute. Sometimes you get odd behaviour setting it as an attribute.
You could use jQuery:
jQuery('.myClickableLink').click(function(){ alert(123) })
I think that's a simpler way.
I am betting you have a pop up blocker installed on that machine that hijacks window.alert. Disable the plugins and see if it works correctly. [Normally a pop up blocker does this]
use
window.alert('msg)';
it will work...

jQuery call followed by clicking accordion control fires Ms Jscript error

I have jquery modal that works perfectly fine.
But after closing this modal and clicking on accordion control(MS ajax) fires
Jscript runtime error
Microsoft JScript runtime error:
Sys.ArgumentTypeException: Object of
type
'AjaxControlToolkit.AccordionSelectedIndexChangeEventArgs'
cannot be converted to type
'Sys.CancelEventArgs'. Parameter name:
instance
I have done days of searching. But I couldn't find a solution to this.
I have tried scriptmode="Release". Single reference call to the jquery file.
I read some parts saying that some it helped some people to turn of smart navigation but I couldn't find how to do so.
If anyone has any idea on this it will be much appreciated.
Please.. Help~!
I've solved this issue by putting this
var $j = jQuery.noConflict();
at the end of my jquery.js file and referencing all jquery functions with a $j, instead of $
Ok I found the problem. One of the controls inside the container(div) which is loaded by jquery was throwing an error. So in this case, the error message did not help much to track that particular control down.
Thanks a lot for your effort guys!.

Categories