Title: Bug in output, wrong class
Last modified: August 30, 2016

---

# Bug in output, wrong class

 *  Resolved [ttremain](https://wordpress.org/support/users/ttremain/)
 * (@ttremain)
 * [11 years ago](https://wordpress.org/support/topic/bug-in-output-wrong-class/)
 * file: inc/amazon-product-in-a-post-functions.php
    Line: 304
 * Uses class: “amazon-new” when this is the used price. The class should be “amazon-
   used”
 * Also, there is no tag that allows the removal of the “used” prices in the shortcode.
 * according to the source, used_price=”0″ should work, but does not. This is also
   an alteration of the format used for listprice=”0″ (both either should or should
   NOT have the underscore) This is what led me to looking at hiding the used prices
   based on the class, but that proved fatal due to the first bug.
 * Lastly, the “buy now” button, is inside a div called “amazon-dates”, which is
   hidden immediately, using the default styles.
    .amazon-dates > div {visibility:
   hidden;}
 * [https://wordpress.org/plugins/amazon-product-in-a-post-plugin/](https://wordpress.org/plugins/amazon-product-in-a-post-plugin/)

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Don Fischer](https://wordpress.org/support/users/prophecy2040/)
 * (@prophecy2040)
 * [11 years ago](https://wordpress.org/support/topic/bug-in-output-wrong-class/#post-6193333)
 * ttremain,
    Thanks for taking the time to be so in depth the the issue on the 
   shortcode used_price parameter. We have already caught this item and it will 
   be in the next update.
 * You will be able to use the following:
 *     ```
       listprice=0 (or 1 - default 1)
       list_price=0 (or 1 - default listprice - alias for listprice)
       show_list=0 (or 1 - default listprice - alias for listprice)
       used_price=0 (or 1 - default 1)
       usedprice=0 (or 1 - default used_price - alias for used_price)
       show_used=0 (or 1 - default used_price - alias for used_price)
       showformat=0 (or 1 - default 1)
       show_format=0 (or 1 - default showformat - alias for showformat)
       ```
   
 * On the “Buy Now” button being wrapped in “amazon-dates” class (and it being hidden):
   
   I think you are mistaken. In version 1.9 of the styles (in effect since version
   3.5.2), there is not a style `.amazon-dates > div {visibility:hidden;}`. There
   _IS_ a style `.amazon-dates br {display:none;}` and that fixes an extra line 
   break issue when there is no additional data for release dates, etc.
 * The new version of the plugin introduces a new version of the styles (version
   2.0) which is more responsive than the previous one.
 * Thanks again for taking the time to write us.
    Warmest regards, Don
 *  Thread Starter [ttremain](https://wordpress.org/support/users/ttremain/)
 * (@ttremain)
 * [11 years ago](https://wordpress.org/support/topic/bug-in-output-wrong-class/#post-6193357)
 * .amazon-dates > div {visibility:hidden;}
 * Was a default setting in the tool, probably when it was first installed. (quite
   some time ago)
 * Still, the buy now buttin, shouldn’t be wrapped in a dates div.
 * It is good to know, with the other settings, that if I make manual changes, then
   next version out the door, shouldn’t break them again.
 * Thanks!
 *  [Don Fischer](https://wordpress.org/support/users/prophecy2040/)
 * (@prophecy2040)
 * [11 years ago](https://wordpress.org/support/topic/bug-in-output-wrong-class/#post-6193359)
 * ttremain,
    I went back through all the versions of the plugin styles, and that
   was not in any of them, so it had to have been added manually. I am the lead 
   programmer and I almost never use ‘visibility:hidden’ on anything, so it made
   me wonder if it was put in there by someone else – but it was not. No big deal.
 * Let me give you a bit of background about the issue you pointed out:
 * > I agree that it is not entirely logical that the button be wrapped in the `'
   > amazon-dates'` class wrapper, but I originally put it there because all of 
   > the product dates (release date, future date, etc.) were there and they were
   > displayed right above the button. The early versions used a table layout for
   > everything, so it was just put in a table with that class and the individual
   > elements had their own `td` classes (amazon-button, etc.). When it was ported
   > to divs instead of tables, it was a conscience decision to leave it that way
   > so if anyone had styles set up dependent on that wrapper, it would not break
   > the style.
   > The hardest part of putting out a plugin, is updating it. You have to make 
   > a conscience effort to ensure that those people that are already using it a
   > certain way, do not get affected if we decide to change the way we do something.
   > In some cases that can’t be helped, but we try to make sure that it does not
   > happen whenever we can.
 * Thanks again for pointing out all of these things – it really does help make 
   things better when others get involved.
 * Warmest regards,
    Don

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Bug in output, wrong class’ is closed to new replies.

 * ![](https://ps.w.org/amazon-product-in-a-post-plugin/assets/icon.svg?rev=1565235)
 * [Amazon Product in a Post Plugin](https://wordpress.org/plugins/amazon-product-in-a-post-plugin/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/amazon-product-in-a-post-plugin/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/amazon-product-in-a-post-plugin/)
 * [Active Topics](https://wordpress.org/support/plugin/amazon-product-in-a-post-plugin/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/amazon-product-in-a-post-plugin/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/amazon-product-in-a-post-plugin/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [Don Fischer](https://wordpress.org/support/users/prophecy2040/)
 * Last activity: [11 years ago](https://wordpress.org/support/topic/bug-in-output-wrong-class/#post-6193359)
 * Status: resolved