SlideShare a Scribd company logo
What is Ajax?
• "Asynchronous JavaScript and XML"
• New name for an old technique:
• JavaScript + DHTML + XMLHttpRequest
• In use since at least 1997
• I've used it since 2000
• Finally someone gave it a name
• Already enabled in yourWeb server and browser
• Use JavaScript asynchronously behind the scenes
to load additional data (typically XML) without
discarding and reloading the entireWeb page.
Why useAjax?
• Your users will soon demand it
• Not just another cool (geeky) technology
• Very user-visible effect
• Rich UI experience in aWeb page
• Portable across browsers
• Plus, all advantages of zero-installWeb app
• No install done for this demo
• No "DLL Hell“
Continued…
Why useAjax?
• Client/Server Apps:
• Dynamic data
• Static forms, controls, code, etc.
• Efficient, but not flexible
• Traditional Web Apps:
• Dynamic data
• Dynamic forms, controls, code, etc.
• Flexible, but inefficient, and noticeably slow
• Ajax Apps:
• Dynamic data
• Static or dynamic forms, controls, code, etc.
• Best of both worlds.
Continued…
Why useAjax?
• Geeky reasons:
• Multithreaded data retrieval fromWeb servers
• Pre-fetch data before needed
• Progress indicators
• Appearance of speed
• Avoids need for setTimeout()
• Less bandwidth required; less server load
• Reload partial page, not entire page
• Load data only, not even partial page
How much to useAjax?
• As little or as much as you like
• No need to abandon what you already do
• One more item in your "bag of tricks"
• Start by jazzing up your existing UI
How to useAjax?
Simple!
Use the
XMLHttpRequest
Object
XMLHttpRequest Methods
• open (“method”, “URL”, [async, username, password])
• Assigns destination URL, method, etc.
• send (params)
• Sends request including postable string or DOM object data
• abort ()
• Terminates current request
• getAllResponseHeaders ()
• Returns headers (name/value pairs) as a string
• getResponseHeader (“header”)
• Returns value of a given header
• setRequestHeader (“label”,”value”)
• Sets Request Headers before sending
Continued…..
XMLHttpRequest Properties
• onreadystatechange
• Event handler (your code) that fires at each state change
• readyState
0 = uninitialized 3 = interactive (some data has been returned)
1 = loading (broken in IE 6.0)
2 = loaded 4 = complete
• status
• HTTP Status returned from server: 200-299 = OK
• responseText
• String version of data returned from server
• responseXML
• XML DOM document of data returned
• statusText
• Status text returned from server
Simple Example
var req = new XMLHttpRequest();
req.onreadystatechange = myHandler;
req.open("GET", "servlet", true);
req.send("p1=abc");
...
function myHandler() {
if (req.readyState == 4) {
doSomethingWith(req.responseXML);
}
else if (req.readyState == 3) {
showProgressIndicator();
}
}
Demos
• Simple demo
• More demos
• Google Suggest
• Google Maps
• Language translation
• Mouse gesture as password
• Typing speed as password
• Classified ads tied to map
• "Mashups"
Security Issues
• Can only hit domain theWeb page came from
• Cannot access a 3rd partyWeb Service
• However:
• You can wrap those requests through your own server
• User can allow access to specific sites via browser security settings
• IFRAME can access any site (instead of XMLHttpRequest)
AdvancedTopics
• XSLT and XPath support (Sarissa)
• Serializing Java Beans as XML
• XMLBeans, JAXB, Zeus, Jbind,Castor, Betwixt
• Serializing Java Beans as JavaScript objects
• JSON -- JavaScript Object Notation
• 2-way Mapping of Java Beans to JavaScript objects
• DWR -- DirectWeb Remoting
• Ajax Component Libraries andToolkits:
• Dojo, Prototype, HTC, XBL
• Implemented as JSP tag libraries or pure JavaScript
• Ajax Frameworks
• Ajax Patterns
We also provide classroom and online training classes
For More Details
www.asit.amcsquare.com
Wise Machines India Pvt Ltd
#360, Sri Sai Padma Arcade,
Varthur Main Road,
Ramagondanahalli,
Whitefiled ,Bangalore – 560066.
We also having Branches in Hyderabad & Chennai

