javascript

In an onclick handler, how can I detect whether shift was pressed?

How can I write an onclick handler that does one thing for regular clicks and a different thing for shift-clicks? ...

TinyMCE - external toolbar position

Hello folks, I am trying to work with TinyMCE in creating a multi-textbox, click-to-edit type graphical content editor. I have got TinyMCE to the point where I can add and remove them, position and size them, click to edit them, and so forth - but one thing is bothering me and that is the toolbar. I have an external toolbar that I'm tr...

Can you insert a form onto a page using jQuery's $.load() function?

I have a page where there's a drag and drop table where the order of the rows determines the value of a subtotal. However, it's more complicated than just addition and I would rather not duplicate the logic in JavaScript to update the values. A simple solution would be to reload the whole page using Ajax and then replace the table from ...

Client Side Pagination

What are the best libraries available right now for client side pagination? ...

Javscript / jQuery not executing in IE until the body of the page is moused over

I'm working on a new portfolio site at http://www.nitrohandsome.com, and am using the experience to cut my teeth on jQuery. I'm using the latest build and jcarouselite along with the easing extension on my main page for a nifty carousel effect. It works fine in most browsers, but when I started testing in IE (7 and 8, haven't started opt...

max number of concurrent file downloads in a browser?

Two related questions: What are the maximum number of concurrent files that a web page is allowed to open (e.g., images, css files, etc)? I assume this value is different in different browsers (and maybe per file type). For example, I am pretty sure that javascript files can only be loaded one at a time (right?). Is there a way I ca...

Why does my website crash in IE?

My site works fine in Firefox, but it crashes in IE. I am using alot of jQuery in order to fade in content. When the user clicks on one of the above links a few times, it will crash in IE. Here is my site: Idea Palette I have absolutely no idea why the site crashes in IE. I don't even know where to begin to debug my problem. I don't h...

why does my JScript (windows script host) exit with 0 on an uncaught exception?

I have some JScript which does some stuff with an ODBC connection. An exception was thrown by the ODBC ActiveXObject object and not caught in my script. I expected that the script would exit with an non 0 value but it didn't. Anyone know why this is the case and how to get it to exit with a non 0 value on an uncaught exception? ...

Rhino: restrict Java packages that can be accessed from JavaScript

When embedding a JavaScript interpreter (Rhino) into a Java application (to be able to script that application), how would one go about restricting the Java packages that are available to scripts? For example, only "java.lang.*" should be accessible. ...

How do you remove the x-axis from a bar chart produced by Google's Visualization API?

Referring to the kind of chart shown here: http://code.google.com/apis/visualization/documentation/gallery/barchart.html There doesn't seem to be a simple switch, and changing the axis color to white (on a white background) didn't seem to do anything. I even tried jquery to hide the selectors produced by the api output but no dice. ...

SWFObject Flash Player Script: Wode = Transparent?

I'm using the SWFObject script (http://blog.deconcept.com/swfobject) to embedd a flash object into the following page: http://parramatta.pjgallaghers.com.au/_flashvr/test The flash is from an external supplier and I don't have a whole lot of control over it apart from the embed script. For some reason once the Flash has finished loading...

How to create a modal popup using javascript

hi everyone how to create a modal popup window with background with gray color using javascript and css. can any body show me the example. it's urgent Thanks & Regards Ravi Kumar ...

How can I keep my AJAX call from posting back to the server when using Prototype?

I am trying to keep my AJAX call from posting back to the server when using Prototype. Code: echo " <a href='my.php?action=show&amp;id=".$fid."' onclick=\"return display('".$fid."');\"> "; echo "" .$fname."</a> "; How can I do this? ...

allow digits only for inputs

Hi there I;m trying yo implement a javacript function which will not allow to the user to input anything else than float numbers (digits) This is my approach but I don't know how to improve it in order to allow submition of negatives numbers also (allow '-' key) and work on IE also. function digits_only(evt, form) { var evt = evt...

Set confirmation prompt box's title

Any way to set the confirmation prompt (confirm() in javascript) box's title? At the moment it will display the confirmation prompt box's title to "Windows Internet Explorer" if it run in IE and "the page at http://... said: " in Firefox. ...

window.open not working when attached on onload event in chrome and safari

I have attached some javascript on onload event of the form. this script contains window.open. Although this works fine in all the browsers window.open doesn't open a new window nor it gives nay error message in google chrome and firefox. I want to first check the screen resolution if it is less than 1024 then I would open it in a new w...

How to show some swf file in a webView with the App PictureBrowser?

I saw a App named PictureBrowser in the /Leopard/Developer/Examples/WebKit. I found that this App can show the images only in a webview. Now I want to show some swf flash swf files in this webview , How to do ? I thought this is a problem with javascript , Now I can show the two html file in this ,somebody can help to resolve this proble...

XML Parsing Error: no element found

I am using NiceEdit to format text in text areas, it displays a toolbar over the specified text area, I created a test page, its working, I Response.Write the content of the text area after being formatted, and its okay, I created a break point to see whats being read, it was all fine. Now I moved to the real page where I should impleme...

window.open not working when attached on onload event in chrome and safari

I want to open a new window on onload if a particular condition is satisfied works fine in all others but window is not opening in Chrome and Safari would somebody please find a way to do this Duplicate: window.open not working when attached on onload event in chrome and safari ...

printing in client machine

hi guys.. i am creating a jsp application in which i want to print a file in client (linux os only )machine by sending a command lets say "cat /root/data.txt >/dev/lp0" to the local port of the client systm because my printer is a thermal printer which will print a ticket... the data.txt will be on the client machine.. and i cant use wi...