Results 1 to 3 of 3

Hybrid View

  1. #1
    Join Date
    Dec 2012
    Posts
    66
    Plugin Contributions
    0

    Default Purposes, tpl_reviews_default.php and tpl_product_reviews_default.php (query)

    During customization,

    I customized the listing template for product reviews (tpl_product_reviews_default.php), and matters seemed well in hand. Of course I stored the customized template in my templates override directory. The reviews listing displayed exactly as I had expected. Then, though, I noticed that *occasionally* the default listing template reappeared. After some head-scratching, I noticed that the default listing template displayed only when I clicked the "Read Reviews" button on the template page for writing a review (tpl_product_reviews_write_default.php). I discovered that the "Read Reviews" link on this latter template pointed to a different listing template (tpl_reviews_default.php).

    So to my query: What are the differences in purpose between the tpl_reviews_default.php and tpl_product_reviews_default.php files? On my ZC installation at least, both default templates render exactly the same. I did study the differences in the file codings (best I could, given my limping ability with php), and I see the *coding* differences, but my ZC installation doesn't show any *rendered* differences. The two templates look just the same when rendered.

    My query isn't just academic. As I mentioned, the two separate files caused my customized reviews listing not to show from the Write Reviews page. Rather than customize the second reviews listing template (tpl_reviews_default.php) to match the first one that I customized (tpl_product_reviews_default.php), I just changed the link on the Write Reviews template to go to the tpl_product_reviews_default.php. After making this change, though, I realized that I might be doing something stupid by making this change without fully understanding the file relations. Hence my query.

    Thanks in advance for any direction sent my way,

    Ken Baker

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Purposes, tpl_reviews_default.php and tpl_product_reviews_default.php (query)

    Take two Products and make 2 reviews each and approve them in your admin ...

    Start on the link for Reviews at:
    /index.php?main_page=reviews

    Now open, in a separate tab the button for:
    Read Review

    Next, open in a separate tab the button for:
    More Reviews

    This should help give you a better idea what the different layouts are for and their associated templates ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Dec 2012
    Posts
    66
    Plugin Contributions
    0

    Default Re: Purposes, tpl_reviews_default.php and tpl_product_reviews_default.php (query)

    Ajeh,

    Thanks for the reply. I had already created two test reviews to check my customized template (tpl_product_reviews_default.php). I made both test reviews, though, for the same product, so it *appeared* that both reviews listing pages were identical. I assume from your direction that the tpl_reviews_default.php template will list reviews for all products; I didn't test this assumption, as I've pretty well come to trust your directions in these matters.

    I certainly see the value in a comprehensive reviews listing, though at present I have the Reviews sidebox disabled. I think, though, that I'll leave the Read Reviews link on the Write Reviews page pointed to the specific product reviews listing. To my (at times misguided) way of thinking, if someone sets out to write a review of a specific product, then decides to read the existing reviews first, then that someone would expect to get a listing of the reviews for the specific product. Still, I can now make that choice in light of an understanding of the purposes of both reviews listing templates. That's reassuring.

    Cheers,

    Ken Baker

 

 

Similar Threads

  1. Replies: 4
    Last Post: 17 Jul 2015, 04:44 AM
  2. Replies: 2
    Last Post: 12 Jun 2015, 10:11 PM
  3. how about optimizing Php for SEO purposes?
    By lieven23 in forum General Questions
    Replies: 1
    Last Post: 27 Mar 2009, 02:54 PM
  4. $products_name on tpl_product_reviews_default.php
    By Alex Clarke in forum General Questions
    Replies: 2
    Last Post: 19 Sep 2007, 09:50 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg