javascript

Is javascript reliable for preventing actions on the front end such as form submission?

I have a webservice that I need called, the result of which determines whether or not the user is allowed to submit the form. Since this call is from javascript and not from code behind is it not reliable? Is there any way the user can get around the check -- by either going in with firebug and enabling the submit button, somehow making...

javascript save dynamic object in someplace for resuse byother methods later on!

i want to save javascript object in a place, so if selected row is getting trigger, i can use that row object again by different methods. maybe saving it in input hidden field can work? but not sure.. how would you do it? im trying to do following, but that dont work, obviously my code is wrong, but i want to show you, so you can maybe...

Start a flash game when the user clicks

I want to put two miniclip.com games in my website but they both start at the same time. How can I get them to start separately when the user clicks them? ...

jQuery autocomplete special character (Norwegian) problems

I'm using jQuery's autocomplete function on my Norwegian site. When typing in the Norwegian characters æ, ø and å, the autocomplete function suggests words with the respective character, but not words starting with the respective character. It seems like I've to manage to character encode Norwegian characters in the middle of the words, ...

eval creating problems in evaluating

i am using eval to convert string decimals to decimals. eval("000451.01"); When i am using the above statement javascript it throws exception 'expected ;' and when using eval("000451"); it gives me a different result. anyone has got any idea?? ...

JavaScript Programming Help

Hello everyone, I have some previous programming knowledge but need some help with this. I need to create a JavaScript bookmarklet like the one that Instapaper.com has. I want for this bookmarklet to have the following functionality and look: Popup on the corner of the page (which I could specify in the code) Display a count-up timer ...

Opener Window... Navigate To URL?

Ok so my main window is going to open up a popup window, the popup window is going to contain a Flex app. The flex app is going to need to navigatToURL() but also send POST data along with it. However instead of the popup-window navigating, I would like to main-window to navigate to the url and recieve the post vars. Is this possible?...

JQuery Class Selector still firing after removeClass.

I am creating a little voting mechanism that sends a quick database timestamp through AJAX. A series of buttons with the class "vote" are the triggers to vote, while there is text below to show how many "votes" are for that particular item. After I run the AJAX method from the click event, I remove the "vote" class such that there cann...

How to implement apply pattern in Javascript

What is apply invocation pattern in Javascript in reference to function invocation patterns and how can I use it? What are the benefits of using this invocation pattern. ...

How to highlight a table cell (TD) when radio button is clicked with JavaScript/JQuery?

I'm developing an online baseball/softball scorebook application. I want to visually change the CSS of the specific table cell (a specific TD) when the user changes the value of one of the radio buttons inside that TD is selected. Here is a JPG of what the table looks like: http://www.ppgeez.com/images/gt_ab.jpg There are 12 players ...

How to get the onclick "attribute event" return value in "property event" ?

consider this code sample : <a href="some url" onclick="confirm('ok to proceed ?')">bla</a>` <script type="text/javascript"> $(document).ready(function() { $("a").live("click", function (event) { // In that function, I want to get // the "confirm" return value ...

Is there any non-web application of JavaScript?

As far as I know, JavaScript is a general purpose language but mostly it is used for Web Applications. I am curious to know whether anyone is using JavaScript for non-Web apps. Also, are there any tools available for non-Web application development? ...

Using Scanner/Parser/Lexer for script collation

I'm working on a JavaScript collator/compositor implemented in Java. It works, but there has to be a better way to implement it and I think a Lexer may be the way forward, but I'm a little fuzzy. I've developed a meta syntax for the compositor which is a subset of the JavaScript language. As far as a typical JavaScript interpreter is c...

setInterval and long running functions

How does setInterval handle callback functions that take longer than the desired interval? I've read that the callback may receive the number of milliseconds late as its first argument, but I was unable to find why it would be late (jitter, or long running functions). And the wonderful follow up, does it behave differently for the comm...

Enforce semicolons in my Javascript?

How best does the developer who's decided he likes semicolons at the end of his Javascript statements enforce that expectation technically for himself? I'm using Visual Studio (ASP.NET webapps), but I'd love to hear about solutions for any environment. ...

Wufoo date form javascript not working

Hye guys, I installed a wufoo form on one of my websites. It links to a javascript file that I have referenced from their server. The date picker is supposed to work by opening a little pop-up modal with a calendar where the user can click on a date and have the fields auto-updated. This date picker button on this site is a little calen...

Exceptionally slow javascript performance on one laptop out of a few dozen

I'm working on a web application using a pretty heavy amount of javascript. On the majority of computers (all running IE6...unfortunately), the average document.ready time is about 2 seconds. While this isn't great, it's at least useable. The problem is one computer has ridiculously slow javascript document.ready times. Something that w...

Get svg graphics size when width/height attributes on <svg> are not set

So how to get the size of an SVG file with javascript when width and height are not set on the svg element? The svg is a string, but could be made a DOM if necessary. ...

Change browser time

Is there any way to change the browser's time without manipulating the system clock? ...

CSS Navigation Menu Using Sprite: How to highlight current page's tab/button?

Hi all, I've built a CSS navigation menu using a sprite, very similar to the one on Apple's website. I've got it working fine, such that it changes to the right position on the image on hover and mousedown (all using CSS), but I'm having a hard time figuring out how to make a button stay highlighted once it's clicked. I have a row in my...