Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more

Go Back   Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more > Web Design Forum > HTML / CSS

Reply
 
LinkBack Thread Tools Display Modes
Old 11-13-2008, 03:32 PM   #1 (permalink)
Junior Member
 
Join Date: Sep 2008
Posts: 6
Default How To Automatically Add AJAX Functionality to A Static Web Site

There are many AJAX frameworks and tools but sometimes they could be hard to implement into old static websites. clascom.bydust.ajax is a JavaScript based class that allows you to automatically convert a static website into an AJAX based one. A detailed article can be found here.
downloadtube is offline   Reply With Quote
Sponsored Links
Old 11-16-2008, 04:51 PM   #2 (permalink)
Junior Member
 
Join Date: Nov 2008
Posts: 9
Default Re: How To Automatically Add AJAX Functionality to A Static Web Site

you can use this code to fetch data from txt, htm, php files/pages.

Code:
function get_data()
		{
                var myStr = 'var1=data1&var2=data2&var3=data3'; 
		var myurl = 'your_file_here';
		var xmlhttp=new XMLHttpRequest();
		xmlhttp.onreadystatechange= function() 
			{ 
			if (xmlhttp.readyState==4)
			if (xmlhttp.status==200)
				read_data(xmlhttp);
			}
		xmlhttp.open("POST",myurl,true);
		xmlhttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded; charset=UTF-8");
		xmlhttp.send(myStr);
		}

function get_data(req) {
 alert(req.responseText); //this will return your data 
}
mgwalk is offline   Reply With Quote
Old 11-17-2008, 09:22 PM   #3 (permalink)
Member
 
Join Date: Feb 2008
Posts: 321
Default Re: How To Automatically Add AJAX Functionality to A Static Web Site

acording to google: "AJAX can make a site difficult for search engines to index if the technology is not implemented carefully."

you might want to consider it, read more about it: AJAX-enhanced sites - Webmaster Help Center
__________________
Dog Door | Dog Feeder
bogs is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Sponsors

» Links

» Affiliates
Web Hosting
Online Backup Reviews
Marketing Find
Merchant Select
SiteMap Builder
Host Compare

» Links

» Sports Network
Paintball Forum
Football Forum
Hockey Forum
Golf Forum
Boxing Forum
Lacrosse Forum
Baseball Forum
SnowBoarding Forum
Soccer Forum
MMA Forum


All times are GMT -4. The time now is 01:00 PM.


Powered by vBulletin® Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.2
Webmaster Forums