jQuery Dropdown Suggestions Comments (4)
by Wez Pyke - January 30, 2010 in jQuery

jquery dropdown suggestionsFor this tutorial we are going to create a drop down box similar to the one on the Google homepage when you start typing.

The Markup

The first thing that we must do is create the markup HTML. We are also going to include a stylesheet called style.css, we will create the CSS further down the tutorial.
(more...)

Twitter-like pagination using CakePHP and jQuery Comments (1)
by Wez Pyke - January 11, 2010 in PHP,Text Tutorials

twitter pagination icon Twitter like pagination using CakePHP and jQueryI have already done this tutorial with CodeIgniter and jQuery it can be found here. I thought I would do this tutorial again but rewrite it for CakePHP because it is a popular PHP framework.

Before we start doing any PHP code make sure to copy in the code below into your MySQL database.

CREATE TABLE  `tutorials`.`twitter_messages` (
`id` INT NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`username` VARCHAR( 30 ) NOT NULL ,
`message` VARCHAR( 140 ) NOT NULL
) ENGINE = INNODB

Create the controller

Under the folder named controller create a file and call it twitter_controller.php.

We create a class inside it called TwitterController and it will extend AppController. We then set the name of the controller to twitter and tell CakePHP which table we are using in our database.
(more...)