• Resolved Travis S.

    (@travis-s)


    Parse error: syntax error, unexpected ‘<‘ on line 106 is the error I am getting after editing the functions php.

    Before you jump the gun, I typically create a child functions but I’m on a restricted router right now, so I cant access the server. And obviously I’m not an expert with php and what not. I assume unexpected ‘<‘ means that there is a ‘<‘ floating around on line 106 correct? Well there isn’t one as far as I can see.

    I’m using the 2013 theme, so after I got the error message, I pulled up a clean copy of the 2013 functions php, erased my revisions, and plugged in the fresh one. But I still can’t get my site up and running and getting the SAME error.

    I’ve tried accessing the site through other browsers with a cleaned cache but nothing. The only plugin i’m running is css live preview, so I couldn’t imagine there’s much of a conflict.

    Any ideas? Does error ‘<‘ mean that there is an extra one? or does that have to do with spacing? Any help would be much appreciated. Here’s lines 99 through 110 on the clean copy, and also what i replaced in my functions. Maybe it has something to do with that ‘{‘ cause i ran the code through the php code checker. IDK, running out of options.

    99      /*
     100       * This theme uses a custom image size for featured images, displayed on
     101       * "standard" posts and pages.
     102       */
     103      add_theme_support( 'post-thumbnails' );
     104      set_post_thumbnail_size( 604, 270, true );
     105
     106      // This theme uses its own gallery styles.
     107      add_filter( 'use_default_gallery_style', '__return_false' );
     108  }
     109  add_action( 'after_setup_theme', 'twentythirteen_setup' );
     110
Viewing 3 replies - 1 through 3 (of 3 total)
  • /*
    100 * This theme uses a custom image size for featured images, displayed on
    101 * “standard” posts and pages.
    102 */
    103 add_theme_support( ‘post-thumbnails’ );
    104 set_post_thumbnail_size( 604, 270, true );
    105
    106 // This theme uses its own gallery styles.
    107 add_filter( ‘use_default_gallery_style’, ‘__return_false’ );
    108 }
    109 add_action( ‘after_setup_theme’, ‘twentythirteen_setup’ );
    110

    Hey Travis!
    I am not an expert but i wana help you. What i think is you have // sign on 106 that needs to be something like //** your documentation**//
    and also you have a closing } but not “{“.
    i am not sure but see if thats the case!! k!! Good Luck!!

    Thread Starter Travis S.

    (@travis-s)

    thanks for the response, any help is appreciated.

    that was my initial “Why is it like that?” with the “//” comments, but unfortunately it’s not that simple. Chances are you don’t want to look into any more but i’m using this http://phpxref.ftwr.co.uk/wordpress/nav.html?wp-content/themes/twentythirteen/functions.php.source.html which is the clean 2013 functions copy.

    I think my best bet would be to hop on my router, and possibly switch out themes and then reactivate the 2013. for some reason I’m thinking screwing with add_action( ‘after_setup_theme’, ‘twentythirteen_setup’ ); must have corrupted something.

    Your guess is as good as mine, thanks

    Thread Starter Travis S.

    (@travis-s)

    idk what was up with it, what a huge pain. Deleted the 2013 theme and uploaded a fresh one. All is well now.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Error after editing functions php’ is closed to new replies.