Title: parse error in categories
Last modified: August 21, 2016

---

# parse error in categories

 *  [moriaanvintage](https://wordpress.org/support/users/moriaanvintage/)
 * (@moriaanvintage)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/)
 * Hello,
    We have a webshop with products in different categories and sub-categories.
   Some of the categories only display a product on the site when there is only 
   1 product in this category. When you add another product to this category and
   select this category on the website, it gives the following rsponse:
 * Parse error: syntax error, unexpected ‘$’, expecting ‘&’ or T_VARIABLE in /home/
   moriaanvintage.nl/public_html/shop/wp-content/themes/responsive-child/wpsc-products_page.
   php on line 7
 * I also added a new categorie for testing purposes. Same problem.
 * Does anyone have a solution?
 * Thanks.

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

 *  [Jarret](https://wordpress.org/support/users/jarretc/)
 * (@jarretc)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/#post-4221516)
 * Can you provide us with the content of the /home/moriaanvintage.nl/public_html/
   shop/wp-content/themes/responsive-child/wpsc-products_page.php file inside pastebin.
   com URL or similar so we can see what code you have in there?
 *  Thread Starter [moriaanvintage](https://wordpress.org/support/users/moriaanvintage/)
 * (@moriaanvintage)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/#post-4221535)
 * Hi, thanks for the prompt reply
 * here is a piece of the code:
 * <?php
    global $wp_query; $image_width = get_option(‘product_image_width’); /**
   Most functions called in this page can be found in the wpsc_query.php file */
   jQuery(function($) { $(“form.product_form, .wpsc-add-to-cart-button-form”).die(‘
   submit’).live(‘submit’, function() { return confirm(‘Proceed to Checkout?’); });});?
   >
 *  [Jarret](https://wordpress.org/support/users/jarretc/)
 * (@jarretc)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/#post-4221695)
 * Is this some custom code you’re using? I’m not super great at development but
   I don’t think you can just start calling jQuery within PHP like that.
 *  Thread Starter [moriaanvintage](https://wordpress.org/support/users/moriaanvintage/)
 * (@moriaanvintage)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/#post-4221698)
 * The code was like this from the beginning.
    Some categories work fine and the
   products in these categories are displayed on the site.
 * But some categories only diplay the product, when there is only 1 product in 
   this category. When you add another product, the before mentioned error appears
   on the site.
 * So, why does it only work fine for some categories?
 *  [Andrew Nevins](https://wordpress.org/support/users/anevins/)
 * (@anevins)
 * WCLDN 2018 Contributor | Volunteer support
 * [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/#post-4221703)
 * What is this, a plugin?
 *  [Saravanan S, a11n](https://wordpress.org/support/users/simplysaru/)
 * (@simplysaru)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/#post-4221704)
 * I think it is something to do with the WP-e-commerce plugin. Could you check 
   if the plugin is updated and theme you are using supports the e-commerce plugin.
   Posting the question on the developer’s plugin page will get you a faster reply.
 *  [Andrew Nevins](https://wordpress.org/support/users/anevins/)
 * (@anevins)
 * WCLDN 2018 Contributor | Volunteer support
 * [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/#post-4221707)
 * > The code was like this from the beginning.
 * It can’t have been because you would have had a syntax error from the beginning.
 *  Thread Starter [moriaanvintage](https://wordpress.org/support/users/moriaanvintage/)
 * (@moriaanvintage)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/#post-4221708)
 * The code is part of the products_page.
    The plugin we use is WP-ecommerce. I 
   am also going to post the problem on the wp-ecommerce site.
 * Thanks for the advices so far.

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

The topic ‘parse error in categories’ is closed to new replies.

## Tags

 * [categorie](https://wordpress.org/support/topic-tag/categorie/)
 * [categories](https://wordpress.org/support/topic-tag/categories/)
 * [parse-error](https://wordpress.org/support/topic-tag/parse-error/)
 * [products](https://wordpress.org/support/topic-tag/products/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 8 replies
 * 4 participants
 * Last reply from: [moriaanvintage](https://wordpress.org/support/users/moriaanvintage/)
 * Last activity: [12 years, 7 months ago](https://wordpress.org/support/topic/parse-error-in-categories/#post-4221708)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
