I am having a very strange issue on the native android browser and blackberry browsers. I simply have a div with id “jobStream” and want to append html to it.
HTML:
<div id="jobStream"></div>
JavaScript”
$("#jobStream").append("<div>test</div>");
Weird thing is that if I do:
$("#jobStream").append("test");
it works fine, but creating the nested div with append seems to be causing issues. I tried with .html() and .after() as well and I see the same problem. I.e. $(“#jobStream”).html(“test”) works but $(“#jobStream”).append(“test”) does not.
AGAIN: this is ONLY not working on some mobile browsers (native android browser 4.1.1 and blackberry browser from what I have tested).
Any ideas why?
Turns out that the javascript needed to be contained in an external js file and included rather than coding it inline with . Ridiculous issue but thankfully solved now.