WordPress.org

Ready to get started?Download WordPress

Forums

Website not working (9 posts)

  1. WritingButler
    Member
    Posted 1 year ago #

    Hi,

    I downloaded some code and inserted into my wordpress.com theme .php. Now I can't access my site. The code was supposed to allow me to write pages with summary only and (...more)
    However when I inserted the code I must have misplaced it in the php and voila I can't access my site. Here is the message I receive when attempting to log in:Parse error: syntax error, unexpected T_FUNCTION in /home/content/94/8738594/html/wp-content/themes/associate/functions.php on line 82

    Here is the code I inserted into theme:add_action( 'init', 'my_add_excerpts_to_pages' );
    function my_add_excerpts_to_pages() {
    add_post_type_support( 'page', 'excerpt' );
    }

    Thanks if anyone can tell me how to access my wp-admin and delete this code.
    AB. My website is: http://www.thewritingbutler.com

  2. Krishna
    Volunteer Moderator
    Posted 1 year ago #

    Deactivate all plugins and revert to Twenty Eleven theme. Use FTP or your hosting login to rename themes and plugins except Twenty Eleven.

    Backup your site, especially database before doing anything else.

  3. WritingButler
    Member
    Posted 1 year ago #

    Hi Krishna,

    Many thanks but wouldn't I have to log in to do this? I think if I could log in to my site, I could simply delete the code I foolishly entered and I'd be back to normal. My immediate problem is not being able to log in.
    Alastair

  4. The_Blog_Effect
    Member
    Posted 1 year ago #

    Hi Alastair,

    Using FTP, download the file you updated to your computer, edit it on your computer and using a program like textpad, remove the code upload the file back to your site and see if that fixes the problem.

    If that doesn't work, try renaming the plugins folder using FTP
    /www/wp-content/plugins
    to something like
    /www/wp-content/p--lugins
    and see if you can login. Once logged in disable all plugins. (they will be disabled because you renamed the folder) then with all the plugins disabled. Using FTP rename the plugin folder back to
    /www/wp-content/plugins

    Activate each plugin one at time testing your site. with each plugin reactivation.
    Hope this Helps

  5. WritingButler
    Member
    Posted 1 year ago #

    Hi Blog Effect,

    Many thanks. I couldn't begin to understand all your information but appreciate your help. I'll see if I can hire somebody who can handle it and will pass your information along to them.

    I simply tried to insert some code in order to use "summary" on my "Writing samples" page. I should have left well enough alone. I had a "web guy" who set up what I would consider a complicated WordPress site and he left without warning leaving me stranded. Seems to happen a lot.

    I thought when I put in the code to summarize my writing samples, if it didn't work all I had to do was remove it. Never thought I'd be shut out of the site.

    Again my thanks
    Alastair.

  6. The_Blog_Effect
    Member
    Posted 1 year ago #

    Hi Alastair,

    If you like email me, You can find my email at:
    http://www.theblogeffect.com/contact-us/

    I will fix it for you no charge. I do need some information form you, that's why I want you to email me, you can't post that type of information in a public forum.

    Acey

  7. esmi
    Theme Diva & Forum Moderator
    Posted 1 year ago #

    @The_Blog_Effect: I appreciate that you mean well but please do not encourage people to contact you directly. These forums do not provide support via email and you should not encourage people to send sensitive site information to anyone other than a developer that they have engaged commercially.

    @WritingButler: Please try http://jobs.wordpress.net/

  8. The_Blog_Effect
    Member
    Posted 1 year ago #

    Hi Esmi

    Oh okay, I was just trying to help, not to make money. But I get understand what you are saying and will remember that for future posts.

    Thanks for letting me know
    Acey

  9. jhonson
    Member
    Posted 1 year ago #

    sir your solution are very easy.if your theme backup in your pc.
    go to cpanel and open the function.php file
    and copy pc to cpanel function file.
    and refresh the wordpress.
    your problem r solved.

    other thing add in function then change via cpanel.not wordpress.

Topic Closed

This topic has been closed to new replies.

About this Topic