More Related Content

What's hot

Introduction to ajax
Introduction  to  ajaxIntroduction  to  ajax
Introduction to ajax
Pihu Goel
 
Headless drupal + react js Oleksandr Linyvyi
Headless drupal + react js   Oleksandr LinyvyiHeadless drupal + react js   Oleksandr Linyvyi
Headless drupal + react js Oleksandr Linyvyi
DrupalCamp Kyiv
 
Ajax
AjaxAjax
Asp.Net 3.5 Part 2
Asp.Net 3.5 Part 2Asp.Net 3.5 Part 2
Asp.Net 3.5 Part 2
asim78
 
Ajax and PHP
Ajax and PHPAjax and PHP
Ajax and PHP
John Coggeshall
 
Jquery Ajax
Jquery AjaxJquery Ajax
Jquery Ajax
Anand Kumar Rajana
 
Ajax
AjaxAjax
Ajax ppt - 32 slides
Ajax ppt - 32 slidesAjax ppt - 32 slides
Ajax ppt - 32 slides
Smithss25
 
Building Real Time Applications with ASP.NET SignalR 2.0 by Rachel Appel
Building Real Time Applications with ASP.NET SignalR 2.0 by Rachel AppelBuilding Real Time Applications with ASP.NET SignalR 2.0 by Rachel Appel
Building Real Time Applications with ASP.NET SignalR 2.0 by Rachel Appel
.NET Conf UY
 
Ajax
AjaxAjax
PHP - Introduction to PHP AJAX
PHP -  Introduction to PHP AJAXPHP -  Introduction to PHP AJAX
PHP - Introduction to PHP AJAX
Vibrant Technologies & Computers
 
Asynchronous JavaScript & XML (AJAX)
Asynchronous JavaScript & XML (AJAX)Asynchronous JavaScript & XML (AJAX)
Asynchronous JavaScript & XML (AJAX)
Adnan Sohail
 
Building Modern Websites with ASP.NET by Rachel Appel
Building Modern Websites with ASP.NET by Rachel AppelBuilding Modern Websites with ASP.NET by Rachel Appel
Building Modern Websites with ASP.NET by Rachel Appel
.NET Conf UY
 
MongoDB.local Berlin: Building a GraphQL API with MongoDB, Prisma and Typescript
MongoDB.local Berlin: Building a GraphQL API with MongoDB, Prisma and TypescriptMongoDB.local Berlin: Building a GraphQL API with MongoDB, Prisma and Typescript
MongoDB.local Berlin: Building a GraphQL API with MongoDB, Prisma and Typescript
MongoDB
 
MongoDB.local Berlin: App development in a Serverless World
MongoDB.local Berlin: App development in a Serverless WorldMongoDB.local Berlin: App development in a Serverless World
MongoDB.local Berlin: App development in a Serverless World
MongoDB
 
APIdays Paris 2018 - Building scalable, type-safe GraphQL servers from scratc...
APIdays Paris 2018 - Building scalable, type-safe GraphQL servers from scratc...APIdays Paris 2018 - Building scalable, type-safe GraphQL servers from scratc...
APIdays Paris 2018 - Building scalable, type-safe GraphQL servers from scratc...
apidays
 
Powershell For Developers
Powershell For DevelopersPowershell For Developers
Powershell For Developers
Ido Flatow
 
Azure Container Apps
Azure Container AppsAzure Container Apps
Azure Container Apps
ICS
 
Using Ajax In Domino Web Applications
Using Ajax In Domino Web ApplicationsUsing Ajax In Domino Web Applications
Using Ajax In Domino Web Applicationsdominion
 

What's hot (20)

Introduction to ajax
Introduction  to  ajaxIntroduction  to  ajax
Introduction to ajax
 
Headless drupal + react js Oleksandr Linyvyi
Headless drupal + react js   Oleksandr LinyvyiHeadless drupal + react js   Oleksandr Linyvyi
Headless drupal + react js Oleksandr Linyvyi
 
Ajax
AjaxAjax
Ajax
 
