javascript

what is showErros function do in jquery validation

I am using Jquery validation plugin to validate my form at client side. I need to know what showError function does. It takes two parameters errorMap and errorList, what are these parameters. ...

Create HTML file with JavaScript

Hi, I'm looking for a way to use a JavaScript function to create a new HTML file in the local directory. Is this possible? Thanks ...

ASP.NET JavaScript from MasterPage doesn't work

Hello. I put common(for all my content pages) js to head section at my masterpage. <head runat="server"> <script type="text/javascript" src="../Scripts/jquery-1.4.1.js"></script> <script type="text/javascript" src="../Scripts/jquery.corner.js?v2.11"></script> <script type="text/javascript" src="../Scripts/jquery.timers.js"></script>...

how to hide broweser address bar using javascript on client side using java script in onload function of body

how to hide broweser address bar using javascript on client side using java script in onload function of body ...

parent window close through child window in ie8

Hello I want to close parent window through child window. For this purpose I m using window.opener.close(). but it is not working in IE8. thanks ...

How to get request url in a jQuery $.get/ajax request

I have the code: $.get('http://www.example.org', {a:1,b:2,c:3}, function(xml) {}, 'xml'); Is there a way, to fetch the url it used to make the request after the request has been made(in the callback or otherwise)? I would want the output: http://www.example.org?a=1&amp;b=2&amp;c=3 ...

font-color of disabled input box in IE

how to set the font color of an input box which is disabled (IE only) ...

Disable button in update panel on async postback

I have multiple update panels with various asp buttons on a single page. I want to disable the buttons which caused the postback in update panel untill it completes. Is there a way to avoid using a third party control for this? through JQuery or any other method ? ...

My Return false is not working in this code..using jquery

$(function () { $('#form4').submit(function () { var val = $("#txtNewServiceTypeCategory").val(); $("#ServiceTypeCategoryName").children("option").each(function () { var $this = $(this); if (val == $this.val()) { alert("ServiceTypeCategory Name is already added! Please Choose D...

Javascript appear in title tag

Hi, is it possible to have javascript appear in the title tag on a web page? Cheers Jules ...

How do I prevent the user from entering '>' and '<' characters with javascript?

I want to prevent user from entering '>' and '<' character. How should i do this? I tried to implement this by ( via javascript) detecting their keycodes but since '>' and '.' have the same keycode, it also prevented '.' from being entered. The same happens for the ',' and '<' characters. How should i do this? Below is what i have tried...

Algorithm problem: Packing rods into a row

Alright, this might be a tricky problem. It is actually an analogy for another similar problem relating to my actual application, but I've simplified it into this hypothetical problem for clarity. Here goes: I have a line of rods I need to be sorted. Because it is a line, only 1 dimension needs to be of concern. Rods are different l...

jQuery UI DatePicker - Departing Date and Returning Date

Hi, Basically what I'm trying to do is create two DatePicker fields. The first is the departing date and the second is the returning date. So for example if someone was looking for a holiday that was a 5 night stay, when they loaded the page the dates would look as follows: 01/12/2010 | Calendar Icon 07/12/2010 | Calendar Icon For the...

Jgrid Save cell on button click

HI, I am using afterSaveCell that fires if we modifies the cell then it get fires. My scenario is that i m doing batch update to the database on save change button. But when user edit the cell and got to the other cell then i log the modification in a array. But if user edit the cell and click on the Save Change button the cell focus n...

How to Hide/Encrypt Javascript(which is visible to client in his/her browser)

Possible Duplicates: hide javascript from showing up in browser How can I obfuscate JavaScript? How to Hide/Encrypt Javascript(which is visible to client in his/her browser) ...

How to suppress javascript exception?

In my application i am getting the content of some other domain's page. Along with the content it is running the javascript associated with the particular page. In the javascript code "document.selection.createRange()" is written which is throwing exception at run time in IE (since in IE due to security concern you can't change iframe's ...

How to restrict drag (disable) in the block?

Hello, How to restrict drag (disable) in the block? Full example <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" type="text/javascript"></script> <script type="text/javascript"> $(function(){ var x = 0, setElementMove = 0, getElementMove = $('#drag'); getElementMove.mousedown(...

Haxe for javascript without global namespace pollution?

I've known about haxe for a while, but never really played with it until yesterday. Being curious, I decided to port showdown.js, a javascript port of markdown.pl, to haxe. This was pretty straightforward, and the javascript it generates seems to run fine (edit: If you want to see it in action, check it out here). However, I noticed tha...

How to put Silverlight application inside Flash file(swf - browser independet which run with flash player)

Hi every body, i have created a silverlight application , but i need to embed it to a Flash file(swf) which it runs with Flash Player ( whithout using browser), I had found a solutions to call it using javascript, but it still needs my flash file run inside the browser, dose any one can help me, Either to run js inside swf (without need...

How to allow input type=file to accept only image files

I need to upload file which is an image.I am using .But it will accept all types of files.I need only files with extensions such as .jpg,.jif etc.How can I make the upload dialogue to select only image files . Thanks in advance ...