Tiffany B. Brown

a mish-mosh of stuff

Posts tagged: PHP

Yes, you really do need to learn JavaScript
From Ed Finkler‘s PHP Advent 2009 piece, You Really Need to Learn JavaScript: When I say “you need to learn JavaScript,” I don’t mean “learn how to copy and paste an example,” or “learn how to generate JavaScript with PHP.” I mean learn it as well as you already know PHP — or better. Why? Because JavaScript [...] [3 Dec 2009]
PHP in Arabic: An interview with Khaled Al-Shamaa
PHP Classes interviews Khaled Al-Shamaa about his AR-PHP project, a series of PHP classes designed to handle Arabic-language web applications. Because Arabic uses a non-Latin character set, it presents a new set of challenges. PC: Developing Web applications in Arabic requires special care. What are the most important concerns and what components do you provide [...] [18 Nov 2009]
[PHP quickie] Select a certain number of words from a string
An alternative to subst() that selects entire words rather than a specified number of characters. I used this on a recent project where I needed to create a meta tag description from text and HTML stored in a database. Uses PHP’s native str_word_count() function. function select_number_of_words($input,$number_of_words){ $output = ”; $input = strip_tags($input); $input = str_word_count($input,1); [...] [26 Mar 2009]
Collecting e-commerce conversion data with Zen Cart and Google Analytics
Google Analytics allows you to collect pretty robust data about how users move through your e-commerce site. Here’s how to make it work with Zen Cart, an open source shopping cart. For this tutorial, you will need: A Zen Cart-based shopping cart A Google Analytics account and the tracking code for both conversions and page [...] [19 Feb 2009]
Security vulnerability found in WordPress; Upgrade to 2.6.3
News of a vulnerability in the Snoopy open source PHP library has surfaced. WordPress uses the Snoopy library to power feeds in administration section’s Dashboard. A fix — WordPress 2.6.3 — was released today. You can download the entire package, or just download the two affected files and upload them to your server. [23 Oct 2008]
UPDATED: Atlanta, GA: PHP Atlanta “Join-Fu: The Art of SQL”
This meeting has been rescheduled to Thursday, August 14th at 7 p.m. Jay Pipes of MySQL AB and co-author of Pro MySQL, comes to Atlanta this month to present “Join-Fu: The Art of SQL.” I’ve seen Pipes speak before, and his presentation was incredibly informative. If you do a lot of development with MySQL, you [...] [18 Jul 2008]
Atlanta, GA: php|works and PyWorks
Marco Tabini & Associates, publishers of PHP Architect and Python Magazine are bringing their php|works conference back to Atlanta this fall, November 12th through 14th, 2008. This year, though, the conference has an added bonus: PyWorks, a conference devoted to Python. Registering for one conference allows you to attend both. Both conferences have an open [...] [18 Jul 2008]
Debugging tip: “Disallowed Key Character” error in CodeIgniter
After 6 hours of massive anxiety, stress, near tears, one pound on my desk, and some hair pulling, I tracked down the source of a nagging Disallowed Key Character error that I received while using CodeIgniter: an extra line break. The line feed (LF) and carriage return (CR) characters (and their hex code equivalents (%0D [...] [6 May 2008]
Turn text files into pull down menus
UPDATE: This could also be done with the foreach() construct, but here — on my set-up at least — the for loop is a teensy bit faster. I developed this PHP function for a project I’m working on. I’m posting it here in case I need it again, or in case you find it handy. [...] [26 Feb 2008]
Damn … my VPS is being cracked
UPDATE: What appears to have happened … Yeah, as I type this, I’m getting hit with an attack. I’m not precisely sure of the motive. I just know that there are two directories on my server that should not be there and the attack appears to be coming through a specific URL. It’s been happening [...] [7 Nov 2007]