Asp.Net 3.5 Part 2
Asp.Net 3.5 Part 2Asp.Net 3.5 Part 2
Asp.Net 3.5 Part 2
 
Ajax and PHP
Ajax and PHPAjax and PHP
Ajax and PHP
 
Jquery Ajax
Jquery AjaxJquery Ajax
Jquery Ajax
 
Ajax
AjaxAjax
Ajax
 
Ajax ppt - 32 slides
Ajax ppt - 32 slidesAjax ppt - 32 slides
Ajax ppt - 32 slides
 
Building Real Time Applications with ASP.NET SignalR 2.0 by Rachel Appel
Building Real Time Applications with ASP.NET SignalR 2.0 by Rachel AppelBuilding Real Time Applications with ASP.NET SignalR 2.0 by Rachel Appel
Building Real Time Applications with ASP.NET SignalR 2.0 by Rachel Appel
 
Ajax
AjaxAjax
Ajax
 
PHP - Introduction to PHP AJAX
PHP -  Introduction to PHP AJAXPHP -  Introduction to PHP AJAX
PHP - Introduction to PHP AJAX
 
Asynchronous JavaScript & XML (AJAX)
Asynchronous JavaScript & XML (AJAX)Asynchronous JavaScript & XML (AJAX)
Asynchronous JavaScript & XML (AJAX)
 
Building Modern Websites with ASP.NET by Rachel Appel
Building Modern Websites with ASP.NET by Rachel AppelBuilding Modern Websites with ASP.NET by Rachel Appel
Building Modern Websites with ASP.NET by Rachel Appel
 
MongoDB.local Berlin: Building a GraphQL API with MongoDB, Prisma and Typescript
MongoDB.local Berlin: Building a GraphQL API with MongoDB, Prisma and TypescriptMongoDB.local Berlin: Building a GraphQL API with MongoDB, Prisma and Typescript
MongoDB.local Berlin: Building a GraphQL API with MongoDB, Prisma and Typescript
 
MongoDB.local Berlin: App development in a Serverless World
MongoDB.local Berlin: App development in a Serverless WorldMongoDB.local Berlin: App development in a Serverless World
MongoDB.local Berlin: App development in a Serverless World
 
APIdays Paris 2018 - Building scalable, type-safe GraphQL servers from scratc...
APIdays Paris 2018 - Building scalable, type-safe GraphQL servers from scratc...APIdays Paris 2018 - Building scalable, type-safe GraphQL servers from scratc...
APIdays Paris 2018 - Building scalable, type-safe GraphQL servers from scratc...
 
Powershell For Developers
Powershell For DevelopersPowershell For Developers
Powershell For Developers
 
Azure Container Apps
Azure Container AppsAzure Container Apps
Azure Container Apps
 
Using Ajax In Domino Web Applications
Using Ajax In Domino Web ApplicationsUsing Ajax In Domino Web Applications
Using Ajax In Domino Web Applications
 
Ajax
Ajax Ajax
Ajax
 

Viewers also liked

Christoph scheibner english profile
Christoph scheibner   english profileChristoph scheibner   english profile
Christoph scheibner english profile
cs381
 
Human Population Growth
Human Population GrowthHuman Population Growth
Human Population Growth
Jamaica Olazo
 
Cata arte!!
Cata arte!!Cata arte!!
Cata arte!!
catalinalastra
 
Schools around the world
Schools around the worldSchools around the world
Schools around the world
LuciaAbalos
 
ученический проект
ученический проектученический проект
ученический проект
davidovanat
 
Using Gobi Notifications
Using Gobi NotificationsUsing Gobi Notifications
Using Gobi Notifications
Lauren Marshall
 
Laboratorio estudio no 9569
Laboratorio estudio no 9569Laboratorio estudio no 9569
Laboratorio estudio no 9569
JUAN GARAVITO
 
Fekdr expérience du terrain
Fekdr expérience  du terrain  Fekdr expérience  du terrain
Fekdr expérience du terrain
GADR2014
 
Poland
PolandPoland
Poland
Kasia_Z-D
 
Guia positiva 10
Guia positiva 10Guia positiva 10
Guia positiva 10
Angelys De Alba
 
