• barb331

    (@barb331)


    Hello,
    I was attempting to edit titles per this link:

    http://presscustomizr.com/snippet/setting-custom-titles-featured-pages/

    and received this error:

    Parse error: syntax error, unexpected ‘s’ (T_STRING), expecting ‘)’ in /home/content/p3nexnas06_data02/71/2159571/html/wp-content/themes/customizr-child/functions.php on line 59

    I am now unable to access the site at all.

    The filter I added and customized:

    add_filter('tc_fp_title' , 'my_custom_fp_titles', 10 ,3);
    function my_custom_fp_titles( $original_title , $fp_id = null , $page_id = null ) {
    
        //assigns a custom title by page id
        $custom_title = array(
            //page id => 'Custom title'
            54 => 'More than just translation',
            57 => 'My background',
            60 => 'Contact me'
        );
    
        //if no custom title is defined for the current page id, return original
        if ( ! isset($custom_title[$page_id]) )
            return $original_title;
    
        return $custom_title[$page_id];
    }

    I’m brand new to this, any help i appreciated.

    http://wmcjunkin.com

Viewing 1 replies (of 1 total)
  • Thread Starter barb331

    (@barb331)

    I got the site back up by replacing the child php file with a slightly edited one (via FTP). Working on fixing the filter so it actually works.

Viewing 1 replies (of 1 total)
  • The topic ‘parsing error after adding php filter and unable to edit site’ is closed to new replies.