Hi David,
I have made a menu where you can choose a category, and when this category is choosen, i want all the stores within that category to be displayed in a list.
And next to each store i want a link called "more info" or something like that, that links to a page with information that i put in, with information about that specific store, and with the ability to let people review the store.
If the store link is clicked i just want it like it is now, products within the store listed as usual. But the "more info" should work as i explained above.
Is this possible? If so, what do i need to do to make this happend?
Best Regards
Ole S.
Hi Ole,
It is quite involved - particularly where you want to add reviews for merchants as this involves database tables and associated code.
Have you already created your menu? The SQL to select all stores that have products in a particular category is straight forward; for example - if you pass the category through in the URL, the following would do the trick:
$sql = "SELECT DISTINCT(merchant) FROM `".$config_databaseTablePrefix."` WHERE category='".database_safe($_GET["category"])."'";
if (database_querySelect($sql,$rows))
{
foreach($rows as $row)
{
print "<p>".$row["merchant"]."</p>";
}
}
The next step of course is to make the merchant name be a link to your merchant info pages. Let me know what you have done already and how much help you need and I'll try and point you in the right direction...
Cheers,
David.
Hi David,
What i have done so far, is just to modify my page so that it contains your script.
I have s simple
And from there i want to be able to select all the stores that is in one category.
So basically i only have a menu, hehe.
But i dont expect you to tell me this in full detail if it is a really complicated task.
But whatever you can give me of assistance is very much appreciated.
Best regards
Ole S.
Hei david,
Is this is a tricky thing to do?
Best regards
Ole