La escultura
La esculturaLa escultura
La escultura
vanecch
 
Sistema endocrino
Sistema endocrinoSistema endocrino
Sistema endocrino
Rabel Ruiz de Sulbaran
 

Viewers also liked (13)

Christoph scheibner english profile
Christoph scheibner   english profileChristoph scheibner   english profile
Christoph scheibner english profile
 
Human Population Growth
Human Population GrowthHuman Population Growth
Human Population Growth
 
Cata arte!!
Cata arte!!Cata arte!!
Cata arte!!
 
Schools around the world
Schools around the worldSchools around the world
Schools around the world
 
ученический проект
ученический проектученический проект
ученический проект
 
Using Gobi Notifications
Using Gobi NotificationsUsing Gobi Notifications
Using Gobi Notifications
 
Laboratorio estudio no 9569
Laboratorio estudio no 9569Laboratorio estudio no 9569
Laboratorio estudio no 9569
 
Fekdr expérience du terrain
Fekdr expérience  du terrain  Fekdr expérience  du terrain
Fekdr expérience du terrain
 
Poland
PolandPoland
Poland
 
Guia positiva 10
Guia positiva 10Guia positiva 10
Guia positiva 10
 
KUMAR PREM RANJAN CV
KUMAR PREM RANJAN CVKUMAR PREM RANJAN CV
KUMAR PREM RANJAN CV
 
La escultura
La esculturaLa escultura
La escultura
 
Sistema endocrino
Sistema endocrinoSistema endocrino
Sistema endocrino
 

Similar to Learn AJAX at ASIT

AJAX.pptx
AJAX.pptxAJAX.pptx
AJAX.pptx
Ganesh Chavan
 
Ajax tutorial by bally chohan
Ajax tutorial by bally chohanAjax tutorial by bally chohan
Ajax tutorial by bally chohan
WebVineet
 
ITI006En-AJAX
ITI006En-AJAXITI006En-AJAX
ITI006En-AJAX
Huibert Aalbers
 
Synapseindia dot net development web applications with ajax
Synapseindia dot net development  web applications with ajaxSynapseindia dot net development  web applications with ajax
Synapseindia dot net development web applications with ajax
Synapseindiappsdevelopment
 
Introduction to Node.js
Introduction to Node.jsIntroduction to Node.js
Introduction to Node.jsRichard Lee
 
Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...
Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...
Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...
SPTechCon
 
Unit-5.pptx
Unit-5.pptxUnit-5.pptx
Unit-5.pptx
itzkuu01
 
Windows 8 Apps and the Outside World
Windows 8 Apps and the Outside WorldWindows 8 Apps and the Outside World
AD102 - Break out of the Box
AD102 - Break out of the BoxAD102 - Break out of the Box
AD102 - Break out of the Box
Karl-Henry Martinsson
 
Rethinking Syncing at AltConf 2019
Rethinking Syncing at AltConf 2019Rethinking Syncing at AltConf 2019
Rethinking Syncing at AltConf 2019
Joe Keeley
 
Ajax
AjaxAjax
Ajax Technology
Ajax TechnologyAjax Technology
Ajax Technology
Zia_Rehman
 
Ajax workshop
Ajax workshopAjax workshop
Ajax workshop
WBUTTUTORIALS
 
SharePoint Saturday The Conference DC - How the client object model saved the...
SharePoint Saturday The Conference DC - How the client object model saved the...SharePoint Saturday The Conference DC - How the client object model saved the...
SharePoint Saturday The Conference DC - How the client object model saved the...Liam Cleary [MVP]
 

Similar to Learn AJAX at ASIT (20)

Introduction to AJAX
Introduction to AJAXIntroduction to AJAX
Introduction to AJAX
 
AJAX.pptx
AJAX.pptxAJAX.pptx
AJAX.pptx
 
Ajax tutorial by bally chohan
Ajax tutorial by bally chohanAjax tutorial by bally chohan
Ajax tutorial by bally chohan
 
Ajax
AjaxAjax
Ajax
 
ITI006En-AJAX
ITI006En-AJAXITI006En-AJAX
ITI006En-AJAX
 
Ajax
AjaxAjax
Ajax
 
