Php and ajax
Download
1 / 11

PHP and AJAX - PowerPoint PPT Presentation


  • 89 Views
  • Uploaded on

PHP and AJAX. Servers and Clients. For many years we tried to move as much as possible to the server. Weak clients, poor bandwidth, browser compatibility.. Created a certain way of interacting with a website. Request – Response model. Clients and Servers.

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about ' PHP and AJAX' - ardelle-york


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript

Servers and clients
Servers and Clients

  • For many years we tried to move as much as possible to the server.

    • Weak clients, poor bandwidth, browser compatibility..

  • Created a certain way of interacting with a website.

    • Request – Response model.


  • Clients and servers
    Clients and Servers

    • Client machines have become much more powerful.

      • You’re not using much of your duel core processor rendering a webpage

  • Bandwidth has increased dramatically

    • 9.5 million broadband users in the UK (2006, BBC)

    • “Broadband now makes up 57.4% of all net connections compared to 42.6% for dial-up. In the last year dial-up connections had shrunk by 28.7%” (2005, BBC)

    • 14,520,988 Q2 2007

      (http://www.thinkbroadband.com/news/3280-number-of-uk-broadband-users-nearing-saturation-point.html)


  • Clients and servers1
    Clients and Servers

    • Browsers now run JavaScript in a more predictable manner.

    • So the technology is ready for AJAX but what is it?


    What isn t ajax
    What isn't AJAX

    • A Language

    • A Technology

    • A Plug-in

    • Proprietary

    • All that hard

    • The answer to all of our dreams


    What is ajax
    What is AJAX?

    • Asynchronous JavaScript and XML

      • What is asynchronous?

    • Uses JavaScript and XML to create seamless interaction on a website.

    • Lots of CSS sites look ‘real purty’ but still have the response/request model of interaction.

      • Using Obvious forms for their interaction.


    AJAX

    • “It uses the JavaScript XMLHttpRequest function to create a tunnel from the client's browser to the server and transmit information back and forth without having to refresh the page.” http://coldfusion.sys-con.com/read/138966.htm

    • Ajax has become synonymous with any rich web application or Web 2.0 / 3.0 application.


    Php and ajax1
    PHP and Ajax

    • XMLHttpRequest Object

    • “XMLHttpRequest (XHR) is an API that can be used by JavaScript, and other web browser scripting languages to transfer XML and other text data to and from a web server using HTTP, by establishing an independent communication channel between a web page's Client-Side and Server-Side.” - Wiki

      • Created in IE:

        var AlsAjaxObject = new ActiveXObject("Microsoft.XMLHTTP");

      • In other browsers:

        var AlsAjaxObject = new XMLHttpRequest();


    Demos
    Demos

    • Image Editor

    • Text Stuff

    • Google Suggests

    • Google Maps


    Some tutorials
    Some tutorials

    • http://www.w3schools.com/php/php_ajax_database.asp

    • http://www.ibm.com/developerworks/xml/library/os-php-rad1/

    • http://www.phpbuilder.com/columns/kassemi20050606.php3

    • http://www.phpbuilder.com/columns/kassemi20050606.php3

    • http://www.johnwiseman.ca/blogging/tutorials/creating-a-mysql-connection-with-phpajax/


    Links further reading
    Links – Further Reading

    • http://dhtmlnirvana.com/ajax/ajax_tutorial/

    • http://ajaxpatterns.org/wiki/index.php?title=Whats_Ajax

    • http://www.maxkiesler.com/index.php/weblog/comments/round_up_of_50_ajax_toolkits_and_frameworks/

    • http://www.ajaxwith.com/PHP

    • http://www.fiftyfoureleven.com/resources/programming/xmlhttprequest/examples


    ad