Thread: Order Error,

Results 1 to 10 of 11

Hybrid View

  1. #1
    Join Date
    Feb 2007
    Posts
    130
    Plugin Contributions
    0

    database error Order Error,

    Hi all, I hope somebody can help me, i do not have a clue on this one.

    I have a new customer and for some reason when i try and view the details of the order i am getting an error message. It has only just started happening, has anybody got any idea of how to fix this

    Parse error: syntax error, unexpected T_CASE in /home/****/public_html/admin/orders.php on line 195






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

    Default Re: Order Error,

    What do you have on lines 180 to 206 of the file:
    /admin/orders.php
    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
    Feb 2007
    Posts
    130
    Plugin Contributions
    0

    Default Re: Order Error,

    whats the quickest way to finding the line numbers, what program shall i use, i usually use notepad and i really do not want to count the lines. please let me know another way

  4. #4
    Join Date
    Feb 2007
    Posts
    130
    Plugin Contributions
    0

    Default Re: Order Error,

    its alright, i can do it in notepad

  5. #5
    Join Date
    Feb 2007
    Posts
    130
    Plugin Contributions
    0

    Default Re: Order Error,

    Quote Originally Posted by Ajeh View Post
    What do you have on lines 180 to 206 of the file:
    /admin/orders.php
    PHP Code:
     if (($action == 'edit') && isset($_GET['oID'])) {
        
    $oID zen_db_prepare_input($_GET['oID']);

        
    $orders $db->Execute("select orders_id from " TABLE_ORDERS "
                                where orders_id = '" 
    . (int)$oID "'");

        
    $order_exists true;
        if (
    $orders->RecordCount() <= 0) {
          
    $order_exists false;
          
    $messageStack->add(sprintf(ERROR_ORDER_DOES_NOT_EXIST$oID), 'error');

          case 
    'doRefund':
            
    $order = new order($oID);
            if (
    $order->info['payment_module_code']) {
              if (
    file_exists(DIR_FS_CATALOG_MODULES 'payment/' $order->info['payment_module_code'] . '.php')) {
                require_once(
    DIR_FS_CATALOG_MODULES 'payment/' $order->info['payment_module_code'] . '.php');
                require_once(
    DIR_FS_CATALOG_LANGUAGES $_SESSION['language'] . '/modules/payment/' $order->info['payment_module_code'] . '.php');
                
    $module = new $order->info['payment_module_code'];
                if (
    method_exists($module'_doRefund')) {
                  
    $module->_doRefund($oID);
                }
              }
            }
            
    zen_redirect(zen_href_link(FILENAME_ORDERSzen_get_all_get_params(array('action')) . 'action=edit''NONSSL'));
            break;
          case 
    'doAuth':
            
    $order = new order($oID);
            if (
    $order->info['payment_module_code']) {
              if (
    file_exists(DIR_FS_CATALOG_MODULES 'payment/' $order->info['payment_module_code'] . '.php')) {
                require_once(
    DIR_FS_CATALOG_MODULES 'payment/' $order->info['payment_module_code'] . '.php');
                require_once(
    DIR_FS_CATALOG_LANGUAGES $_SESSION['language'] . '/modules/payment/' $order->info['payment_module_code'] . '.php');
                
    $module = new $order->info['payment_module_code'];
                if (
    method_exists($module'_doAuth')) {
                  
    $module->_doAuth($oID$order->info['total'], $order->info['currency']);
                }
              }
            } 
    Last edited by Ajeh; 27 May 2007 at 12:06 AM. Reason: added php tags for clarity

  6. #6
    Join Date
    Feb 2007
    Posts
    130
    Plugin Contributions
    0

    Default Re: Order Error,

    line 195 is

    case 'doRefund':

  7. #7
    Join Date
    Feb 2007
    Posts
    130
    Plugin Contributions
    0

    Default Re: Order Error,

    anybody got any ideas what the problem is

  8. #8
    Join Date
    Aug 2004
    Posts
    1,590
    Plugin Contributions
    1

    Default Re: Order Error,

    Very odd but don't see the switch command before applying the case.

  9. #9
    Join Date
    Feb 2007
    Posts
    130
    Plugin Contributions
    0

    Default Re: Order Error,

    i am not sure what is happening but i added a new copy of the order.php and overwrite it and its seems to be working fine now.

 

 

Similar Threads

  1. Replies: 1
    Last Post: 27 Mar 2015, 08:54 AM
  2. Error on Order Total
    By annettes in forum General Questions
    Replies: 6
    Last Post: 14 Apr 2011, 12:36 AM
  3. Replies: 2
    Last Post: 20 Jul 2010, 04:40 PM

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