Ajax
AjaxAjax
Ajax
 
Synapseindia dot net development web applications with ajax
Synapseindia dot net development  web applications with ajaxSynapseindia dot net development  web applications with ajax
Synapseindia dot net development web applications with ajax
 
Introduction to Node.js
Introduction to Node.jsIntroduction to Node.js
Introduction to Node.js
 
Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...
Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...
Tutorial, Part 2: SharePoint 101: Jump-Starting the Developer by Rob Windsor ...
 
Unit-5.pptx
Unit-5.pptxUnit-5.pptx
Unit-5.pptx
 
AJAX
AJAXAJAX
AJAX
 
Windows 8 Apps and the Outside World
Windows 8 Apps and the Outside WorldWindows 8 Apps and the Outside World
Windows 8 Apps and the Outside World
 
AD102 - Break out of the Box
AD102 - Break out of the BoxAD102 - Break out of the Box
AD102 - Break out of the Box
 
Rethinking Syncing at AltConf 2019
Rethinking Syncing at AltConf 2019Rethinking Syncing at AltConf 2019
Rethinking Syncing at AltConf 2019
 
Ajax
AjaxAjax
Ajax
 
Ajax
AjaxAjax
Ajax
 
Ajax Technology
Ajax TechnologyAjax Technology
Ajax Technology
 
Ajax workshop
Ajax workshopAjax workshop
Ajax workshop
 
SharePoint Saturday The Conference DC - How the client object model saved the...
SharePoint Saturday The Conference DC - How the client object model saved the...SharePoint Saturday The Conference DC - How the client object model saved the...
SharePoint Saturday The Conference DC - How the client object model saved the...
 

More from ASIT

Asit education student review
Asit education student reviewAsit education student review
Asit education student review
ASIT
 
ASIT EDUCATION STUDENT REVIEWS
ASIT EDUCATION STUDENT REVIEWSASIT EDUCATION STUDENT REVIEWS
ASIT EDUCATION STUDENT REVIEWS
ASIT
 
Asit Education
Asit EducationAsit Education
Asit Education
ASIT
 
Asit Education Student Reviews
Asit Education Student ReviewsAsit Education Student Reviews
Asit Education Student Reviews
ASIT
 
Asit education Student review
Asit education Student reviewAsit education Student review
Asit education Student review
ASIT
 
ASIT EDUCATION REVIEW
ASIT EDUCATION REVIEWASIT EDUCATION REVIEW
ASIT EDUCATION REVIEW
ASIT
 
Asit Never Cheats Unemployes
Asit Never Cheats UnemployesAsit Never Cheats Unemployes
Asit Never Cheats UnemployesASIT
 
Latest News on Amc Square Asit
Latest News on Amc Square AsitLatest News on Amc Square Asit
Latest News on Amc Square Asit
ASIT
 
Asit amc never cheats students
Asit amc never cheats studentsAsit amc never cheats students
Asit amc never cheats studentsASIT
 
News on AMC Square ASIT
News on AMC Square ASITNews on AMC Square ASIT
News on AMC Square ASIT
ASIT
 
News on Asit Amc
News on Asit AmcNews on Asit Amc
News on Asit Amc
ASIT
 
Time Management
Time ManagementTime Management
Time Management
ASIT
 
learn Ruby at ASIT
learn Ruby at ASITlearn Ruby at ASIT
learn Ruby at ASIT
ASIT
 
introduction to Mongodb
introduction to Mongodbintroduction to Mongodb
introduction to Mongodb
ASIT
 
introduction to hadoop
introduction to hadoopintroduction to hadoop
introduction to hadoop
ASIT
 
ASIT REVIEWS
ASIT REVIEWSASIT REVIEWS
ASIT REVIEWS
ASIT
 
ASIT REVIEWS
ASIT REVIEWSASIT REVIEWS
ASIT REVIEWS
ASIT
 
Learn REST API at ASIT
Learn REST API at ASITLearn REST API at ASIT
Learn REST API at ASIT
ASIT
 
Learn C LANGUAGE at ASIT
Learn C LANGUAGE at ASITLearn C LANGUAGE at ASIT
Learn C LANGUAGE at ASIT
ASIT
 
