Parse Rss Of Classifieds Store Data Mysql Php

PHP Script

Parse Motorcycle Classifieds, store data.

Collection Overview:

+ Parse a list of structured RSS feeds (Feed) for Posts
+ Using regular expressions, extract strings that match specific criteria
+ Test for string match to values in database tables
+ Store new Records in MySQL database
+ Modify Records in database with datestamp when Posts are no longer in feed

Example feeds:

http://dallas.craigslist.org/ftw/cto/index.rss
http://sfbay.craigslist.org/scz/cto/index.rss

Database Record:

1. Required for insert:
a. Date of capture
b. Make
c. Model
d. Year of Manufacture
e. Price
f. Date listed
g. Days on market (calculated)
h. Postal Code (calculated)
i. Post ID
2. Optional for insert
a. Mileage ( Integer)
b. Trim Designator (STX, R/S…)
c. Significant Features (4×4, extra cab: comma separated list)
d. Value Modifier (integer -5 to +5)
e. Dealer or Private listing (Single Alpha “D” or “P”)
f. Phone
g. Email

Leave a Reply

Your email address will not be published. Required fields are marked *