javascript

Using JS Event handlers inside a wizard inside an updatepanel

Hi All, I've got a textbox being used to enter a password inside a wizard control. I'm trying to get a password strength meter working with it. Unfortunately, the password box isn't visible until step 4 and this means that I can't register the event handler onload() and putting some JS next to the PW box to register the event handler d...

Automated browsing with javascript?

I'm trying to do some browser automation, but I'm having some problems. Basically, what I'd like to do is load a set pages, set some forms options, click a button and view the results for each page that I open. Originally, I tried to do this by placing the pages I wanted to automate in iframes and then using javascript to drive the inter...

Dynamic dropdown search box

Are there any gems that would help me make a search box like the one for tags on stackoverflow? (Rails 2.3.5, required IE7 support and graceful no-script fall-back) P.S.: Do these boxes annoy you or do you think it's a good thing to have one? ...

Online Code Coloring Service

Hello, I would like to know if anyone knows of an online service where we paste the code and it generates back the colored html source code for that code. It could be PHP, HTML, CSS, Javascript, C, Java. Idea is that once i have the colored html code, i could easily put that in my wordpress.com blog. I know about [sourcecode language="...

javascript: Implementing selection via click, control click and shift click, such as in windows explorer

In Javascript: I need to implement selection via click, control click and shift click on rows in an html table, such as in windows explorer, and I hate to write it if the code already exists. Can anyone point me in the right direction? thanks! ...

how can i reference form data from the referring document ?

Hi I have a web page that opens up from another page after the user clicks a link. What i want to do using JS is reference the form data from the original page and use it on the page that has just been opened . my first page contains something like function date_change() { window.open("//www.abbeysoft.co.uk/adi/datepicker.php"); } ...

Fixing tabs to the top of the page, but underneath the header

I'm trying to figure out how to design a header for a website so that there are tabs placed underneath the header (that look like they're sticking out from under the header), that stay with the header as the page is scrolled down (and the header moves up), but when they reach the top of the page become fixed there so that they're always ...

jQuery Popup Window Return Value to Parent

How can I accomplish the following using jQuery: Open a popup window that returns a value to the parent window when a link in the child window is clicked, close the child window, and then have the parent automatically submit a form based on the value returned? I realize that the jQuery Dialog is a popular solution, but I require a popu...

URL to check if domain is available

I use AJAX to check Australian domain availability with this web service: http://portal.ausregistry.com.au/whois/whois_check_result.jsp?qry=[AU domain goes here] Are there equivalent services that expose availability for other TLD's? (particularly the big 3: .com, .org, .net) ...

Can JavaScript retrieve a file that is above the web root?

Is it possible to make JavaScript retrieve a file that is above the web root? function sendurl(url) { if(document.images){ (new Image()).src="../recieve_url.php?url="+url; } return true; } ...

which is the best Javascript Keyboard event library.(Hotkeys,Shortcuts )

i want to make a bbs forum that using much Keyboard event , so which is the best Keyboard event library, thanks ...

Joomla - calling the username with javascript

I am working on a simple game to add to my joomla site, done in html/javascript. I want to be able to track user scores, I figure the easiest way to do that is to have the scores saved by username... but I can't figure out how to have joomla provide the javascript with the username? ...

Invalid argument in IE

I love IE :) OK, so I've downloaded a scrip called TinySlidshow (http://www.leigeber.com/2008/12/javascript-slideshow/) works perfectly in FF then I tried IE and boom got an invalid argument error on like 160. Here is line 160 compressed which is what it looks like by default. if(oh==h){clearInterval(e.si)}else{if(oh!=h){e.style.heigh...

How to capture a backspace on the onkeydown event

I have a function that is triggered by the onkeydown event of a textbox. I need to know if the user has hit either the backspace key or the del key. Thanks in advance ...

Cannot confirm that element exists on the page when I clearly see it there.

I'm using a function which utilizes jQuery in order to grab information from a JSON feed. The problem here is that from the feed I must pick 10 items that meet the criteria of being within the last year (31 billion milliseconds from the request for argument's sake) and I have to specify how many results I want from the feed with a varia...

question about javascript string's replace method

Hi guys, I know that I can pass a string as the second parameter to the JavaScript string object's replace method. In this case I can use $` and $' to reference the left/right part text of a successful match. Now my question is, If I pass a callback function as the second parameter, how can I get the same information? I want to use this...

How would you make a dynamic formset in Django?

Here's the way I'm doing it: {{ formset.management_form }} <table> {% for form in formset.forms %} {{ form }} {% endfor %} </table> <a href="javascript:void(0)" id="add_form">Add Form</a> And here's the JS: var form_count = {{formset.total_form_count}}; $('#add_form').click(function() { form_count++; var fo...

How to get a list of pages if site having two pages-with same name?

for example http://www.sitename.com/section1/pagename.aspx http://www.sitename.com/section2/pagename.aspx I need quick report only for pages which has same name. like "pagename.html" in example. ...

How to call a jquery validation function outside of form

Hi guys! So I have a validation script I made a while ago. I can pass the script "this" as the form identifier to get it going on the right element (with(this)). But what if I want to call this validation function from a place other than the form itself, let's say, in an another request that wants to know if the form is valid? functi...

event listeners on plugin in document.onload events in opera

I am trying to understand an issue where event-listener registration on plugins doesn't work in Opera unless i delay them. In particular, this doesn't work: document.onload = function() { plugin.addEventListener("foo", function() { alert('onFoo'); }, false); } while delaying the addEventListener() call somewhat through e.g. an al...