javascript

Please share your experience with JavaScriptMVC, alternatives

Hi I have been reading through the documentation on the JavaScriptMVC framework and it looks interesting. I am wondering if anybody here has used the framework, and with what success. So please share your experience with JavaScriptMVC, if you have any. If you can suggest another MVC javascript framework that is fine to. Best regards, ...

Javascript Object.Watch for all browsers?

Hey all, I was looking for an easy way to monitor an object or variable for changes, and I found Object.Watch that's supported in Mozilla browsers, but not IE. So I started searching around to see if anyone had written some sort of equivalent. About the only thing I've found has been a jQuery plugin (http://plugins.jquery.com/files/jqu...

How to separately recognize the data sent over to php?

Hello I am sending two data to my php from my javascript: http://forum.research.bell-labs.com/zeeshan/publication/phpwithmysql11111.php?rowid=BL09.00001,0 1) BL09.00001 2) 0 How do I recognize them separately in my php? I was trying to do: $job=$_GET[rowid]; echo($job); this gives me both the fields. ...

Determine if browser supports windows integrated authentication

Is there a way to determine if a browser supports NTLM without having NTLM enabled for the particular site or directory in IIS and without showing a login dialog/pop-up? Preferably, determine this using ColdFusion or perhaps some combination of JS and CF. I'd prefer not to restrict this to just IE as other browsers (such as FF) support N...

Ajax problem using MooTools/jQuery - p.onStatusChange is not a function

Hello, I get the following error in firebug in Firefox 3 with both MooTools and jQuery: "p.onStatusChange is not a function". I've noticed this error frequently in firebug since one of the latest updates of FF3. However, it has started appearing with code that hasn't been changed in some time and that was not reporting errors previous...

Replacing part of a string with javascript?

Let's say I have a URL that looks something like this: http://www.mywebsite.com/param1:set1/param2:set2/param3:set3/ I've made it a varaible in my javascript but now I want to change "param2:set2" to be "param2:set5" or whatever. How do I grab that part of the string and change it? One thing to note is where "param2..." is in the ...

Request Address in Javascript

How do you get the address of the page you are on in JavaScript? For example, if i had a script at somesite.com/javascript/home.html and I want to find out the request address (somesite.com/javascript/home.html) how do I get this information in javascript ? ...

How do I keep form data when Back button is clicked.

Hi, I am developing a rails app. (I don't think this is a rails-specific problem) There's a reservation process which is consisted of 3 steps. When a user is on step 2 page, if the user clicks 'Previous' button, the form data in step 1 should be the same as before. I attached "history.go(-1);" to the 'Previous' button. It works on my ...

Returning a value with Ajax.Request

Why does this script result in 'undefined' when the value is returned from the Ajax call? function myShippingApp() { this.shipper = 0; this.init() { this.getShipRate(); alert(this.shipper); } this.getShipRate = function() { var zip = $('zip').value; if(zip == '') { return false; } else { var url = 'getrate.php?zip='+zip; ...

calling a function on one page from a link on another page

I have an html page (django) that contains several divs(each displaying different data) and one div that has navigation links. I'll call this my main page. I have an external .js file (jQuery) that reveals one display div on the main page and simultaneously hides all of the others (except the navigation div) based on which nav link is ch...

When using back button AJAX results have been lost.

So I've set up a pagination system similar to Twitter's where where 20 results are shown and the user can click a link to show the next twenty or all results. The number of results shown can be controlled by a parameter at the end of the URL however, this isn't updated with AJAX so if the user clicks on one of the results and then choose...

handle a file upload from a html page to a separate .NET page

I want to upload a file from a web application. The web application calls web services to access .NET classes, but it's not a .NET application itself. What I want to do is this: upload a file from the web application, and call a separate .NET page to process and handle the uploaded file. It would be easy to do this if I used a php sc...

Is there any shortcut to make css positioning programmatic instead of declarative?

How complicated will it be to implement from scratch? Mainly for layout issues. The reason I want to make it declarative is that I hope to encapsulate it into a javascript class,so that I don't need to cope with css deficits once and again,instead,once for all. ...

What is exactly meaning of "===" in javascript?

Possible Duplicate: Javascript === vs == What's the diff between "===" and "==" ? Thanks! ...

location.hash oddness in Safari 4

location.hash seems to be utterly broken in Safari 4: It can be set initially, but cannot be set in any event as far as I can tell, whether that event is triggered by a user action or a timer. Here's an example (I use jQuery here for brevity, but I can't imagine that this problem is jQuery-specific): <!DOCTYPE html PUBLIC "-//W3C//DTD ...

My RegEx is screwing up the rest of my javascript...

OK, so I'm working with a little regular expression—it's my first time, please, be gentle—and I've run into a problem where I can set a variable with it but if I try to do anything with that variable it causes problems. Here's my script: $(document).ready(function () { var show_number; var url_param; $("a[rel=more]").live(...

[jQuery] How to extract a string from a larger string?

Using jQuery how would I find/extract the "Spartan" string if the outputted HTML page had the following.. <a href="/mytlnet/logout.php?t=e22df53bf4b5fc0a087ce48897e65ec0"> <b>Logout</b> </a> : Spartan<br> ...

Reporting syntax errors in a JSON object with jQuery and/or Javascript

What the best way to report a syntax error when I'm loading a JSON feed with jQuery? I can establish the error reporting settings like this: error: function(xhr){ alert('Request Status: ' + xhr.status + ' Status Text: ' + xhr.statusText + ' ' + xhr.responseText); } however this function doesn't fire when the URL I've called loads ...

jquery or javascript page re-SCAN?

Hi Guys, I have a js script on my blog page that scans the page, looks for special snippets similar to bb code and translates it into an image. For example, i search for all instances of [ ] and replace it with a box image, or all images of :) and replace it with a smiley. I also have a live preview script for my comments. My problem is...

Django Debug toolbar - Prototypejs version

I am a big fan of Django Debug Toolbar But what happened is it totally has got Jquery framework being used for all its UI richness. But my application uses Prototypejs. So browser is actually getting confused to execute(or not executing) a couple of methods written by me. So how do I get pass this? ...