protractor problem: not working consistently - javascript

I work with protractor v5.4.2, then i have a issue regarding the consistency of my scripts, the problem the same script sometimes it works the next run it doesn't.
I tried changing jasmine and protractor versions but no luck.
Generaly the errors are :
-Element not interectable.
-No element found using locator. Despite the elements are present and displayed so logicly they are selectabale correctly
Help will be appreciated.

Related

stylesheet not working in chrome , working fine in firefox

Problem with css style sheet, its not working properly in chrome but working fine in firefox
www.danafoods.ae
There is lot of parsing errors in your CSS file (http://www.danafoods.ae/wp-content/themes/wpnation/style.css).
For Chrome, it may look that some of { } braces are left unclosed. See the validation results, it should help you to fix errors:
The W3C CSS Validation Service - CSS validation results
You might want to first see why it can't find the missing wp-admin/admin-ajax.php that it's warning about - if you're trying to fetch css files through ajax, that might be preventing it. Two things I'd try, have you tried running your site locally and seeing if it works in chrome on localhost? And also, have you got the correct permissions on those files/folders?

skrollr mobile clicking on item returns error

I am using the skrollr plugin for parallax https://github.com/Prinzhorn/skrollr. I know it works fine on iPad 3 and iPhone 4S with version 6.1.3.
However, on an iPad 2 version 5.1.1 and several various Android devices, I have run into an issue where if I attempt to click on any link...or really anything at all...I get a message that says:
"JavaScript:Error undefined TypeError:'undefined' is not a function".
I isolated the issue to skrollr.js about line 649 initialElement.click();. If I remove that call, then the error no longer happens...except obviously I still can't click on anything.
Also, I know for sure that this is an error in the plugin itself because I tried clicking on things in the skrollr demo and get the same error http://prinzhorn.github.io/skrollr/.
Has anyone come upon a solution for this? I haven't seen it posted anywhere. Also I've already tried alternatives such as:
initialElement.mousedown('click');
initialElement.trigger('click');
initialElement.bind('click');
initialElement.live('click');
initialElement.delegate('click');
and all give the same exact error.
I find it strange that it doesn't occur in all devices, and the rest of the plugin seems to be working...so it's not an issue on where I'm importing it...heck even everything else attached to initialElement seems to be okay.
Any ideas?
Once again, I would give you a link to my site but can't due to disclosure agreement. But if you need snippets of code let me know.
Thanks for the help!! :)
Maybe give this a shot at line 644 - https://gist.github.com/JustinWUP/6032497
Changing the following on skrollr.js worked for me. [Added $() around the 'initialElement']
if(distance2 < 49) {
//It was a tap, click the element.
//initialElement.focus();
//initialElement.click();
$(initialElement).focus();
$(initialElement).click();
return;
}

Can't destroy CKEditor instances

I'm trying to refresh all my CKEditor instances using this code:
for(name in CKEDITOR.instances)
{
console.log(name);
CKEDITOR.instances[name].destroy();
//Also tried this
//CKEDITOR.instances[name].destroy(true);
}
CKEDITOR.inlineAll();
and I'm receiving this:
Uncaught TypeError: Cannot call method 'getRanges' of null.
The interesting part is that, if I use the code directly in the console, it works just fine.
Anyone has any idea on how to solve it?
Check this bug report: http://dev.ckeditor.com/ticket/10219
In 4.1 and 4.0.3 we have partially fixed this issue, but... only partially :). However, this error shouldn't cause any problems - it is completely harmless.
I also had the same issue but it seems to be fixed in ck-editor-dev repositories.
Somebody checked in a fix 2 days ago for CKEDITOR 4.1.1 milestone.
Check http://dev.ckeditor.com/ticket/10219 again to access the change link in git.

Internet Explorer 7+8 jQuery Error with infiniteCarousel

Hai guise! I am having a spot of trouble with some jQuery I am using, this was previously working but I have made many developments since then and tried to track back to find out what the issue was, but I am unsuccessful - hence, my presence on here. Anyway, I am getting some JS errors in both IE7 and IE8 with the catch my frame jQuery infiniteCarousel plugin, I am literally pulling my hair out over this as when you remove any reference to this everything works beautifully.
Here is a link to the page.
If anyone can shed any light on the matter you would be a life saver!
The problem is that the jQuery infinite carousel plugin is poorly written and the minifaction process requires well formed JavaScript. If you take his code and run it through JSLint you'll see it needs dozens of fixes before it's likely to minimize properly. This is something the author of the plugin needs to rectify.
Although it isn't throwing any errors, it seems that the plugin is loosing track of the elements. A possible solution would be to hook into the start and complete events and stop all the button events until it has completed the animation.
Alternatively, use this plugin instead: http://sorgalla.com/jcarousel/

IE 8 Frameset / Javascript error

Ok here's the problem. I have a page that works in FF3 and Safari4 no problem. It's IE8 that's causing the issue, go figure. I remember in the Netscape days when it was the opposite.
Anyways,
So i'm building a website for a friend - i have three pages. the first two work fine on their own, but when they are combined in a frameset in the third (main.html) in IE8 all hell breaks loose. here are the pages:
www.wither.org/Karoline/navigation.html
www.wither.org/Karoline/portfolio.html
http://www.wither.org/Karoline/main.html
& my CSS if you want it: www.wither.org/Karoline/css/styles.css
if anyone can figure out how to fix this, i'd be eternally grateful. It's completely baffling to me and i've tried all kinds of options. i upgraded jquery to the latest version but then my scroller didn't work and i can't dive too much into the javascript code right now.
Please if you could help out, it would mean a lot to me. this has to go live sometime tomorrow.
There is a JS error when executing the following line of code document.getElementById("loading").style.display = 'none';
in the portfolio page.
Apparently, the element with id 'loading' is not being found. However, if I continue execution of the JavaScript on the page (from within the debugger), there are no issues, and the behavior is the same as in Firefox. This is indicative of a concurrency issue - the element 'loading' is not present in the DOM yet, but the script is attempting to change the element's style.
In order to fix this issue, you will have to ensure that the 'loading' element is present in the DOM before its style is being changed. In fact, you could delay the execution of the onload event handler (using window.setTimeout), until a point where the element is present in the DOM.
What's the actual javascript error?
And IE does have an issue in regards to invalid/broken markup inside of frames, I would try
a) commenting out each script and see which causes the js error
b) if commenting out all the js did nothing it might be related to the invalid markup inside of a frame issue, in which case I'd ditch frames alltogether.
yeah....
so thanks so much for your help. problem solved and i figured the other CSS error. should have picked up on that one earlier.
so site is working and if you want to see what happened with your help,
http://www.wither.org/Karoline
it works perfectly cross platform. made the deadline with hours to spare. thanks SO much. can't believe how well this worked.

Categories

Resources