11.07.2015 Views

AJAX and PHP

AJAX and PHP

AJAX and PHP

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Chapter 10When dropping a task on the DROP HERE TO DELETE area, a confirmation is required before theapplication proceeds with the actual deletion; as shown in the following figure:Figure 10.2: Confirmation Required Before Deleting a TaskTime for Action—Task Management Application with <strong>AJAX</strong>1. Connect to the ajax database, <strong>and</strong> create a table named tasks with the following code:CREATE TABLE tasks (id INT UNSIGNED NOT NULL AUTO_INCREMENT,order_no INT UNSIGNED NOT NULL default '0',description VARCHAR(100) NOT NULL default '',PRIMARY KEY (id));2. In your ajax folder, create a new folder named drag-<strong>and</strong>-drop.3. In the drag-<strong>and</strong>-drop folder, create a file named config.php, <strong>and</strong> add the databaseconfiguration code to it:241

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!