Learn Advanced JAVA at ASIT
Learn Advanced JAVA at ASITLearn Advanced JAVA at ASIT
Learn Advanced JAVA at ASIT
ASIT
 

More from ASIT (20)

Asit education student review
Asit education student reviewAsit education student review
Asit education student review
 
ASIT EDUCATION STUDENT REVIEWS
ASIT EDUCATION STUDENT REVIEWSASIT EDUCATION STUDENT REVIEWS
ASIT EDUCATION STUDENT REVIEWS
 
Asit Education
Asit EducationAsit Education
Asit Education
 
Asit Education Student Reviews
Asit Education Student ReviewsAsit Education Student Reviews
Asit Education Student Reviews
 
Asit education Student review
Asit education Student reviewAsit education Student review
Asit education Student review
 
ASIT EDUCATION REVIEW
ASIT EDUCATION REVIEWASIT EDUCATION REVIEW
ASIT EDUCATION REVIEW
 
Asit Never Cheats Unemployes
Asit Never Cheats UnemployesAsit Never Cheats Unemployes
Asit Never Cheats Unemployes
 
Latest News on Amc Square Asit
Latest News on Amc Square AsitLatest News on Amc Square Asit
Latest News on Amc Square Asit
 
Asit amc never cheats students
Asit amc never cheats studentsAsit amc never cheats students
Asit amc never cheats students
 
News on AMC Square ASIT
News on AMC Square ASITNews on AMC Square ASIT
News on AMC Square ASIT
 
News on Asit Amc
News on Asit AmcNews on Asit Amc
News on Asit Amc
 
Time Management
Time ManagementTime Management
Time Management
 
learn Ruby at ASIT
learn Ruby at ASITlearn Ruby at ASIT
learn Ruby at ASIT
 
introduction to Mongodb
introduction to Mongodbintroduction to Mongodb
introduction to Mongodb
 
introduction to hadoop
introduction to hadoopintroduction to hadoop
introduction to hadoop
 
ASIT REVIEWS
ASIT REVIEWSASIT REVIEWS
ASIT REVIEWS
 
ASIT REVIEWS
ASIT REVIEWSASIT REVIEWS
ASIT REVIEWS
 
Learn REST API at ASIT
Learn REST API at ASITLearn REST API at ASIT
Learn REST API at ASIT
 
Learn C LANGUAGE at ASIT
Learn C LANGUAGE at ASITLearn C LANGUAGE at ASIT
Learn C LANGUAGE at ASIT
 
Learn Advanced JAVA at ASIT
Learn Advanced JAVA at ASITLearn Advanced JAVA at ASIT
Learn Advanced JAVA at ASIT
 

Recently uploaded

Unit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdfUnit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdf
Thiyagu K
 
The basics of sentences session 5pptx.pptx
The basics of sentences session 5pptx.pptxThe basics of sentences session 5pptx.pptx
The basics of sentences session 5pptx.pptx
heathfieldcps1
 
Embracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic ImperativeEmbracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic Imperative
Peter Windle
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
camakaiclarkmusic
 
How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...
Jisc
 
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Thiyagu K
 
Multithreading_in_C++ - std::thread, race condition
Multithreading_in_C++ - std::thread, race conditionMultithreading_in_C++ - std::thread, race condition
Multithreading_in_C++ - std::thread, race condition
Mohammed Sikander
 
How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17
Celine George
 
Acetabularia Information For Class 9 .docx
Acetabularia Information For Class 9  .docxAcetabularia Information For Class 9  .docx
Acetabularia Information For Class 9 .docx
vaibhavrinwa19
 
Overview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with MechanismOverview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with Mechanism
DeeptiGupta154
 
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama UniversityNatural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
Akanksha trivedi rama nursing college kanpur.
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
EugeneSaldivar
 
Biological Screening of Herbal Drugs in detailed.
Biological Screening of Herbal Drugs in detailed.Biological Screening of Herbal Drugs in detailed.
Biological Screening of Herbal Drugs in detailed.
Ashokrao Mane college of Pharmacy Peth-Vadgaon
 
