javascript

How to pass a Javascript object to a Java applet in Safari?

I'm trying to call into a Java applet from Javascript but when I pass an object the Java applet only receives null. This works in IE and Firefox but not in Safari 4 (tried OSX and Windows version, neither seem to work). The Java applet method I'm calling might look like: public void sampleFunction(JSObject someobject) throws Exception...

Moving a large set of HTML objects on the page and rebinding events with jQuery

I have a DIV with many elements that are all clickable. Each one with it's own unique event. This DIV has a "docked" mode where it shows in some other place and layout on the page, when the mode is toggled. I have to note that my main target browser is IE8. Many of the problems I'm facing here (SSSLLLLLOOOOWWWWW) just go away when I ...

Disable Extjs Form Validation Callout

I have a grid, with contains form items. Example below. Link here. The form elements trigger a validator (ex: allowBlank: false), and pop up a callout. The callout continuously flip flops, and annoys the users. How to disable this callout. { header: 'Item', width: 85, sortab...

In regards to stopping a nsIRequest before completion and determining when a nsIRequest is complete (firefox extension)

Thanks to everyone in advance! I am using a xul:browser and attaching a nsIWebProgressListener to it. I am trying to accomplish two things: 1. Determine when a request is complete (when a document is completely load with all css/js/imgs). 2. Stop a request from completing, specifically URLs with files that issue the download prompt. In...

Open a Spry accordion panel by "onmouseover" instead of "onClick"?

Hi, I added a spry accordion, but the panels only open if the user clicks on it. Is it possible to open a panel by mouseover? And if so how? If you go here, they show you how to do this using buttons, but the methods only include: 1)OpenFirstPanel() 2)OpenNextPanel() 3)OpenPreviousPanel() Is there maybe a method I'm missing? ...

Users having problems clicking submit button.

I have a few users testing a site of mine which has 2 text fields and an image for a submit button. I can't replicate the problem on my side, nor can I seem to find anyone else that is having it either. The problem is that the submit button doesn't do anything when they click it. When I click, and the fields are empty or invalid, I get a...

Direct/Live Preview Like Stackoverflow?

Hello, how do i do like Stackoverflow, when you type in this field, that the it previews directly under it?.. I have no idea how this have been made and i really like to do something like this to my website. I have a textarea that you edit, and then..? how to? Thanks ...

JS/jQuery Image Editor

Hello, has anyone stumbled upon image editor done either in pure JS, or jQuery - that kind like CKEditor has? I'm looking for piece of code, that adds handles to image, so you can resize it, or even drag image around, as you wish. Thank you. Edit: rephrased. ...

change global function scope in javascript

Is the following possible: var someObject = {someProperty : "someValue"}; var someFunction = function() { someProperty = "anotherValue"; }; // what do I do here, in order to use // someFunction to change someObject, // without altering either of those things? // directly accessing "someObject" in someFunction // is not an option. e.g...

Image Hidden, then on mouse movement Fade-In, Fade-Out and Fade-In again.

I am trying to get an image to fade out when there has been no mouse action for 3 seconds and then fades in when the mouse is again moved. I would also be appreciative if anyone could tell me how I can make the image be hidden until the mouse moves. So when the page loads up you don't see the image until the mouse moves. This is what I...

How to elegantly wrap Amazon Affiliate script to prevent validation errors?

I hope everyone is doing well. I'm having an issue on my girlfriend's Blog (www.lawsandlanguages.com). Basically, she suscribed to the Amazon Affiliate Program and they gave her this poorly written code she's supposed to put in her header section so Amazon can keep a track of referrals and purchases coming from her blog. This code is gen...

How to implement dynamic taxonomy navigation / hierarchical drop down list using ajax/jQuery?

I'd like to provide my users a way to navigate a taxonomy by successively drill down ono drop down lists. A simple example would be something like ebay's categories. Say you pick the category "Clothing", the next drop down list would display all the sub-categories under Clothing such as "Shorts", "Pants", "Coats" etc. And this can go on...

syntax error T_PAAMAYIM_NEKUDOTAYIM!

buy.php: <form action="cart.php" method="post"> <?php foreach($product['varieties'] as $variety): ?> <input style="width:10px; margin-left:9px; " name="price[]" type="checkbox" value="<?php echo $variety['price'] . '_' . $variety['size']; ?>" />'; <?php end foreach; ?> </form> cart.php: list($aDoor, size) = split('_', $_POST['p...

Including JavaScript validation in a form submit in PHP

Is it possible to to submit an HTML Form (with a PHP action) and include a javascript onsubmit="VerifyFields()? I am trying to do it now, but it seems that it will do the PHP action and not do the onsubmit. Update: Thanks for all of your help. The problem was that I was putting my VerifyMe() function in the <head></head>, as opposed...

How to use firebug when debugging Javascript entailing focus/blur event handling

I'm trying to use Firebug to debug some Javascript that entails blur and focus event handling, specifically some auto-complete/look-ahead functionality. The issue is that, merely by clicking on the various tabs within Firebug, such as "Console", "Script", "DOM", etcetera, the blur() event in my application is being fired, and then the f...

Is it possible to get the location/position of the mouse cursor on document load event. (in javascript)

Hi All, Just wondering if its possible to get the x/y location of the mouse from the onload event of the document (before any mousemove events). Thanks Guido ...

need mouseover to stay highlighted while viewing the page

On this site: http://www.winteradagency.com/mrw/real_estate.php the navigation uses a javascript that highlights the selections as you mouseover them. Is there an easy way to change the code so that the page the user is on stays highlighted? That helps them see what page they're on and allows for better navigation. thanks ...

access iframe name from inside iframe

I though this would be simple enough but I can't find the answer. I need to know how I can access an iframes name from withing said iframe. I was trying something like this but it's not working. <iframe name="thename"> <script type="text/javascript"> alert(parent.name); </script> </iframe> ...

Serialize a DOM range

Hi, is there any standard/easy way to serialize a DOM Range (and the IE equivalent) with java script. The motivation is to store the current selection for a document together with its HTML code. I thought of using XPath for it, but before I start to reinventing the wheel maybe there is something already working available and I just ...

JavaScript Regex Compile()

Is there a shorter way to write this? var needed = /\$\[\w+\]/mi; needed.compile(/\$\[\w+\]/mi); Why do I have to pass the pattern back into the regex when I've already declared it in the first line?! ...