Hi, I am having the following problem:
I need to convert table data into some format suitable for insertion into MySQL database. The problem is that database is normalized. So i need this:
<tr><td class="picture" ><img src="images/1.jpg" width="150" height="130" /></td>
<td class="title">Book 1</td>
<td class="author">John Smith</td>
<td class="price">1034</td>
</tr>
converted into:
$query1= "INSERT INTO Books (Picture,Title,Price) VALUES ("images/1.jpg","Book 1","1034")";
$query2="INSERT INTO Authors (Author) Values ("John Smith")";
- some script that would insert data into join table. Also some author tags contain multiple authors. Any ideas?