Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Problem on Reviews Page


stef686

Recommended Posts

I have a problem on the reviews page, it seems all the data retrieved from the database appears as the letter L, so it says:

 

by L

 

L

 

 

Rating: L of 5 stars! [L of 5 stars]

 

any ideas why its doing this? :S

Link to comment
Share on other sites

I have a problem on the reviews page, it seems all the data retrieved from the database appears as the letter L, so it says:

 

by L

 

L

Rating: L of 5 stars! [L of 5 stars]

 

any ideas why its doing this? :S

 

:'( I'm having the same problem. It works fine on my test site (unmodified files). I made some changes to the product_reviews.php and product_reviews_write.php files. Everything works fine for these files. The problem is in the product_reviews_info.php file. It just won't display what's actually in the database. The modifications made were to improve the page displayed, I added p.products_thumb to the query and commented out the product name/price varible so that I can list them separately.

 

Can anyone respond with an idea of what and/or where the problem could be?

Link to comment
Share on other sites

I remember fixing this problem for my shop as follows

After line 86 in the default products_reviews_info in the catalog directory add these lines

 

<?php
? ?$review_query = tep_db_query("select rd.reviews_text, r.reviews_rating, r.reviews_id, r.customers_name, r.date_added, r.reviews_read, p.products_id, p.products_price, p.products_tax_class_id, p.products_image, p.products_model, p.products_sku, pd.products_name from " . TABLE_REVIEWS . " r, " . TABLE_REVIEWS_DESCRIPTION . " rd, " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where r.reviews_id = '" . (int)$HTTP_GET_VARS['reviews_id'] . "' and r.reviews_id = rd.reviews_id and rd.languages_id = '" . (int)$languages_id . "' and r.products_id = p.products_id and p.products_status = '1' and p.products_id = pd.products_id and pd.language_id = '". (int)$languages_id . "'");
? ?$review = tep_db_fetch_array($review_query);
?>

 

did I say backup your file first? :lol:

Link to comment
Share on other sites

I remember fixing this problem for my shop as follows

After line 86 in the default products_reviews_info in the catalog directory add these lines

 

<?php
? ?$review_query = tep_db_query("select rd.reviews_text, r.reviews_rating, r.reviews_id, r.customers_name, r.date_added, r.reviews_read, p.products_id, p.products_price, p.products_tax_class_id, p.products_image, p.products_model, p.products_sku, pd.products_name from " . TABLE_REVIEWS . " r, " . TABLE_REVIEWS_DESCRIPTION . " rd, " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where r.reviews_id = '" . (int)$HTTP_GET_VARS['reviews_id'] . "' and r.reviews_id = rd.reviews_id and rd.languages_id = '" . (int)$languages_id . "' and r.products_id = p.products_id and p.products_status = '1' and p.products_id = pd.products_id and pd.language_id = '". (int)$languages_id . "'");
? ?$review = tep_db_fetch_array($review_query);
?>

 

did I say backup your file first?  :lol:

 

 

:thumbsup: Thanks, Enigma1! It worked! This query is already in the file after $review_check query. Copying the same query to above the table it's to be used in did the trick! How odd, but it works!

Link to comment
Share on other sites

I found this happens if you move your reviews to the left colum. Something about the IDs get reused and screwed up. Another fix is to do this in column_left.php

 

  if (!isset($HTTP_GET_VARS['reviews_id'])) include (DIR_WS_BOXES . 'reviews.php');

 

where the reviews box is.

 

So now on product_reviews_info.php, the reviews box won't show, but you won't need it because the user is already looking at the reviews.

Link to comment
Share on other sites

I found this happens if you move your reviews to the left colum.  Something about the IDs get reused and screwed up.  Another fix is to do this in column_left.php

 

 ?if (!isset($HTTP_GET_VARS['reviews_id'])) include (DIR_WS_BOXES . 'reviews.php');

 

where the reviews box is.

 

So now on product_reviews_info.php, the reviews box won't show, but you won't need it because the user is already looking at the reviews.

 

 

Yes! that worked,thanks alot!

Link to comment
Share on other sites

  • 2 weeks later...
I found this happens if you move your reviews to the left colum.  Something about the IDs get reused and screwed up.  Another fix is to do this in column_left.php

 

 ?if (!isset($HTTP_GET_VARS['reviews_id'])) include (DIR_WS_BOXES . 'reviews.php');

 

where the reviews box is.

 

So now on product_reviews_info.php, the reviews box won't show, but you won't need it because the user is already looking at the reviews.

 

I like this remark a lot and indeed it fixed this strange problem. :D (Thnx jclay12345)

For those who enable their boxes like myself, from the admin control panel.

Here's the neccessary code

 

if (BOXES_REVIEWS == 'Yes') {
if (!isset($HTTP_GET_VARS['reviews_id']))
require(DIR_WS_BOXES . 'reviews.php');
}

Kind regards

 

Hakan Haknuz

Link to comment
Share on other sites

  • 5 months later...
I found this happens if you move your reviews to the left colum. Something about the IDs get reused and screwed up. Another fix is to do this in column_left.php

 

 ?if (!isset($HTTP_GET_VARS['reviews_id'])) include (DIR_WS_BOXES . 'reviews.php');

 

where the reviews box is.

 

So now on product_reviews_info.php, the reviews box won't show, but you won't need it because the user is already looking at the reviews.

 

This one worked for me because I moved my reviews to the left column... the other solution didn't seem to work without this.

 

Thanks

Link to comment
Share on other sites

  • 2 weeks later...

Archived

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

×
×
  • Create New...