The following code:  var borderTds = document.getElementsByClassName('leftborder');   gives me an error message in Internet Explorer 6, 7 and 8:      Object does not support this method   How can I select elements by their class in these br...
I'm trying to replace all text in between tags and I want to know the fastest way of doing so.   An example would be trying to replace all text with the arbitrary string helloWorld, so that this:   <div>     <div>         RandomText1...
I'd like to be able to walk up the DOM from inside one or more nested iframes to grab and empty the parent div of the top iframe. I'd like my JS to work if there's just one iframe, or if there are two.  I have a main page with this iframe...
Let's say I have many of these in my content div : <cite class="fn">blabla</cite>  How can I check every cite tag's content (in this case: blabla) with class fn to see if it equals to "sometext" then change it'...
Please take a look at the snippet below:  <div>     <div></div>     <div><!-- my target node -->         <div><!-- not my target node -->             <img /><!-- my source node -->         </di...
I am looking to select the common parent of multiple nested elements for which I only know the inner text.  For example, in the following code:  <unknown>            <unknown class="unknown">         ....         <unknown>...
I have page with many doubleclick scripts   I have js code inserted    at the body top (via s.src=('parts_async_dev.js')):  var innerHTML = document.getElementsByTagName('html')[0].innerHTML.toString(); var regexp = /ad.doubleclick.n...
I am trying to get the text of the link directly before another link (parent's sibling), but I keep getting "undefined." I can't figure out what I need to change to get the anchor tag's text rather than "undefined"  Here i...
I have a ul of items that are being displayed on a page under a form.  I want a link to be added in each li on submission of the form.  I have an array of links  I want to have a method loop over array and loop over li, essentially setAttribute on ea...
I am calling an async function on all the HTML of a page 5000 characters at a time, and then want to replace the 5000 characters in place as I hear back from the API. However I am having trouble replacing the returned text in place.  Note that this i...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.