Given a form that allows the user to upload a text file with each row having the following format:
Title|Description|Tags|Thumb Location|Category|Video Embed, Blog Code or Link|V. B or L value|Date|
thumb location: url of thumb, needs to be grabbed, uniquely named and stored in a folder /thumbs, and store the filename in char(14)
Video Embed, Blog Code or Link: text
V. B or L value: represents if previous field is video embed, blog code or link. Need switch to create three different sql statements based on this value
Date is in unix date format, ex. 1202071358
need to parse and build sql statement similar to:
INSERT INTO TABLE_NAME
( title, description, tags, thumb, category, embed, blog_code, link, date )
('title', 'description', 'tags', 'thumb', 'category', 'embed', 'blog_code', 'link', 'date');
exact database fields will be provided once the job has been awarded. There will be slight variations depending on the V, B or L value.
The form will be submitted. Text file will be processed and resulting sql statements will be echoed to the screen.
Not worried about styling output, just functionality. Should be a simple job, thanks!