javascript

How to get javascript function data into Php variable

Dear all I am using PHP and Javascript, My Javascript conatains function get_data() function get_Data(){ var name; var job; ..... return buffer; } Now I have PHP with following <?php $i=0; $buffer_data; /*here I need to get the Value from Javascript get_data() of buff...

Make submit work by pressing enter on PHP and Javascript login page

I'm pretty new to Javascript and I'm sure this is an easy fix, but I can't figure it out. I'm using a slightly modified version of the code from this page and I want to make the form work by entering the information and pressing enter rather than having to click the button. FYI I've read this thread and can't work out my own answer f...

Screen scraping through AJAX and javascript

Hi friends, I want to scrape a screen using AJAX and javascript. How is this possible? Need to scrape this : http://www.fedex.com/Tracking?ascend_header=1&amp;clienttype=dotcom&amp;cntry_code=us&amp;language=english&amp;tracknumbers=776812461212825 I had used the technique given in w3school.com, but it's showing "access denied." Why ...

Hosted Yui, Google maps, JQuery - an easy way of monitoring website usage?

The Yahoo Javascript library (YUI), JQuery and less so Google maps all allow you to reference their files using the following format: <script type="text/javascript" src="http://yui.yahooapis.com/2.6.0/build/yahoo-dom-event/yahoo-dom-event.js"&gt;&lt;/script&gt; This does a request for the script from their servers, which will also pas...

Does location.replace() not do a conditional get if last-modified caching is in place?

Here's what I'm seeing: I have a conditional-get caching policy in place (cache-control: private, must-revalidate). It works fine if I'm on the page, then try to hit the browser's refresh button. However, in another part of my site, I use location.replace(url) to go to that page... if I do that, its not makign that check and always ret...

Getting selected value from drop down box in a html form without submit

How to get the text of selected item from a drop down box element in html forms? (using python) How can I store the value to a variable, when I select one item from the drop down box using mouse? (ie. without using a submit button) This is for a application which I am doing in app engine which only supports Python. ...

Most efficient javascript/AJAX toolkit?

What is the most efficient Javascript/AJAX toolkit? ...

Bookmarking with javascript

I want to make a bookmark of my webpage by using javascript code. I want a javascript code to make a bookmark that should be opened in a new window. I am using firefox. ...

WebtextEdit execute Javascript function

Hi, I need to execute an entire javascript function. Found what i was doing wrong: var edit = igedit_getById("FG2100RefNo"); var editText = edit.getText(); alert(!isNaN(editText)); But this only checks & displays a message box. I need to execute the below javascript: <SCRIPT language=Javascript> <!-- function isNumberKey(evt) ...

Setting pretty print tags through javascript

Im trying to get pretty.js to prettify code in CODE tags, using this js: onload_functions.push(function() { var node_list=document.getElementsByTagName('code'); for (i=0; i < node_list.length; i++) { node_list[i].setAttribute('class','prettyprint'); } prettyPrint(); }); This works fine for Firefox :) but IE's havi...

Is there a way to detect the start of a download in JavaScript?

In our current project we are providing a PDF download that can be customized by the user through an HTML form he submits. It takes several seconds to dynamically generate the PDF and I'd like to visualize this, e.g. by disabling the submit button until the download starts. Unfortunately, I couldn't find a way to detect when the download...

Copy-pasting image into JavaScript rich-text editor

Hi, I'm looking for a rich-text editor control that has some way of allowing users to copy-paste images into it, a la Google Mail. I guess I'm hoping there's some way to communicate the binary contents of an image on the clipboard to the browser (and perhaps store these contents in a hidden element somewhere that I can access). If you c...

how to load a div into html using jquery

I'm trying to load a div into a page based on a change in the drop down. I either want to show a div which has state/zip or province/postal_code, (each is a file) but I am getting a "406 Not Acceptable [http://localhost/profiles/residency]" Here is my JQuery code: $(function(){ $("#profile_country").change(onSelectChange); }); fun...

JQuery resizable with a knob

I am using JQuery Resizable - http://docs.jquery.com/UI/Resizable/resizable#options - and i want to use a knob instead of the borders (my knob is a button in the bottom right). I see that in options I have a KnobHandles, that I have to set to true. Where do I set my handle? I tried to set it in the handles option but it is not working. M...

Need help with an AJAX workflow

Sorry I couldn't be more descriptive with the title, I will elaborate fully below: I have a web application that I want to implement some AJAX functionality into. Currently, it is running ASP.NET 3.5 with VB.NET codebehind. My current "problem" is I want to dynamically be able to populate a DIV when a user clicks an item on a list. T...

Good choice for a lightweight checksum algorithm?

Hi all, I find myself needing to generate a checksum for a string of data, for consistency purposes. The broad idea is that the client can regenerate the checksum based on the payload it recieves and thus detect any corruption that took place in transit. I am vaguely aware that there are all kinds of mathematical principles behind thi...

TreeView Update

Hi, I have a treeview control on an aspx page. The data comes from database and I bind it to treeview control programmatically. (Parent-Child relationship in database of course) Well and I added a textbox which I use to add new child under the selected node and it works also good but so as to see the new added node, I have to refresh a...

trying to find a javascript dropdown control

I'm looking for a dropdown similar to the openid site-select dropdown on the stackoverflow login page: ... and for now I'd rather not sit down and write one myself. I'm looking for one written for inclusion in plain html/javascript (php code), must be free for commercial use. ...

"Pin" a class to the selected radio button?

I'm trying to add a class to the selected radio input and then remove that class when another radio of the same type is selected The radio buttons have the class 'radio_button' but i can't get the class to change with the below code. jQuery(".radio_button").livequery('click',function() { $('input.radio_button :radio').focus...

Help with regex in javascript

I have this sample text, which is retrieved from the class name on an html element: rich-message err-test1 erroractive rich-message err-test2 erroractive rich-message erroractive err-test1 err-test2 rich-message erroractive I am trying to match the "test1"/"test2" data in each of these examples. I am currently using the following rege...