Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

SitePoint PHP Blog:
Interactive PHP Debugging with PsySH
Sep 30, 2014 @ 12:53:30

The SitePoint PHP blog has a new tutorial posted by i>Miguel Ibarra Romero showing how to use the PsySH tool to do some interactive debugging of your PHP applications via both the command line and a web frontend.

It’s 1:00 a.m., the deadline for your web application’s delivery is in 8 hours… and it’s not working. As you try to figure out what’s going on, you fill your code with var_dump() and die() everywhere to see where the bug is. [...] Is this situation familiar to you? PsySH to the rescue. PsySH is a Read-Eval-Print Loop (or REPL). You may have used a REPL before via your browser’s javascript console. If you have, you know that it possesses a lot of power and can be useful while debugging your JS code.

He walks you through the install via Composer and some of the basic commands and syntax for executing PHP code inside its shell. Command line testing is good, but debugging full applications is a bit more difficult. He shows how to integrate the tool into a sample application that calls PsySH via a "debug" call and output via a set of "window" objects. He also includes a bit close to the end about debugging with unit tests, executing them from inside the shell as well.

tagged: interactive debugging psysh repl unittest commandline web

Link: http://www.sitepoint.com/interactive-php-debugging-psysh/

Mapping with Geocoder PHP and Leaflet.js
Nov 06, 2013 @ 10:49:43

On PHPMaster.com a new tutorial has been posted showing how to combine Geocoder PHP with Leaflet.js to create interactive maps. The Leaflet.js library lets you easily create mobile-friendly maps with simplicity and usability in mind.

Interactive maps inside a web application have a lot of great uses. From visualizing data to highlighting points of interest, maps are expected to communicate ideas within the context of location easily. The hardest part, however, is converting that data into coordinates that the map can understand. Luckily, Geocoder PHP allows us to connect to different geo-coding providers. Combined with Leaflet.js, a simple Javascript library, creating maps is a breeze.

He starts by helping you get the Geocoder library installed via Composer and make a sample page (using Bootstrap and jQuery) with a container for the map. He helps you set up Geocoder with an adapter to connect to the service of your choice (like Google Maps, Bing Maps or Openstreatmap). With this configured and created, he inputs some sample data and coverts the addresses to latitude/longitude sets. He walks you through getting Leaflte.js added to the page and pulling in these results via individual generated Javascript variables. You can check out a demo of the end result to see how it all fits together too.

tagged: mapping geocoder leafletjs tutorial introduction interactive

Link: http://www.sitepoint.com/mapping-geocoder-php-leaflet-js/

Brian Moon's Blog:
Check for a TTY or interactive terminal in PHP
Sep 02, 2011 @ 09:12:47

In a new post to his blog Brian Moon describes a need he had for detecting if the client or user calling a PHP script was using an interactive terminal (TTY) or not:

Let's say I am trying to find out why some file import did not happen. Running the job that is supposed to do it may yield an error. Maybe it was a file permission issue or something. There are other people watching the alerts. What they don't know is that I am running the code and looking at these errors in real time.

Since the errors were being sent to the log file, they were lost to the client/user on the other end left staring at their script wondering what went wrong. He ended up with a solution (a pretty simple one too) that uses posix_ttyname and posix_isatty. He includes the little snippet of code he puts in his prepend file that checks for errors then checks for a TTY. If both are there, it turns off logging the errors to the file and sends them direct instead.

tagged: check tty interactive terminal posixisatty posixttyname error log


Casey's Blog:
Make Your Life as a PHP Developer Twice as Easy With phpsh
Jul 05, 2011 @ 11:50:37

In his (Python) blog today Casey reminds the developer community about a handy tool that the developers at Facebook have made available to make a PHP coder's life easier - phpsh.

The developers at Facebook have brought PHP developers a powerful REPL now ala-Python to round out a solid toolbox that PHP developers already have. The project is called phpsh and is written in Python.

He includes the commands you'll need to get it pulled from github and working, providing you with an interactive shell right on your local machine (more powerful than the built-in PHP shell). You can also grab a zip or gzipped archive for download. For complete details on the tool and how to use it, see phpsh.org.

tagged: tool phpsh shell interactive facebook python


Symfony Blog:
Symfony2: Getting Easier - Interactive Generators
Jun 22, 2011 @ 10:09:39

On the Symfony blog they've posted the latest in their "Getting Easier" series looking at some of the things being done for the framework to help make it more appealing for those just coming in. In this new article they look at the new interactive generators that help you create the code you'll need to set up your bundles without a lot of manual effort.

symfony1 has generators for all those things, but until now, Symfony2 was not very good at generating code. Well, that's "fixed" now, thanks to the new GeneratorBundle. The bundle is included by default in Symfony SE (as of 2.0.0 RC1 which will be released on June 24th) and it knows how to generate bundles, forms, Doctrine entities, and simple CRUD controllers to get you started even faster.

