ajax

Posting to website using captcha

Hi, Currently I'm wondering if there is a way to post to a website using captcha for a human-check. The following question is asked, ofcourse this is done with random numbers: Type this number in digits; 'twohundredandfive': [ input ] The form is sent using AJAX. So when reloading the website the number to be typed changes. A way to...

How a Javascript Accordion Works?

Hi, I would like to create my own accordion component without using any AJAX toolkits, mostly for learning purposes. I am not sure quite where to start with this one. I'm assuming I would begin by creating div's for each section in the accordion. Perhaps each div would contain a header, which would be the actual button selected to mo...

jquery ajax- How to check duplicate name

When i use blur function on textbox to check duplicate name using jquery ajax working fine. Here is code: function duplicate(data){ //alert(data); //successfully gives the value from the text input $.post("test.php", {name: data}, function (data){ if(data){ alert('duplicate name'); } }); } $(fun...

Is the PHP file instantiated on every AJAX call?

I was just wondering how the PHP is behaving in the background. Say I have a PHP which creates an array and populates it with names. $names = Array("Anna", "Jackson" .... "Owen"); Then I have a input field which will send the value on every keypress to the PHP, to check for names containing the value. Will the array be created on e...

Jquery Form Validation and Checking the values with Mysql Database through PHP Script

I have a form which has a input textbox and submit button. On submission of the form the textbox value should get pass to an php script and check the values whether it exists in the Mysql Database. If it exists then we need to show an alert box stating that "Entered Value is already exists, Try something new". If the value not exists th...

Tomcat Comets application returns .jsp page instead of weather data

I have implemented the Comets tutorial at http://www.ibm.com/developerworks/web/library/wa-cometjava/#N100CC It seems like I am getting data returned from the server using the Comets technique - i.e. being pushed to the browser. However I am getting the .jsp page that I use to trigger the Comet event returned, rather than the weather da...

Feed Reader: Should It Always Be Client Side?

Should a browser based Feed Reader always use something on the client side, like Javascript? UPDATE: I mean, specifically, for the Parsing of RSS. If you can offload it to the browser, it seems almost irresponsible to make your server do the work. Still, there are plenty of advantages in my particular situation to doing it server side....

jquery reload div X amount of seconds problem

I know there are a million examples and tutrials on how to reload a DIV in jquery every X amount of seconds, here is the example code I am using right now <script> var auto_refresh = setInterval( function(){ $('#notificationcontainer').load('http://localhost/member/beta_new/notifications.inc.php'). fadeIn("slow"); }, 10000); <...

How do I show a modal dialog while the databind occurs?

I have a form with gridview that is bound to a complex stored procedure (financial data). This query takes about 3 minutes to run and load the gridview. The users get impatient and click "Search" repeatedly, which just makes things worse. As an interim solution, I'd like to show a progress bar, and I found a solution using the ASP.NET A...

Designing Web services for AJAX Consumption

We are in the process of designing/creating restful web services that will be consumed client side using XHR calls from various web pages. These web pages will contain components that will be populated by the data retrieved from the web services. My question is, is it best to design the return data of the web services to match specific...

script.aculo.us autocomplete stuck behind input elements

I've got several script.aculo.us Ajax.Autocomplete controls on a page and when the drop down div is rendered it's always stuck behind the other text boxes on the page, no matter what I do with zIndex and positioning. The problem occurs in IE and FF. Anyone else run into this? Am I missing something, or is this just life with this control...

Page is refreshing when making a jQuery ajax call to an ActionResult

My page is refreshing when I add a Comment in my example. What am I doing wrong? I want the comments in the Details page to update without refreshing the page. I am trying to do something very similar to how the comments are added here on StackOverflow. My Details.aspx has a list of Issues, when clicked goes to a Details/id page which s...

jQuery tabs with both Ajax and static div's

I am posting form data to a page that is using jQuery tabs. Because you can't load post data into an Ajax query (at least without a ton of extra work and making it more insecure), I'm loading the active tab as an actual div on the page. <script type="text/javascript"> $(document).ready(function() { ...

Are AJAX sites crawlable by search engines?

I had always assumed that AJAX-driven content was invisible to search engines. (i.e. content inserted into the DOM via XMLHTTPRequest) For example, in this site, the main content is loaded via AJAX request by the browser: http://www.trustedsource.org/query/terra.cl ...if you view this page with Javascript disabled, the main content a...

text input keyup event with time interval

I have a textbox. I want to call a ajax callback function with some 2 second delay on every keyup. How to implement this? ...

Dealing with clients behind slow connection

I am working on building an ajax based messaging system. The idea is that client will call server every X number of seconds to get latest messages and some other crucial information. The application depends very heavily on this data being delivered to client. I have tested it on all kinds of connections and everything seems to be working...

Is google AJAX Libraries API bypassing same origin policy?

From: https://developer.mozilla.org/En/Same_origin_policy_for_JavaScript The same origin policy prevents a document or script loaded from one origin from getting or setting properties of a document from another origin. This policy dates all the way back to Netscape Navigator 2.0. So why is not the same origin policy enforced?, when a...

Ajax in Asp.net mvc

I am using ajax in mvc for partial page refresh. I create a partial view (ie a seperate user control) for each page and then call partial view by using Html.RenderPartial(). I just want to confirm that do I need to create a seperate user control for every page or is there any other way? Any suggestions would be greatly appreciated. ...

Jquery- Modify Element Value after ajax call

enter scenario: I want to do an ajax call to update the image shown. Example: click to activate, click again to deactivate. Now, image can change correctly when click for first time. After that, if I click the img again, changes won't reflect anymore. Reason, the onclick status still= yes How do I access the hyperlink element to rew...

Is it worth it to use jQuery for Ajax instead of building your own JavaScript?

Aside from the framework, is jQuery worth using rather than creating your own javascript? I've always debated if the framework was better to use than to create your own calls. Are their disadvantages of using it? Sorry for beginner question, I'm trying to feel out if it would be better to use this and create some of the ajaxish workings...