Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Germ! I need ya! lol... Parse Error... Discount Coupons


lowkey704

Recommended Posts

Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ')' in /var/www/vhosts/themancaveoutletstore.com/httpdocs/admin/includes/boxes/catalog.php on line 37

 

I installed Discount Coupons and on the Admin Side I am getting the error message above... I am not sure if the code even functions at this point because I don't see it in the checkout pages but I am sure you have to set up a code or coupon for it to show...

 

I would be grateful for any help.

 

Lonny

Yeah Yeah I am learning as I go... lol

Link to comment
Share on other sites

Ok so I fixed the problem with line 37 but now there's an error at line 44

 

<?php
/*
 $Id: catalog.php,v 1.21 2003/07/09 01:18:53 hpdl Exp $

 osCommerce, Open Source E-Commerce Solutions
 [url="http://www.oscommerce.com"]http://www.oscommerce.com[/url]

 Copyright © 2002 osCommerce

 Released under the GNU General Public License
*/
?>
<!-- catalog //-->
         <tr>
           <td>
<?php
 $heading = array();
 $contents = array();

 $heading[] = array('text'  => BOX_HEADING_CATALOG,
                    'link'  => tep_href_link(FILENAME_CATEGORIES, 'selected_box=catalog'));

 if ($selected_box == 'catalog') {
   $contents[] = array('text'  => '<a href="' . tep_href_link(FILENAME_CATEGORIES, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS . '</a><br>' .
							   '<a href="' . tep_href_link(FILENAME_FEATURED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_FEATURED_PRODUCTS . '</a><br>' .

                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_ATTRIBUTES, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS_ATTRIBUTES . '</a><br>' .        
                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_ATTRIBUTES_COPIER, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_ATTRIBUTES_COPIER . '</a><br>' .
                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_MULTI, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS_MULTI . '</a><br>' .
                                  '<a href="' . tep_href_link('text_attributes.php', '', 'NONSSL') . '" class="menuBoxContentLink">Text Attributes</a><br>' .

                                  '<a href="' . tep_href_link(FILENAME_MANUFACTURERS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_MANUFACTURERS . '</a><br>' .
                                  '<a href="' . tep_href_link(FILENAME_REVIEWS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_REVIEWS . '</a><br>' .
                                  '<a href="' . tep_href_link(FILENAME_SPECIALS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_SPECIALS . '</a><br>' .
                                //kgt - discount coupons
                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a><br>' .
                                  '<a href="' . tep_href_link(FILENAME_DISCOUNT_COUPONS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_DISCOUNT_COUPONS . '</a>' );
                                  /***************
                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a>' );
                                  ***************/
                                  //end kgt - discount coupons 

       /* Optional Related Products (ORP) */
       '<a href="' . tep_href_link(FILENAME_RELATED_PRODUCTS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_RELATED_PRODUCTS . '</a>');
       //ORP:end
 }

 $box = new box;
 echo $box->menuBox($heading, $contents);
?>
           </td>
         </tr>
<!-- catalog_eof //-->

Yeah Yeah I am learning as I go... lol

Link to comment
Share on other sites

Parse error: syntax error, unexpected ')' in /var/www/vhosts/themancaveoutletstore.com/httpdocs/admin/includes/boxes/catalog.php on line 37

 

'<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a><br>' .

 

I am getting lost to the problem... it was the classic issue... I added a period to the end of the line above and then the error changed to this line below.

 

Parse error: syntax error, unexpected ')' in /var/www/vhosts/themancaveoutletstore.com/httpdocs/admin/includes/boxes/catalog.php on line 47

 

which is this line:

 

'<a href="' . tep_href_link(FILENAME_RELATED_PRODUCTS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_RELATED_PRODUCTS . '</a>' );

 

any ideas are welcomed. I mean that line worked fine before I added this contrib. and I need this code - I need both lol...

 

<?php
/*
 $Id: catalog.php,v 1.21 2003/07/09 01:18:53 hpdl Exp $

 osCommerce, Open Source E-Commerce Solutions
 [url="http://www.oscommerce.com"]http://www.oscommerce.com[/url]

 Copyright © 2002 osCommerce

 Released under the GNU General Public License
*/
?>
<!-- catalog //-->
         <tr>
           <td>
<?php
 $heading = array();
 $contents = array();

 $heading[] = array('text'  => BOX_HEADING_CATALOG,
                    'link'  => tep_href_link(FILENAME_CATEGORIES, 'selected_box=catalog'));

 if ($selected_box == 'catalog') {
   $contents[] = array('text'  => '<a href="' . tep_href_link(FILENAME_CATEGORIES, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS . '</a><br>' .
							   '<a href="' . tep_href_link(FILENAME_FEATURED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_FEATURED_PRODUCTS . '</a><br>' .

                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_ATTRIBUTES, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS_ATTRIBUTES . '</a><br>' .        
                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_ATTRIBUTES_COPIER, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_ATTRIBUTES_COPIER . '</a><br>' .
                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_MULTI, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS_MULTI . '</a><br>' .
                                  '<a href="' . tep_href_link('text_attributes.php', '', 'NONSSL') . '" class="menuBoxContentLink">Text Attributes</a><br>' .

                                  '<a href="' . tep_href_link(FILENAME_MANUFACTURERS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_MANUFACTURERS . '</a><br>' .
                                  '<a href="' . tep_href_link(FILENAME_REVIEWS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_REVIEWS . '</a><br>' .
                                  '<a href="' . tep_href_link(FILENAME_SPECIALS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_SPECIALS . '</a><br>' .



                                 //kgt - discount coupons
                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a><br>' .
                                  '<a href="' . tep_href_link(FILENAME_DISCOUNT_COUPONS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_DISCOUNT_COUPONS . '</a>' );
                                  /***************
                                  '<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a>' );
                                  ***************/
                                  //end kgt - discount coupons 

        /* Optional Related Products (ORP) */
       '<a href="' . tep_href_link(FILENAME_RELATED_PRODUCTS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_RELATED_PRODUCTS . '</a>' );
       //ORP:end

       }

 $box = new box;
 echo $box->menuBox($heading, $contents);
?>
           </td>
         </tr>
<!-- catalog_eof //-->

Yeah Yeah I am learning as I go... lol

Link to comment
Share on other sites

hmmmm actually I took this line out completely cause there is another way to get to it... through adding or editing products. My admin panel is back up... Do I need to keep this line for any reason in the catalog?

 

/* Optional Related Products (ORP) */

'<a href="' . tep_href_link(FILENAME_RELATED_PRODUCTS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_RELATED_PRODUCTS . '</a>' );

//ORP:end

Yeah Yeah I am learning as I go... lol

Link to comment
Share on other sites

hmmmm actually I took this line out completely cause there is another way to get to it... through adding or editing products. My admin panel is back up... Do I need to keep this line for any reason in the catalog?

 

/* Optional Related Products (ORP) */

'<a href="' . tep_href_link(FILENAME_RELATED_PRODUCTS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_RELATED_PRODUCTS . '</a>' );

//ORP:end

You can do whatever you want, you just need to ensure that the last entry end in the ; like

 

. '</a>');

 

and the ones above end in a period like

 

. '</a><br>' .

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...