A screencast is included in the post showing the process of running the new tool and generate all of the configurations you'll need for a bundle, a Doctrine2 entity, database creation and the CRUD interfaces for a Doctrine entity. You can grab the code for this new bundle from the Sensio github account.

tagged: symfony2 framework interactive generator screencast example


Bence Eros' Blog:
Creating an interactive debugger for PHP
Jan 26, 2011 @ 08:53:48

Bence Eros has submitted a new post from his blog that looks at the method he came up with to create an interactive debugger for PHP. It's just a prototype/proof of concept that lets you execute PHP code in the browser (using eval - a little scary, I'll admit).

Last night I created a prototype for an interactive debugger for PHP without the need of any IDE-plugin. In this post I'm going to show what I found. Unfortunately you will need some time to put the environment together, but I think it's worth doing it. My target was to create a way how you can view and modify your variables manually at runtime, only by inserting one line code.

He does mention that, because of the settings he uses, the debugger can only be loaded from a different domain than the application which can be restricted a bit simpler (i.e. its own https or .htauth). His setup uses an Apache2 web server and a few PHP/HTML scripts to get the job done. In the end you'll have something similar to this for you to run your code in.

tagged: interactive debugger webbased tutorial apache2


Job Posting:
Apollo Interactive Seeks PHP Programmer (Culver City, CA)
Oct 13, 2010 @ 14:45:03

Company Apollo Interactive
Location Culver City, CA
Title PHP Programmer

We are seeking a team-oriented, skilled PHP Programmer to join Apollo in our Culver City office.  This is a full-time position.  Salary will be in line with candidate’s experience, however please provide requirements in your cover letter.  Likely candidates will have 2-4 years experience in similar position using PHP/MySQL. You will be part of an established team that is responsible for the development of new Web sites from inception to completion and for performing updates to existing Web sites.  Ideal candidates have excellent code/commenting, are able to manage multiple projects, have good communication skills, and a solid understanding of the Web site development process. 


  • Program large, database-driven Web sites
  • Requirements gathering and preparing functional/technical specifications
  • Ability to communicate well with both staff and clients
  • Work closely with Account Services, Creative, and Web Producers
  • Self-motivator and good attitude
  • Willingness to learn and apply new technologies as needed


  • 4+ years programming in Agency or similar environment
  • Must be able to create a functional Webpage using only Notepad or similar text editor
  • Expert SQL Knowledge
  • Strong understanding of Object Oriented Programming
  • Good understanding of C#, JavaScript, XML and DHTML
  • BS degree in CS (or similar)

Experience with the following is helpful but not required

  • Unit Testing
  • Design Patterns
  • Online Marketing
  • Lead Generation

    Benefits include Medical, Dental, 401K and annual salary review.  


    Email resumes to careers@apollointeractive.com 

    About Apollo
    Apollo Interactive is a full-service Interactive Agency with offices in Culver City, CA and Dallas, TX. Our services include Web Development and Online Advertising for some of America’s largest well-known companies like Jack in the Box, Roland, Curves International, Chuck E. Cheese’s, The University of Phoenix, and Blue Cross of California.

  • tagged: job programmer culvercity ca apollo interactive


    Jordi Boggiano's Blog:
    PHP Console in Your Browser
    Sep 24, 2010 @ 11:51:49

    Jordi Boggiano has a new post today looking at his PHP console script that works in your browser that sets up easily and works from your localhost web server - php-console.

    Since I spend most of my days programming PHP I tend to need that a lot and a few years back I wrote a small script that would let me type php code in my browser and execute it. Nothing fancy, but quite useful. Over the years a few people got interest seeing me use it and asked for the sources, so instead of repackaging it every time, I thought I'd clean it up, polish a bit, add some features, and put it on github.

    Setup is as simple as dropping the code somewhere in your local server's document root and offers a textarea for input and a expandable tree for the resulting output. It uses the Krumo tool to create this modified output. You can see a screenshot here.

    tagged: console browser interactive shell webbased


    Communty News:
    iphp, the Interactive PHP shell
    Dec 10, 2009 @ 10:35:39

    Alan Pinstein has put together an interactive PHP shell that gives you some interesting advantages over PHP's default shell feature.

    php is an interactive php shell that solves a number of painful problems with normal php shells: error handling, readline support, autocomplete, history, require support an autoload support.

    You can grab the latest version from his github repository.

    tagged: interactive shell iphp


    Matt Curry's Blog:
    Interactive Plugin For CakePHP Console and DebugKit
    Jun 10, 2009 @ 09:33:36

    Matt Curry has released a new plugin for running code against a CakePHP installation (either via DebugKit or the command line).

    I teased this on twitter last week, so here’s the official release. The interactive plugin is a super easy way to run code against your Cake app. You can use it either through a custom panel in the DebugKit or from the command line as a shell.

    The plugin [github] allows you to run all sorts of operations - simple PHP commands, Cake functions, application code, debugging statements and SQL queries.

    tagged: debugkit cakephp interactive plugin