There are tons of functions out there to calculate the distance between two points, but what if you know one point and want to calculate the latitude (“vertical”) or longitude (“horizontal”) equivalent of a fixed distance, in miles? An example application would be in generating a minimum & maximum latitude and longitude bounding box around [...]
Category Archives: PHP
Planning to add proper PHPunit and PHPlogger code examples and blog about it at http://bcmoney-mobiletv.com/blog/
auto complete code snippet like google suggestions
A function that resizes an image to desired width and height, but does not distort the image proportions. Suggestions please comment.
This code snippet gets all information from a YouTube video (title, description, duration, thumbnail url, thumbnail width, thumbnail height, etc..) using the video id and YouTube API. (Sorry about my bad english)
I wrote SnipBot a while ago which automatically posts draft articles to Snipd. The snippet below will create a new draft post on a WordPress blog. It uses the IXR class to communicate with WordPress via XML-RPC. The IXR class is included with WordPress by default.
Convert an address to geocode Latitude/Longitude positioning with PHP and Google Maps
Tests for a valid email address and optionally tests for valid MX records, too.
A collection is a Model type containing other Models, it is basically used in Magento to handle product lists (ie. from a category or a bundle option), but not only. This is a simple example of loading some product collection from a category and ordering them on their product name using Magento’s API.
If you are creating an admin module for Magento (learn creating admin module in Magento) then you would surely be asked to create grids (eg. for order listing). Creating grids can be somewhat difficult for the novice Magento programmers, but in this tutorial we will create a grid in the admin module in the simplest [...]