kustomjs Posted September 5, 2007 Share Posted September 5, 2007 Hi Guys I am a newbie here and I have a problem with my oscommerce php code and its under admin orders and I am getting this error: Parse error: parse error, unexpected '}' in catalog/admin/orders.php on line 472 and I moded the files with admin notes and google checkout and I also attached my admin code in TXT format [attachment deleted by admin] Quote Link to comment https://forums.phpfreaks.com/topic/68130-i-need-help-on-my-php-but-i-am-getting-errors-on-admin-orders/ Share on other sites More sharing options...
trq Posted September 5, 2007 Share Posted September 5, 2007 Just post the relevent part, 10-20 lines either side of line 472. Quote Link to comment https://forums.phpfreaks.com/topic/68130-i-need-help-on-my-php-but-i-am-getting-errors-on-admin-orders/#findComment-342477 Share on other sites More sharing options...
kustomjs Posted September 5, 2007 Author Share Posted September 5, 2007 ok here it is </form></tr> <tr> <td colspan="2" align="right"><?php echo '<a href="' . tep_href_link(FILENAME_ORDERS_INVOICE, 'oID=' . $HTTP_GET_VARS['oID']) . '" TARGET="_blank">' . tep_image_button('button_invoice.gif', IMAGE_ORDERS_INVOICE) . '</a> <a href="' . tep_href_link(FILENAME_ORDERS_PACKINGSLIP, 'oID=' . $HTTP_GET_VARS['oID']) . '" TARGET="_blank">' . tep_image_button('button_packingslip.gif', IMAGE_ORDERS_PACKINGSLIP) . '</a> <a href="' . tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('action'))) . '">' . tep_image_button('button_back.gif', IMAGE_BACK) . '</a>'; ?></td> </tr> <?php } else { ?> <tr> <td width="100%"><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> Quote Link to comment https://forums.phpfreaks.com/topic/68130-i-need-help-on-my-php-but-i-am-getting-errors-on-admin-orders/#findComment-342483 Share on other sites More sharing options...
Fadion Posted September 5, 2007 Share Posted September 5, 2007 U should understand that posting 875 lines of code is hilarious. As thorpe suggested post only several lines. Anyway i just took a look what was going around line 472. U have an if else statement and im guessing u have two repeated } (one one line 463 and one in line 473). Try removing one of them and see if thats the problem. Quote Link to comment https://forums.phpfreaks.com/topic/68130-i-need-help-on-my-php-but-i-am-getting-errors-on-admin-orders/#findComment-342486 Share on other sites More sharing options...
kustomjs Posted September 5, 2007 Author Share Posted September 5, 2007 I tryed that now I am getting more error codes Quote Link to comment https://forums.phpfreaks.com/topic/68130-i-need-help-on-my-php-but-i-am-getting-errors-on-admin-orders/#findComment-342490 Share on other sites More sharing options...
Fadion Posted September 6, 2007 Share Posted September 6, 2007 No idea, the code is too long to debug. Be sure to have all starting { and ending } in ifs, for's and stuff. Look for any not closed string (" or ') or not escaped characters (like "\""). Quote Link to comment https://forums.phpfreaks.com/topic/68130-i-need-help-on-my-php-but-i-am-getting-errors-on-admin-orders/#findComment-342613 Share on other sites More sharing options...
teng84 Posted September 6, 2007 Share Posted September 6, 2007 i guess the error is not missing } i guess if you missed that it should say expected } not unexpected} so i believe that the error maybe you missed something before that } or you have used this } without the { Quote Link to comment https://forums.phpfreaks.com/topic/68130-i-need-help-on-my-php-but-i-am-getting-errors-on-admin-orders/#findComment-342617 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.