-
-
What, who, where am I?!?
Craig Lotter is a web developer based in Gordon's Bay, South Africa, who seems completely incapable of shaking off that pesky inner child within, the one that forces him to love all things animated or hand drawn.
The Rugged Rock of Craig contains snippets of his life, popular culture and all the important things like anime, manga, games and comic books. The CodeUnit of Craig on the other hand contains the more serious stuff like code snippets and tutorials, while the House of C chronicles his foray into the world of web comics.
For which it never seems he has enough time anyway.
-
Rugged Rock Studio
- CodeUnit Collections
- Funakoshi Karate International South Africa
- Rugged Rock Studio: The Portfolio of Craig Lotter
- The Codeunit of Craig
- The House of C
- The Rugged Rock of Craig
Tag Archives: replace
PHP Script to Trim and Replace Apostrophes for Each Value in Each Column of Each Table in a MySQL Database
I needed to quickly whip up a script that would strip all leading and trailing whitespace plus replace any apostrophes or quotation marks with their web code equivalent for each and every value that appeared in every row, column and table in the database. Continue reading
Posted in Technology & Code, Tutorials Tagged code, database, database walk, htmlentities, mysql, PHP, replace, trim, tutorial, whitespace View Comments
PHP: How to Get all the Numbers out of an Alphanumeric String?
Given a registration code, or something important like that, which often contains information encoded in the alphanumeric string itself, it is sometimes quite useful to be able to simply strip out the letters from the string, leaving only the numeric part behind. Continue reading
Posted in Technology & Code, Tutorials Tagged alphanumeric, digits, numbers, PHP, preg_replace, regex, replace View Comments
PHP: How to Get all the Letters out of an Alphanumeric String?
Given a registration code, or something important like that, which often contains information encoded in the alphanumeric string itself, it is sometimes quite useful to be able to simply strip out the numbers from the string, leaving only the letters behind. Continue reading
Posted in Technology & Code, Tutorials Tagged alphanumeric, letters, PHP, preg_replace, regex, replace View Comments