Chapter 3 - Islamic Banking Products and Services.pptx
Chapter 3 - Islamic Banking Products and Services.pptxChapter 3 - Islamic Banking Products and Services.pptx
Chapter 3 - Islamic Banking Products and Services.pptx
Mohd Adib Abd Muin, Senior Lecturer at Universiti Utara Malaysia
 
Chapter -12, Antibiotics (One Page Notes).pdf
Chapter -12, Antibiotics (One Page Notes).pdfChapter -12, Antibiotics (One Page Notes).pdf
Chapter -12, Antibiotics (One Page Notes).pdf
Kartik Tiwari
 
Marketing internship report file for MBA
Marketing internship report file for MBAMarketing internship report file for MBA
Marketing internship report file for MBA
gb193092
 
The Diamond Necklace by Guy De Maupassant.pptx
The Diamond Necklace by Guy De Maupassant.pptxThe Diamond Necklace by Guy De Maupassant.pptx
The Diamond Necklace by Guy De Maupassant.pptx
DhatriParmar
 
A Survey of Techniques for Maximizing LLM Performance.pptx
A Survey of Techniques for Maximizing LLM Performance.pptxA Survey of Techniques for Maximizing LLM Performance.pptx
A Survey of Techniques for Maximizing LLM Performance.pptx
thanhdowork
 
Francesca Gottschalk - How can education support child empowerment.pptx
Francesca Gottschalk - How can education support child empowerment.pptxFrancesca Gottschalk - How can education support child empowerment.pptx
Francesca Gottschalk - How can education support child empowerment.pptx
EduSkills OECD
 
Azure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHatAzure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHat
Scholarhat
 

Recently uploaded (20)

Unit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdfUnit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdf
 
The basics of sentences session 5pptx.pptx
The basics of sentences session 5pptx.pptxThe basics of sentences session 5pptx.pptx
The basics of sentences session 5pptx.pptx
 
Embracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic ImperativeEmbracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic Imperative
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
 
How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...
 
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
 
Multithreading_in_C++ - std::thread, race condition
Multithreading_in_C++ - std::thread, race conditionMultithreading_in_C++ - std::thread, race condition
Multithreading_in_C++ - std::thread, race condition
 
How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17
 
Acetabularia Information For Class 9 .docx
Acetabularia Information For Class 9  .docxAcetabularia Information For Class 9  .docx
Acetabularia Information For Class 9 .docx
 
Overview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with MechanismOverview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with Mechanism
 
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama UniversityNatural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
 
Biological Screening of Herbal Drugs in detailed.
Biological Screening of Herbal Drugs in detailed.Biological Screening of Herbal Drugs in detailed.
Biological Screening of Herbal Drugs in detailed.
 
Chapter 3 - Islamic Banking Products and Services.pptx
Chapter 3 - Islamic Banking Products and Services.pptxChapter 3 - Islamic Banking Products and Services.pptx
Chapter 3 - Islamic Banking Products and Services.pptx
 
Chapter -12, Antibiotics (One Page Notes).pdf
Chapter -12, Antibiotics (One Page Notes).pdfChapter -12, Antibiotics (One Page Notes).pdf
Chapter -12, Antibiotics (One Page Notes).pdf
 
Marketing internship report file for MBA
Marketing internship report file for MBAMarketing internship report file for MBA
Marketing internship report file for MBA
 
The Diamond Necklace by Guy De Maupassant.pptx
The Diamond Necklace by Guy De Maupassant.pptxThe Diamond Necklace by Guy De Maupassant.pptx
The Diamond Necklace by Guy De Maupassant.pptx
 
A Survey of Techniques for Maximizing LLM Performance.pptx
A Survey of Techniques for Maximizing LLM Performance.pptxA Survey of Techniques for Maximizing LLM Performance.pptx
A Survey of Techniques for Maximizing LLM Performance.pptx
 
Francesca Gottschalk - How can education support child empowerment.pptx
Francesca Gottschalk - How can education support child empowerment.pptxFrancesca Gottschalk - How can education support child empowerment.pptx
Francesca Gottschalk - How can education support child empowerment.pptx
 
