PHP 5.x Archives
IBM:
The introduction of new object-oriented programming (OOP) features in PHP V5 has significantly raised the level of functionality in this programming language. Not only can you have private, protected, and public member variables and functions — just as you would in the Java™, C++, or C# programming languages — but you can also create objects […]
02-22-2006 | Permanent Link | 1 Comment | Related Entries: PHP 5.x, Information
Man, how many clicks does it take to get the download these days at Sourceforge? Seems like it took me a half dozen to get to the AjaxMyTop project download.
MyTop creator Jeremy Zawodny writes:
Someone has built and AJAX powered version of mytop, the little console based MySQL monitoring tool I wrote years ago. I guess […]
01-31-2006 | Permanent Link | No Comments | Related Entries: AJAX, Installation and configuration, PHP 5.x, PHP 4.x
PHP 5.1.0 has been released on Thanksgiving. Changelog
11-24-2005 | Permanent Link | 1 Comment | Related Entries: PHP 5.x
Based on the concept of Rails / Django like framework only for PHP, here comes the MIT licensed symfony
11-09-2005 | Permanent Link | No Comments | Related Entries: AJAX, PHP 5.x
At one of our sites we needed to parse out some names and numbers from a log file. The strings also contained comment text and the order would be mixed format. These types of regular expression parsing can be tricky.
Let’s take a look at the two possible formats of the strings:
FORMAT #1:
[00:02:18][jvastine]7.52..I agree with […]
09-23-2005 | Permanent Link | No Comments | Related Entries: Functions, PHP 5.x, PHP 4.x
The PHP header function allows redirection of the browser, among other cool things.
Example redirecting the browser to php-scripts.com homepage:
<?php
header(”Location: http://www.php-scripts.com/”);
?>
09-22-2005 | Permanent Link | 4 Comments | Related Entries: Functions, PHP 5.x, PHP 4.x, PHP 3.x
Finding out the number of days elapsed from a UNIX timestamp is actually pretty straightforward. If you only know two dates then first you’ll need to convert the date to a UNIX timestamps and then subtract the most recent timestamp from the older timestamp like this:
<?php
$old_timestamp = 1102971600;
$elapsed_seconds = time() - $old_timestamp;
print ‘Seconds elapsed since […]
09-21-2005 | Permanent Link | No Comments | Related Entries: Linux, PHP 5.x, PHP 4.x, PHP 3.x, Information
<?php
$string = “?This is a test that should be in single quotes quotes?”;
$text = preg_replace(”/(\?([^\?]+)\?)/”,”‘\\2′”,$string);
?>
regular expression produces:
This is a test that should be in single quotes’
09-20-2005 | Permanent Link | No Comments | Related Entries: PHP 5.x, PHP 4.x, Information
Today being it is our 16th wedding anniversary I decided it would be appropriate to build a small script to keep track and post a message automatically on our special day together. I wanted this program to remember what year of our anniversary it was without me having to remind it: a great use for […]
09-19-2005 | Permanent Link | No Comments | Related Entries: PHP 5.x, PHP 4.x, Information
For those who would like to learn how to write PHP code, starting next Friday at Webmaster Cookbook, our family friendly webmaster how-to site/blog, we’ll be going through a 32 week course on PHP programming. Details will be announced during the radio show and podcast next Friday September 23, 2005 at 3:30pm PST. For those […]
09-16-2005 | Permanent Link | No Comments | Related Entries: PHP 5.x, PHP 4.x, Information