Building Dynamic SQL String from Associative Array
Posted: Jul 14, 2008 | 1 comment.
It would be nice to have functions that convert associative arrays to SQL queries. Such a function will save our time from building queries. The functions take two main parameters, the name of the table and the data to be inserted in associative array. Read more
Converting Tag's Properties Into Associative Array
Posted: Jun 28, 2008
You've fetched an HTML page and your code needs to read the properties of the some tags in it. Learn how to convert tag's properties into associative array using this code. Read more
Displaying Sequential Images with Pagination
Posted: Jun 22, 2008
Display your sequential images and the pagination with this code snippets Read more
Getting File's Extension with Regular Expression
Posted: Jun 18, 2008 | 1 comment.
Getting file's extension is not as easy as it looks. This is because there is no strict format for file extensions. To obtain the extension from file names, you have to use regular expression. See the following example. Read more
Starting Zend Framework
Posted: Jun 15, 2008
After building lots of projects, I realize that I spend a lot of time just to writing repeating (and boring) code; select, insert, delete, and update rows. I have to find a way to increase my coding speed, and I choose Zend Framework. Read more
Displaying Random Quotes
Posted: Jun 7, 2008
Displaying random quotes is the easiest thing to do with PHP. But in case you don't know how, here it is. Read more
Get Summary From a Long Paragraph
Posted: Jun 3, 2008
If you have recent news you want to display in your homepage, you might want to display only the summaries--a short paragraph with only 20-25 words. Read more
How to Read Command Line Arguments from Your Script
Posted: May 28, 2008
Writing scripts that run from command line is sometimes useful. It gives us more flexibility rather than scripts that called from web browsers. But passing parameters to these scripts is a little different. Learn how to read command line arguments from your script. Read more
Smileys2Emoticons - Display Emoticons in Your Guestbook!
Posted: May 24, 2008
Emoticons are very popular in the Internet these days. It seems like now every forums, mailing lists and guestbook support emoticons in their pages. If you write such applications, why not add them too? Read more
Page Indexing - Get The Title and Meta Tags From All of Your Pages
Posted: May 21, 2008
I'm doing some projects to help webmasters maintain their sites. Some of these tools include: Link checker, Del.icio.us auto submitter and many more. One of the components I need is a web crawler/spider to build a page index, which will be used by the higher level components to perform their tasks. Read more