Jump to content

Archived

This topic is now archived and is closed to further replies.

luigicosta

review random

Recommended Posts

Hello everyone, I'm trying to put the main page "index page"

5 columns in 2 rows

that is written on the top line the name of who wrote the comment and the comment in the second row

of course so random in the sense that every time you access the page names and comments are random.

and in addition put a page where you can read all the comments even if they are 200 or 300 ....

ideas?? suggestions??

thanks

LC

Share this post


Link to post
Share on other sites

I just start from here....

   <div class="contentContainer"><hr></div>
   <div class="contentText">

   <?php echo tep_image(DIR_WS_IMAGES . 'what_our_customers_think_609x21.jpg', STORE_NAME); ?>  > leggi commenti - > scrivi un commento  
   <br><br>

   <?php
   $reviews_query_raw = "select r.reviews_id, left(rd.reviews_text, 10) as reviews_text, r.customers_name from " . TABLE_REVIEWS . " r, " . TABLE_REVIEWS_DESCRIPTION . " rd, " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = r.products_id and r.reviews_id = rd.reviews_id and p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' and rd.languages_id = '" . (int)$languages_id . "' and reviews_status = 1 order by r.reviews_id DESC";
   ?>   




<table width="100%" border="0" align="center" cellpadding="5" cellspacing="5">
 <tr>
   <td background="/images/testimonial_speech_bubble_184x54.jpg"><?php echo sprintf(TEXT_REVIEW_BY, tep_output_string_protected($reviews['customers_name'])); ?></td>
   <td background="/images/testimonial_speech_bubble_184x54.jpg"></td>
   <td background="/images/testimonial_speech_bubble_184x54.jpg"></td>
   <td background="/images/testimonial_speech_bubble_184x54.jpg"></td>
   <td background="/images/testimonial_speech_bubble_184x54.jpg"></td>
 </tr>
 <tr>
   <td><?php echo tep_break_string(tep_output_string_protected($reviews['reviews_text']), 60, '-<br />') . ((strlen($reviews['reviews_text']) >= 100) ? '..' : '') ?></td>
   <td></td>
   <td></td>
   <td></td>
   <td></td>
 </tr>
</table>

Share this post


Link to post
Share on other sites

×