Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Freeaqingme's Blog:
PHP, JS & Service layers: Blend like never before
Mar 17, 2011 @ 11:41:42

On his Tweakblog today Freeaqingme has posted about some work he's done linking Javascript to a PHP service layer and overcoming some of the performance issues he came across.

The past week I've been only programming (clientside) Javascript, and last night I finally got to tying it all to the serverside app, which is written in PHP. While adding some functionality to my Service Layer, it came to mind how much slower this process was in the past. [...] One of the nice things of Service Layers and performing your Access Control there, is that you can have multiple points of entry. So, to lessen the amount of tediousness, one can simply use one controller for all service requests coming from the client.

He was connecting to two via a XMLHttpRequest to a custom URL that would return a different result based on the kind of request. Internal routing handled the request correctly and the result from the view was pushed directly back to the client. He includes code to illustrate - a bit of PHP based on the Zend Framework structure, the Javascript to make the request and an example of invoking the service on the client side.

tagged: javascrupt tutorial servicelayer ajax xmlhttprequest

Link:

IBM developerWorks:
Build Ajax-based Web sites with PHP
Sep 04, 2008 @ 11:19:02

The IBM developerWorks website has a new tutorial for those looking to get into the powerful combination of Ajax and PHP - an introduction to creating Ajax-based websites with PHP.

Learn the process of writing Asynchronous JavaScript + XML (Ajax) applications using native JavaScript code and PHP. This article introduces a few different frameworks and application program interfaces (APIs) that reduce the amount of code you need to write to achieve a complete Ajax-based Web application.

They (briefly) explain what Ajax is and the benefits of it before jumping right in to a sample page. They go for the "manual first" approach so developers know to make basic connections with the XMLHttpRequest object and handle the responses. They do mention some of the libraries offered that help with the connections too (like jQuery, Prototype and Dojo).

tagged: ibm tutorial ajax website manual xmlhttprequest jquery dojo prototype library

Link:

The Bakery:
Six New Components/Articles/Tutorials (SOAP, XHR, Tickets, Models, Releases & Flashes)
Oct 31, 2007 @ 10:24:00

The Bakery has a grouping of six new articles/tutorials/components posted covering things from SOAP to loading models on the fly to some of the latest CakePHP releases:

Check out The Bakery for more great CakePHP related information and tools.

tagged: thebakery cakephp framework soap ticket model release flash xmlhttprequest thebakery cakephp framework soap ticket model release flash xmlhttprequest

Link:

The Bakery:
Six New Components/Articles/Tutorials (SOAP, XHR, Tickets, Models, Releases & Flashes)
Oct 31, 2007 @ 10:24:00

The Bakery has a grouping of six new articles/tutorials/components posted covering things from SOAP to loading models on the fly to some of the latest CakePHP releases:

Check out The Bakery for more great CakePHP related information and tools.

tagged: thebakery cakephp framework soap ticket model release flash xmlhttprequest thebakery cakephp framework soap ticket model release flash xmlhttprequest

Link:

DevArticles:
Learning AJAX
Aug 20, 2007 @ 14:24:00

A new introductory tutorial over on DevArticles looks to help you get acquainted with Ajax through its use in both PHP and JSP:

This is a two-part article. In these two parts I'll try to describe what AJAX is, and how to use AJAX in PHP and JSP. Later we will use some advanced JSP tag libraries to make cool AJAX-based web applications.

This first part looks at the basics of the connection - the XMLHttpRequest object and a simple example putting it to use grabbing the latest date from a background PHP or JSP script (complete with screenshots of the end result).

tagged: ajax tutorial jsp example xmlhttprequest introduction ajax tutorial jsp example xmlhttprequest introduction

Link:

DevArticles:
Learning AJAX
Aug 20, 2007 @ 14:24:00

A new introductory tutorial over on DevArticles looks to help you get acquainted with Ajax through its use in both PHP and JSP:

This is a two-part article. In these two parts I'll try to describe what AJAX is, and how to use AJAX in PHP and JSP. Later we will use some advanced JSP tag libraries to make cool AJAX-based web applications.

This first part looks at the basics of the connection - the XMLHttpRequest object and a simple example putting it to use grabbing the latest date from a background PHP or JSP script (complete with screenshots of the end result).

tagged: ajax tutorial jsp example xmlhttprequest introduction ajax tutorial jsp example xmlhttprequest introduction

Link:

PHPBuilder.com:
Dynamic XML with PHP
Aug 20, 2007 @ 12:48:00

PHPBuilder.com has a new tutorial posted today with a look at the easy creation of dynamic XML with the data from a database.

In this article I will show how to generate dynamic XML documents with Object-Oriented PHP. Before I get started, let's get right to the heart of this functionality. Although the code may look fancy, being packaged up inside objects and inheritance, the key elements of this functionality rest in the the mysql_list_fields() and mysql_num_fields() functions.

The XML is built manually with the tags assigned to a string as they are built. The information is from a simple query to select all from a user-defined table and is output with a UTF-8 character encoding. They also include a Javascript (download) that helps in making an XMLHttpRequest connection to fetch the XML you've created and pull it in.

tagged: dynamic xml create database xmlhttprequest ajax tutorial dynamic xml create database xmlhttprequest ajax tutorial

Link:

PHPBuilder.com:
Dynamic XML with PHP
Aug 20, 2007 @ 12:48:00

PHPBuilder.com has a new tutorial posted today with a look at the easy creation of dynamic XML with the data from a database.

In this article I will show how to generate dynamic XML documents with Object-Oriented PHP. Before I get started, let's get right to the heart of this functionality. Although the code may look fancy, being packaged up inside objects and inheritance, the key elements of this functionality rest in the the mysql_list_fields() and mysql_num_fields() functions.

The XML is built manually with the tags assigned to a string as they are built. The information is from a simple query to select all from a user-defined table and is output with a UTF-8 character encoding. They also include a Javascript (download) that helps in making an XMLHttpRequest connection to fetch the XML you've created and pull it in.

tagged: dynamic xml create database xmlhttprequest ajax tutorial dynamic xml create database xmlhttprequest ajax tutorial

Link:

PHPBuilder.com:
AJAX and PHP Part 2 - XML Communication/Processing
Jun 29, 2007 @ 16:22:06

PHPBuilder.com has posted part two of their look at combining Ajax and PHP. They take things a step further than last time and look at the actual communication between the script and the server.

AJAX and PHP 5 both have powerful features for processing and using an XML document. XML is a method of formatting data often for communication purposes between different computer systems. In this article, we will show you how to access an XML document with AJAX!

They create a script that can load the XML information from a file and echo it back out to the waiting client script. They also include the other half - the client-side javascript that grabs the XML information, parses it, and pushed it into a javascript object for easy access.

tagged: ajax xml communication process client server xmlhttprequest tutorial ajax xml communication process client server xmlhttprequest tutorial

Link:

PHPBuilder.com:
AJAX and PHP Part 2 - XML Communication/Processing
Jun 29, 2007 @ 16:22:06

PHPBuilder.com has posted part two of their look at combining Ajax and PHP. They take things a step further than last time and look at the actual communication between the script and the server.

AJAX and PHP 5 both have powerful features for processing and using an XML document. XML is a method of formatting data often for communication purposes between different computer systems. In this article, we will show you how to access an XML document with AJAX!

They create a script that can load the XML information from a file and echo it back out to the waiting client script. They also include the other half - the client-side javascript that grabs the XML information, parses it, and pushed it into a javascript object for easy access.

tagged: ajax xml communication process client server xmlhttprequest tutorial ajax xml communication process client server xmlhttprequest tutorial

Link: