473,385 Members | 1,333 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Newbite Q' help understanding the use of Ajax

196 100+
Never had any expereience with Ajax before today, what im trying to find out how it differs from javascript for example what would be the Ajax version of -

Expand|Select|Wrap|Line Numbers
  1. <script type="text/javascript">
  2. document.write("Hello World!");
  3. </script>
  4.  
I'v also heard Ajax makes it possible to execute javascript code inside a .php script on the servers side.

Another question i had is say i echo'd some javascript in a .php file, now say that .php file was only run using a cron job i.e. it has No User Sided Browser Intereaction at ALL would the javascript/Ajax script work?

Any help in understanding would great, thanks in advance.
Jul 6 '10 #1
2 1042
Dormilich
8,658 Expert Mod 8TB
Never had any expereience with Ajax before today, what im trying to find out how it differs from javascript for example what would be the Ajax version of -

Expand|Select|Wrap|Line Numbers
  1. <script type="text/javascript">
  2. document.write("Hello World!");
  3. </script>
as the example would take up too much space, kindly refer to this AJAX tutorial.


I'v also heard Ajax makes it possible to execute javascript code inside a .php script on the servers side.
no.

to run JavaScript, you need an appropriate environment. PHP doesn’t provide one.

Another question i had is say i echo'd some javascript in a .php file, now say that .php file was only run using a cron job i.e. it has No User Sided Browser Intereaction at ALL would the javascript/Ajax script work?
no. AJAX is all about client-server communication (nothing more, nothing less).
Jul 6 '10 #2
chazzy69
196 100+
Thanks for the info and clearing up the .php matter for me.
Jul 6 '10 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: bobzimuta | last post by:
I'm creating a simple AJAX library. It's an object that will return an array containing the response text or xml. I'm trying to find a way to assign the response as a property of the object, but...
4
by: Redefined Horizons | last post by:
I've been hearing a ot about AJAX lately. I may have to build a web application in the near future, and I was curoius: How does a web application that uses Python compare with one that uses AJAX?...
31
by: Tony | last post by:
I just noticed that prototype.js is one of the files in the Ajax.NET distribution - I'm pretty concerned about this. Does anyone know if this is the same "prototype.js" that is not well-liked...
1
by: Tony Lawrence | last post by:
Probably a lot of you here are already old hands at Ajax, but I haven't started doing this yet. Part of the reason was that I really didn't understand where Ajax would be useful to my own site,...
25
by: meltedown | last post by:
This is supposed ot be an example: http://www.ajaxtutorial.net/index.php/2006/11/30/simple-ajax-using-prototype-part-2/ It says : This example is probably the simplest example you will ever...
17
by: Arjen | last post by:
Hi, I want to reload 2 divs at one click. Ive tried: <a href = "javascript:void(0);"...
4
by: =?Utf-8?B?R2VyaGFyZA==?= | last post by:
I am just stating to use ajax, and have a perfect place to use the accordion control. I have it working fine, but need to have a normal asp button in one of the panes that fires an onclick event...
2
by: =?Utf-8?B?VG9u?= | last post by:
Hello, I want to understand teh benefits of ajax technology. Does anyone has a good website where AJAX EXTENSIONS is worked out so I really understand it. There a 2 main questions: 1) How about...
2
by: soni2926 | last post by:
hi, does anyone know of any good books on ajax and asp.net, one that teaches ajax itself before jumping in atlas? I wanted to get an understanding of ajax and how to use it, most books i've seen...
7
by: Andrew Poulos | last post by:
If I have code that looks like this ajax = function(str) { var val = ""; // do some stuff here return val; }; var foo = ajax("string");
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.