webid php error help

Discussion in 'PHP' started by ianhaney, May 3, 2013.

  1. #1
    Hi

    I am using webid for a website I am doing for a customer and have added some extra fields to the sell item page and just before I submit it, the data I entered is not showing up in the confirm listing bit and was wondering if anyone could point me in the right direction, I did check the error log and found this but am bit unsure what to change or alter

    PHP Parse error: syntax error, unexpected ')', expecting '&' or T_STRING or T_VARIABLE or '$' in /home/sites/247autotrade.com/public_html/sell.php on line 551

    Below is line 551 from the coding

    foreach ($system->SETTINGS['make'] as $key => $val)

    That line is taken from the following

    // MAKE
    $TPL_make = '<input type="text" name="make" size="25">' . "\n";
    foreach ($system->SETTINGS['make'] as $key => $val)
    {
    //$TPL_item_condition .= "\t" . '<option value="' . $key . '" ' . (($key == $condition) ? 'selected="true"' : '') . '>' . $val . '</option>' . "\n";
    }
    $TPL_make .= '</input>' . "\n";

    I have a screenshot if anyone needs to see the screenshot of the issue
     
    ianhaney, May 3, 2013 IP
  2. HuggyStudios

    HuggyStudios Well-Known Member

    Messages:
    724
    Likes Received:
    20
    Best Answers:
    26
    Trophy Points:
    165
    #2
    I've tested that code in my IDE and it has no obvious syntax errors. One thing I would do is first you need to make your object property call lower case, secondly var_dump $system->settings['make'] followed by a exit and see what the result is. Debugging is always down to evaluating data.
     
    HuggyStudios, May 3, 2013 IP
  3. hostechsupport

    hostechsupport Well-Known Member

    Messages:
    413
    Likes Received:
    23
    Best Answers:
    7
    Trophy Points:
    138
    #3
    >> Please provide a screenshot of the issue will be easy to resolve.
     
    hostechsupport, Jul 6, 2018 IP