javascript

jQuery how to close dialog from iframe within dialog?

If I open a dialog like so: $('<iframe id="externalSite" class="externalSite" src="http://www.example.com" />').dialog({ autoOpen: true, width: 800, height: 500, modal: true, resizable: true }) How can I close the dialog from withing the iframe? ...

Reordering tables nested rows

Hi, I am improving a CMS I have built and wish for the user to be able to reorder pages using drag and drop. I have table drag and drop for jquery: http://www.isocra.com/2008/02/table-drag-and-drop-jquery-plugin/ however I wish to be able to 'group' rows together and move them within only the group. In the CMS I have a list of top lev...

if IE conditional comments not working

It seems like a silly question, but I'm stumped. I'm using an if IE conditional statement to fix some issues in IE6. In the head, I have <!--[if lt IE 7] > <script type="text/javascript" src="js/ie6.js"></script> < ![endif]--> And in the ie6.js file, I have a simple alert, which works when I take it out of the conditional comment. B...

Using javascript to check if div exists from injected HTML

For a website I'm working on, I've created an embed function. This is just a call to a javascript on my server that injects some HTML on the remote server. To make sure the embeds also get some Google juice, I've added a piece of html, so the embed code looks something like this: <script type="text/javascript" src="http://myserver.com...

Ban Internet Explorer IE script

I know some sites like www.me.com bans IE6. It works when the page detects IE6 browser, it would trigger a DIV to let the user know the first time he accesses the website. Then the user closes, that notice won't appear again (at least for that session recorded in the cookie). Where can I get such script? ...

Get all CSS styles of an element with JavaScript

Hi. Is there a way to select all CSS rules of an element with JavaScript? I'm not looking for a specific solution, just as long as all CSS rules of a given element are read. So, I have the following HTML <div class='styledDiv' style='height:100px;width:100px;'></div> and then in a separate CSS file: .styledDiv { background-color:...

javascript sample with modification doesn't work

I got a "Making Layers that Move" javascript sample code and modified the functions that move left and right, creating the following code (I commented the modified lines, so you can see how it was): <html> <head> <title>JavaScript Radio Example</title> <script language=javascript type="text/javascript"> //var x=10; function moveRight(...

ASP.NET form's data encryption without SSL

Normally, if I complete a form, the data will be sent to the server as raw plain text which could be read by sniffers. I want to encrypt form's data client-side (like username, password,...) and then send them to the server. It seems that there are two ways: 1- Using SSL (in my scenarion, I can't use) 2- Using custom ActiveX control. 3...

Can set value to hidden field on change set value to hidden field?

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"&gt; <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title> </title> <style type="text/css"> </style> <script type="text/javascript...

Convert flash project in javascript

Hi guys I need help making this http://0.mk/baner into javascript. The banner only gets the stuff the user wrote in the text fields and redirects him to a website. Thanks ...

javascript dropdown help

Hi I have a question form and in that form i have 10 sections and in those sections i have 8 dropdown entries so for section one i have q1a, q1b, q1c etc I want the user to only answer 5 of the 8 questions within a section and I want them to select them from 1-5 without duplicating the answer. Is this at all possible? ...

JQuery: Cluetip questions - Turning off tips and maximum height

How do I turn off the tips temporarily? I see the ability referenced on the website a couple times, and in this forum as well, but for some reason I can't find the command that turns them off. I just need to disable them for a bit, then re-enable them. Is there a way to give a tooltip a maximum height? I have a bunch of tooltips, som...

[Javascript] Append an Array to an Unordered List

What I'm trying to accomplish with this code is to output the array alphabet as a series of list items into an existing unordered list in the actual markup. I've got the array into list items, but I can't figure out how to tell it to append itself to an existing unordered list <ul id="itemList"></ul>. var itemsExist = true; var indexNu...

Google Maps infoWindow only loading last record on markers

I'm trying to load a google map with dynamic markers and dynamic infoWindows to go with them. Basically I've got the markers working. The infoWindows are clickable and closable, however they do not have the correct content. It seems that the content for every infoWindow is the last record that is found in the query loop. You will see wha...

From image to numbers

Hi everybody, I have some images that contain numbers written perfectly. These numbers can go from one to 4 characters. Is there a way to recognize and convert these numbers to text with PHP or Javascript? Thank you, Regards. ...

Flash panel & JavaScript 'mega-menu' lag/delay in MSIE?

Team, thank you all in advance for your input on this. The client is experiencing an issue that we have not been able to recreate Site: www.pebblebeach.com Issue: Client is experiencing an extended lag/delay in loading the ‘mega-menu’ on the homepage. The mega-menu sits on top a large Flash panel (roughly 1 Meg). Seems to only be an i...

Decoding a JSON Array From Ajax Request

I finally succeeded in using Ajax to get SOMETHING sent from one page to another! What I'm trying to do is pass an array from a PHP file to a Javascript file, and the Javascript file is receiving this in this.responseText: <html> <head> <script type="text/javascript"> var jsonArray = ["chickens","horses","cows","werewolves"...

SlideToggle imperfections

My slideToggle is a little jumpy at the bottom of the slide transition. Could that be because there is a button there or something. Any way to make it smoother. Tried using easing but not very successful. Any suggestions click on video setup to see for yourself The site $(document).ready(function() { $('.drop').click(function() { ...

Correct external javascript-per-view file placement in an ASP .NET MVC Application

In an ASP .NET MVC application, what's the correct folder to place external javascript files particular to each view? Most views require javascript code that I'm planning to write in external files, but I'm not sure if I should drop them next to the views or in subfolders of the Scripts folder. ...

How can I find out which text area in my form is in focus?

Hi I want to prevent users from using the enter key unless they are in a specific text area on my form . I can stop the enter button being used but how can I find out which part of my form is in focus using js ? Any help would be great , thanks ...