Support » Themes and Templates » After adding a semicolon my theme’s layout is disfigured

  • Resolved sinaknows


    I need help and don’t know if this is the proper spot to ask or if I should just go to yahoo answers or wherever. I have been seeking for help in google but gosh trying to word the problem the same way as someone else might have worded it is difficult and I’m getting no where. Anyway, I’m not much of an expert on coding, but I was trying to fix an error by placing a semicolon (;) after this line in the coding of the functions.php file:

    foreach ($comm as $t2n=>$t2v){

    When I added the semicolon it looked like this:

    foreach ($comm as $t2n=>$t2v);{

    After updating it and viewing the site it pretty much wiped out the configuration of the layout of the site. So, I went back in to remove the semicolon from the same line, updated, and refreshed the site. The site still looks disfigured, even after removing the semicolon that I should’ve never inserted in that line.

    Will someone help me fix this? Would a semicolon change something else in another file automatically? I mean I don’t understand why the theme didn’t snap back when I removed the semicolon.


Viewing 4 replies - 1 through 4 (of 4 total)
  • sinaknows


    Please view the site to know what I’m talking about:

    Samuel B


    seeing this error
    Warning: Invalid argument supplied for foreach() in /home/hsinaa/public_html/ on line 575

    can’t you upload a fresh/new functions.php from theme source?



    A semicolon does not belong after a conditional arguement in normal brackets.
    It should be just:

    foreach ($comm as $t2n=>$t2v)
    {code in here;}


    Thanks for your two responses. I went into cpanel overrode the old functions.php file by uploaded the original functions.php file from the theme source and it still didn’t work. I also deleted the functions.php (in cpanel) and uploaded a completely new functions.php file and it still didn’t work. The disfigurement did happen until I placed that semicolon there, that’s why I was wondering if it could’ve changed something else in some other file because that was the only change I did. I don’t know.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘After adding a semicolon my theme’s layout is disfigured’ is closed to new replies.