berkedam Posted November 28, 2003 Share Posted November 28, 2003 The location: Hardware > Graphic Cards (2). My problem: Because I want to apply more and different CSS (especially the class="productListing-heading") therefore I am looking to separate and move 1 line up, the <tr>*Product Name+* *Price* and *Buy Now*<tr> from the next lower <tr>'s in which the 2 Matrox Cards are shown. So just like the line *Displaying 1 to 2 (of 2 products)* which is now in a separate table under the box, I want to have *Product Name+* *Price* and *Buy Now* also in their own tabel and not in the table of which they are now part of. The sourcecode in question: <table border="0" width="100%" cellspacing="0" cellpadding="2" class="productListing"> <tr> <td align="center" class="productListing-heading"> </td> <td class="productListing-heading"> <a href="http://www.oscommerce.com/osCommerce22ms2/index.php?cPath=1_4&page=1&sort=2d" title="Sort products descendingly by Product Name" class="productListing-heading">Product Name+</a> </td> <td align="right" class="productListing-heading"> <a href="http://www.oscommerce.com/osCommerce22ms2/index.php?cPath=1_4&page=1&sort=3a" title="Sort products ascendingly by Price" class="productListing-heading">Price</a> </td> <td align="center" class="productListing-heading"> Buy Now </td> </tr> <tr class="productListing-odd"> <td align="center" class="productListing-data"> <a href="http://www.oscommerce.com/osCommerce22ms2/product_info.php?cPath=1_4&products_id=1"><img src="images/matrox/mg200mms.gif" border="0" alt="Matrox G200 MMS" title=" Matrox G200 MMS " width="100" height="80"></a> </td> <td class="productListing-data"> <a href="http://www.oscommerce.com/osCommerce22ms2/product_info.php?cPath=1_4&products_id=1">Matrox G200 MMS</a> </td> <td align="right" class="productListing-data"> $299.99 </td> <td align="center" class="productListing-data"><a href="http://www.oscommerce.com/osCommerce22ms2/index.php?cPath=1_4&sort=2a&action=buy_now&products_id=1"><img src="includes/languages/english/images/buttons/button_buy_now.gif" border="0" alt="Buy Now" title=" Buy Now " width="60" height="14"></a> </td> </tr> <tr class="productListing-even"> <td align="center" class="productListing-data"> <a href="http://www.oscommerce.com/osCommerce22ms2/product_info.php?cPath=1_4&products_id=2"><img src="images/matrox/mg400-32mb.gif" border="0" alt="Matrox G400 32MB" title=" Matrox G400 32MB " width="100" height="80"></a> </td> <td class="productListing-data"> <a href="http://www.oscommerce.com/osCommerce22ms2/product_info.php?cPath=1_4&products_id=2">Matrox G400 32MB</a> </td> <td align="right" class="productListing-data"> $499.99 </td> <td align="center" class="productListing-data"><a href="http://www.oscommerce.com/osCommerce22ms2/index.php?cPath=1_4&sort=2a&action=buy_now&products_id=2"><img src="includes/languages/english/images/buttons/button_buy_now.gif" border="0" alt="Buy Now" title=" Buy Now " width="60" height="14"></a> </td> </tr> </table> So I was looking for the table with the 4 offending <td>'s in order to put them in a separate table. After some research having no luck, I finaly arrived at product_listing.php which I think is the file to change, but you guess I cannot find the 4 <td>'s. Starting with line 17 I find: <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td> <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td> </tr> </table> but whatever I do: change parameters like border="10" or even comment-out the whole table, I can see no result anywhere, to me this table makes no sense whatsoever. On line 157 there is another table, that one is used for the line: Displaying 1 to 2 (of 2 products) which shows under the Graphic Cards box. Questions: How do I separate the line " Product Name+ Price Buy Now" from the products underneath. i.e. that line I want in a separate table? Still curious and because I want to know what I'm doing and what is happening: What is the table on line 17 doing there and where can I see changes? ;) You guess right, I know my way around in HTML+CSS, but not much about PHP, try to learn tho :) "If you're working on something new, then you are necessarily an amateur." Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.