Azure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHatAzure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHat
 

Learn AJAX at ASIT

  • 1.
  • 2. What is Ajax? • "Asynchronous JavaScript and XML" • New name for an old technique: • JavaScript + DHTML + XMLHttpRequest • In use since at least 1997 • I've used it since 2000 • Finally someone gave it a name • Already enabled in yourWeb server and browser • Use JavaScript asynchronously behind the scenes to load additional data (typically XML) without discarding and reloading the entireWeb page.
  • 3. Why useAjax? • Your users will soon demand it • Not just another cool (geeky) technology • Very user-visible effect • Rich UI experience in aWeb page • Portable across browsers • Plus, all advantages of zero-installWeb app • No install done for this demo • No "DLL Hell“ Continued…
  • 4. Why useAjax? • Client/Server Apps: • Dynamic data • Static forms, controls, code, etc. • Efficient, but not flexible • Traditional Web Apps: • Dynamic data • Dynamic forms, controls, code, etc. • Flexible, but inefficient, and noticeably slow • Ajax Apps: • Dynamic data • Static or dynamic forms, controls, code, etc. • Best of both worlds. Continued…
  • 5. Why useAjax? • Geeky reasons: • Multithreaded data retrieval fromWeb servers • Pre-fetch data before needed • Progress indicators • Appearance of speed • Avoids need for setTimeout() • Less bandwidth required; less server load • Reload partial page, not entire page • Load data only, not even partial page
  • 6. How much to useAjax? • As little or as much as you like • No need to abandon what you already do • One more item in your "bag of tricks" • Start by jazzing up your existing UI
  • 7. How to useAjax? Simple! Use the XMLHttpRequest Object
  • 8. XMLHttpRequest Methods • open (“method”, “URL”, [async, username, password]) • Assigns destination URL, method, etc. • send (params) • Sends request including postable string or DOM object data • abort () • Terminates current request • getAllResponseHeaders () • Returns headers (name/value pairs) as a string • getResponseHeader (“header”) • Returns value of a given header • setRequestHeader (“label”,”value”) • Sets Request Headers before sending Continued…..
  • 9. XMLHttpRequest Properties • onreadystatechange • Event handler (your code) that fires at each state change • readyState 0 = uninitialized 3 = interactive (some data has been returned) 1 = loading (broken in IE 6.0) 2 = loaded 4 = complete • status • HTTP Status returned from server: 200-299 = OK • responseText • String version of data returned from server • responseXML • XML DOM document of data returned • statusText • Status text returned from server
  • 10. Simple Example var req = new XMLHttpRequest(); req.onreadystatechange = myHandler; req.open("GET", "servlet", true); req.send("p1=abc"); ... function myHandler() { if (req.readyState == 4) { doSomethingWith(req.responseXML); } else if (req.readyState == 3) { showProgressIndicator(); } }
  • 11. Demos • Simple demo • More demos • Google Suggest • Google Maps • Language translation • Mouse gesture as password • Typing speed as password • Classified ads tied to map • "Mashups"
  • 12. Security Issues • Can only hit domain theWeb page came from • Cannot access a 3rd partyWeb Service • However: • You can wrap those requests through your own server • User can allow access to specific sites via browser security settings • IFRAME can access any site (instead of XMLHttpRequest)
  • 13. AdvancedTopics • XSLT and XPath support (Sarissa) • Serializing Java Beans as XML • XMLBeans, JAXB, Zeus, Jbind,Castor, Betwixt • Serializing Java Beans as JavaScript objects • JSON -- JavaScript Object Notation • 2-way Mapping of Java Beans to JavaScript objects • DWR -- DirectWeb Remoting • Ajax Component Libraries andToolkits: • Dojo, Prototype, HTC, XBL • Implemented as JSP tag libraries or pure JavaScript • Ajax Frameworks • Ajax Patterns
  • 14. We also provide classroom and online training classes For More Details www.asit.amcsquare.com Wise Machines India Pvt Ltd #360, Sri Sai Padma Arcade, Varthur Main Road, Ramagondanahalli, Whitefiled ,Bangalore – 560066. We also having Branches in Hyderabad & Chennai