How to refresh a web page automatically every specified period of time
I am using asp.net to develop a website, and I want one of my web pages to refresh every 5 seconds when requested; how can I achieve that? ...
I am using asp.net to develop a website, and I want one of my web pages to refresh every 5 seconds when requested; how can I achieve that? ...
Is there a way to load a DOM document dynamically created from the scope of a Firefox extension to a tab in the current browser? I would like to create an HTML report from a Firefox extension and load it in a new tab in the browser. var doc = document.implementation.createDocument ('http://www.w3.org/1999/xhtml', 'html', null); var ...
I'm trying to get the name of an element in Javascript. Meaning if the element is <div />, then "div" would be returned. If it's <img src="" /> then "img" would be returned. I'm using jquery to select a bunch of elements and then calling a custom function on all of them. Within that function I want to know what I'm dealing with. How do I...
I've been tasked with getting all the SMS updates from this page and putting them into a JSON feed using Yahoo Pipes. I'm not entirely sure how I would get each update, as they are not individual elements, but just a collection of title, etc. Any shared wisdom would be much appreciated! ...
Suppose I have two DIVs on my page. <body> <div id="d1"></div> <div id="d2"></div> </body> I want to create a new DIV dynamically using JavaScript and place it between d1 and d2. If I use the appendChild method the new DIV is placed at the end. Right now I can only think of paring the innerHTML of the BODY and appending the new DIV a...
I'm using JSObject plugin to write a cookie through the java applet and it worked with SUN's Java. but, With MS JVM the javascript command returning undefined I'm issuing the following from my Applet: String s1 = "document.cookie='logged=1'"; aobj = new Object[] { s1 }; JSObject.getWindow(MyAppletWindow).call("eval", aobj); any clue...
I know that, in jQuery, we are told to use $(document).ready() in order to ensure that the DOM elements are ready for interaction. I know that this definitely applies if the script tags are in the <head>. If they are at the end of the <body>, after all of the DOM elements, should I still use a DOM-ready function? Are there browsers in wh...
I am using the following JavaScript to add a number of inputs based on a number in a drop down menu. It works fine in firefox and chrome, but in IE7 the inputs all float left on a new line. function add(number) { var foo = document.getElementById("listInputs2"); var count = 1; foo.innerHTML = ""; while ( count <= (number) ) { //Creat...
i have some php files with html code in it and from my php file i have: require "popup.html"; require "main.html"; then i use css to hide the div in popup.html. when i click a link coupled to jquery to display the popup it will be above all divs in main.html except the ones that i have rendered in with ajax. how can i make the pop...
I am working on converting an excel spread sheet into an xml document that needs to be validated against a schema. I am currently building the xml document using the DOM api, and validating at the end using SAX and a custom error handler. However, I would really like to be able to validate the xml produced from each Cell as I parse the e...
For using a 3rd party library, I need a w3c DOM Document. However, creating the xml nodes is easier in Scala. So I'm looking for a way for converting a scala xml element to w3c dom. Obviously, I can serialize to a string and parse it, but I'm looking for something more performant. ...
The case : <form id='frm' name ='frm' action='test.php'> <div style='display:none'> <input type='text' name='name' value ='' /> </div> <input type='submit' value='Submit' /> </form> For example , How can i submit the from given above with its inputs ? Issue : The "name" input wont be passed ! ...
Hey, I'm not very experienced with javascript, jQuery or it's plugins but usually I manage. Anyways, my client is building a site and one of its purposes is to pick up news articles from different sites and show the titles in unordered html lists. I don't have access to his code, the news articles load up rather slow(much after the sit...
I have a requirement in Javascript (using Prototype) to focus the cursor on the first form item within a specific div. Simple example: <form id="theForm"> <div id="part1"> <input id="aaa" .../> <select id="bbb">...</select> </div> <div id="part2"> <select id="ccc">...</select> <input id="ddd" .../> </div> </form...
Simple question - hard to answer, by my experience: I have element E and I'm appending to it some elements to it. All of a sudden, I find out that next element should be first child of E. What's the trick, how to do it? Method unshift doesn't work because E is an object, not array. Long way would be to iterate trough E's children and...
iam using jquery and want to do below written //this is a template <div class='main'> <div class='header'>Some Text</div> <div class='data'> // data goes here </div> </div> // dom --------dom here------------- <div id='red1' class='red'></div> -----more dom (template is here)------------ what i want is...
Hi, everyone. About a year ago I wrote a jQuery-inspired library which allowed you to manipulate the DOM using PHP's XPath and DOMDocument. I recently wanted to clean it up and post it as an open source project. I've been spending the past few days making improvements and implementing some more of PHP's native OO features. Anyhow, I th...
I am trying to put a variable into a dom string. I have various fields as such: <input type="text" name="itemdesc1" /> <input type="text" name="itemdesc2" /> I want to loop through these to see if they are populated before submit. The only problem I have is that I cannot run them through a loop, because I need to put a variable into ...
Hi all, How can we hide the statusbar of a current page using javascript.I used window.statusbar.visible = false but its not working.Please give me a solution regards Arun ...
Hi, Wanted to know which is the most lightest HTML element. Have a huge set of JSON data which i have to display in proper readable format, hence going to loop through the data and create dynamic elements. Which is the most lightest element of HTML, lightest as in which takes the least amount of memory and is easily rendered by the bro...