Tuesday, November 30, 2010

PHP: How to Scrape Websites using Simple HTML DOM Parser

Scraping websites or Web scraping is a method of collecting data off from websites using a program to automate the process. Wikipedia defines it as "a computer software technique of extracting information from websites." For whatever purpose it may be, the creation of web scraping PHP scripts has been made easier using this PHP class for parsing HTML content. From the PHP Simple HTML DOM Parser website:

  • A HTML DOM parser written in PHP5+ let you manipulate HTML in a very easy way!

  • Require PHP 5+.

  • Supports invalid HTML.

  • Find tags on an HTML page with selectors just like jQuery.

  • Extract contents from HTML in a single line.



I have used this class several times already in some of my projects and it does work well. Below are some sample codes:

Monday, November 15, 2010

Drupal: Easy Themeing with Fusion

The more I'm using Drupal, the better I understand why a lot of developers choose it as a top choice when it comes to creating community-driven websites. And another great tool at our dispense for creating Drupal sites is the Fusion theme.