10 super useful PHP snippets

Super simple page caching When your project isn’t based on a CMS or framework, it can be a good idea to implement a simple caching system on your pages. The following code snippet is very simple, but works well for small websites. <?php // define the path and name of cached file $cachefile = 'cached-files/'.date('M-d-Y').'.php'; … Continue reading “10 super useful PHP snippets”

Adding Local Weather Conditions To Your App (Part 2/2: Accessing Google’s XML Weather API)

In this Part 2 of ‘Adding Local Weather Conditions To Your App’, I’ll show you how to quickly add current temp, conditions, and today’s high / low temperature to your app. If you’re lucky enough to already have the user’s zipcode or city and state, this should go very quickly for you. Otherwise, check out … Continue reading “Adding Local Weather Conditions To Your App (Part 2/2: Accessing Google’s XML Weather API)”

Adding Local Weather Conditions To Your App (Part 2/2: Accessing Google’s XML Weather API)

In this Part 2 of ‘Adding Local Weather Conditions To Your App’, I’ll show you how to quickly add current temp, conditions, and today’s high / low temperature to your app. If you’re lucky enough to already have the user’s zipcode or city and state, this should go very quickly for you. Otherwise, check out … Continue reading “Adding Local Weather Conditions To Your App (Part 2/2: Accessing Google’s XML Weather API)”