d4funky1 Posted June 25, 2006 Share Posted June 25, 2006 Hi, I am looking to add some permanent information for each nd every product within my store and a suggestion of hard coding this info into the product_info.php page has arose. Please take a look at the page from my site for example: My Webpage I would like to add 2-3 boxes underneath the reviews & add to cart buttons that would highlight postage, care instructions etc. Can anyone point out whereabouts in the product_info.php file i should start this? Many Thanks D4 Link to comment Share on other sites More sharing options...
Jack_mcs Posted June 25, 2006 Share Posted June 25, 2006 In that file, find this code if ($reviews['count'] > 0) { ?> <tr> <td class="main"><?php echo TEXT_CURRENT_REVIEWS . ' ' . $reviews['count']; ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } and place your code after it as <tr> <td>something goes here</td> </tr> Jack Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
d4funky1 Posted June 25, 2006 Author Share Posted June 25, 2006 Just tried that and got an error message: Parse error: parse error, unexpected '<' in /catalog/product_info.php on line 201 Line 201 being where i inserted the example code: <tr> <td>something goes here</td> </tr> Right after the: if ($reviews['count'] > 0) { ?> <tr> <td class="main"><?php echo TEXT_CURRENT_REVIEWS . ' ' . $reviews['count']; ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } as suggested?? Any ideas? D4 Link to comment Share on other sites More sharing options...
c_karsan Posted June 25, 2006 Share Posted June 25, 2006 Just tried that and got an error message:Line 201 being where i inserted the example code: <tr> <td>something goes here</td> </tr> Right after the: if ($reviews['count'] > 0) { ?> <tr> <td class="main"><?php echo TEXT_CURRENT_REVIEWS . ' ' . $reviews['count']; ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } as suggested?? Any ideas? D4 try putting a ?> on the next line after the curly bracket then put in your code after it remember to enclose your php code within the php tags and to close the tags when moving back to html things can get confusing but should be fairly straightforward once you get the hang of it. The sooner you fall behind, the more time you'll have to catch up. Link to comment Share on other sites More sharing options...
d4funky1 Posted June 25, 2006 Author Share Posted June 25, 2006 ok, I've managed it to a degree, however I seem to be struggling with incorporating it with the style of the page. Do i need to add the stylesheet to this somehow??? Not sure what to do here? Take a look Here Any suggestions would be appreciated. Here's the code i've used to accomplish what you see in the link: ?> <table border="1" cellspacing="0" cellpadding="0"> <tr> <td colspan="3"><font size="-1">Costume Sizes - Adults<br> <br> Most of our adult costumes come in one of two fittings. Standard or Extra Large. These fittings will typically span a range of sizes. Most costumes will have an elasticated waistline or similar design attribute as an adjustment to give a more fitted definition while wearing. It is important to note that unlike fashion designs, fancy dress is designed in a way to fit as broad a range as possible within one fitting. It is therefore possible that your purchase may not be an exact fit and should be thought of as a fun garment.</font></td> </tr> <tr> <td><p><font size="-1"><strong><br> Fitting</strong></font></p> <p><font size="-1">Standard</font></p> <p> </p> <p> </p> <p><font size="-1">Extra Large</font></p> <p> </p></td> <td><p><font size="-1"><strong><br> Ladies</strong></font></p> <p><font size="-1">Dress Size: 10 to 14</font></p> <p> </p> <p> </p> <p><font size="-1">Dress Size: 16 to 20</font></p> <p> </p></td> <td><p><font size="-1"><strong><br> Gentlemen</strong></font></p> <p><font size="-1">Chest: 38" to 42"<br> Waist: 30" to 34"<br> Inside Leg: 30"</font></p> <p> </p> <p><font size="-1">Chest: 44" to 48"<br> Waist: 36" to 40"<br> Inside Leg: 32"</font></p></td> </tr> </table> <?php D4 Link to comment Share on other sites More sharing options...
d4funky1 Posted June 25, 2006 Author Share Posted June 25, 2006 I've made a couple of advancements but still not cracked it check this link to see if you can help: Link Thanks D4 Link to comment Share on other sites More sharing options...
c_karsan Posted June 25, 2006 Share Posted June 25, 2006 I've made a couple of advancements but still not cracked it check this link to see if you can help: Link Thanks D4 hmmm, why don't you put all this as a text definition in the product info language file (you can put html here in the same way), then call it up like with an echo statement similar to the reviews line. it might be a lot better than messing around with the main product_info file. i think the problem is caused due to the tables nesting, try it without the table tag to see what happens The sooner you fall behind, the more time you'll have to catch up. Link to comment Share on other sites More sharing options...
d4funky1 Posted June 26, 2006 Author Share Posted June 26, 2006 Okay, It's pretty much done but still got some alignment issues. Please take a look at the link: Here Here's the code i've used to achieve this: ?> <tr> <td colspan="3" align="left" class="smallText">Costume Sizes - Adults<br> <br> Most of our adult costumes come in standard or extra large. These will typically span a range of sizes. Most costumes will have an elasticated waistline or a similar adjustable attribute to give a more fitted definition while wearing. It is important to note that <strong>fancy dress</strong> is designed in a way to fit as broad a range as possible within one size. It is therefore possible that your costume may not be an exact fit and should be thought of as a fun garment.</font></td> </tr> <tr> <td width="104" align="left" valign="top" class="smallText"><strong><br> Fitting</strong></p> <p>Standard</p> <p> </p> <p> </p> <p>Extra Large</p> <p> </p> <p> </p></td> <td width="186" align="left" valign="top" class="smallText"><p><br> <strong>Ladies</strong></p> <p>Dress Size: 10 to 14</p> <p> </p> <p> </p> <p>Dress Size: 16 to 20</p> </td> <td width="190" align="left" valign="top" class="smallText"><p><br> <strong>Gentlemen</strong></p> <p>Chest: 38" to 42"<br> Waist: 30" to 34"<br> Inside Leg: 30"</p> <p> </p> <p>Chest: 44" to 48"<br> Waist: 36" to 40"<br> Inside Leg: 32"</p></td> </tr> </table> <?php Can anyone point out the obvious for me as I can't see for looking :blush: Many Thanks D4 Link to comment Share on other sites More sharing options...
d4funky1 Posted June 26, 2006 Author Share Posted June 26, 2006 I've cracked it!!! :D Just removed the </table> on the second to last line as there was no <table> instruction within the php commands. Yippee!!! Take a look http://www.fancydressretail.co.uk/catalog/...products_id=223 Thanks to c_karsan & Jack_mcs who helped with this. D4 Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.