It should be possible to have CakePHP directly talking to a Microsoft SQL server, but I don't know how and didn't try it. The advantage of talking directly to MSSQL is that you can use the standard Models.
donderdag 8 november 2007
Use Google Maps in CakePHP
I found an interesting article from Mahmoud Lababidi at the Bakery on integrating Google Maps in your CakePHP application.
Labels:
CakePHP,
google,
google maps
woensdag 7 november 2007
Beautiful PHP thumbnail class useful as vendor in CakePHP
I found a very handy thumbnailer class on written by Ian Selby. This class lets you resize your image, but it is also capable of creating the popular Apple Reflection effect.
You can very easily use this class to use it as a vendor in CakePHP.
Have fun!
You can very easily use this class to use it as a vendor in CakePHP.
Have fun!
Labels:
apple,
CakePHP,
reflection,
thumbnail
maandag 29 oktober 2007
Use helpers in your application
It is advised to make use of helpers in your application. Your code becomes clean and more flexible because the helpers are short and clear, and they handle the paths to the file referenced. For example, to quickly show an image in your view, use:
< ?= $html->image('9.jpg') ?>
Labels:
CakePHP
vrijdag 5 oktober 2007
dinsdag 2 oktober 2007
findAllBy is cool!
Suppose you have a field name in your database called type. CakePHP will automagically add a new function called findAllByType. For example, you can try: findAllByType('customer'); to find all fields with type=customer.
From the CakePHP manual:
From the CakePHP manual:
* findAllBy
* string $value
These magic functions can be used as a shortcut to search your tables for a row given a certain field, and a certain value. Just tack on the name of the field you wish to search, and CamelCase it. Examples (as used in a Controller) might be:
$this->Post->findByTitle('My First Blog Post');
$this->Author->findByLastName('Rogers');
$this->Property->findAllByState('AZ');
$this->Specimen->findAllByKingdom('Animalia');
The returned result is an array formatted just as would be from find() or findAll().
maandag 1 oktober 2007
Basic Task list with Ajax
Graham Bird has written a very nice tutorial on creating a Basic Task list with Ajax. Have a look at it here (http://grahambird.co.uk/cake/tutorials/ajax.php).
Abonneren op:
Posts (Atom)