• Resolved rish30990

    (@rish30990)


    Front end of site is working fine. But back end is partially not working. WordPress dashboard (front page of backend) showing error (internal server error). But other pages of back end working fine like plugin page, theme, pages and posts etc.

    So I am getting this error only in dashboard and when I try to update or add a new page. I have tried to disable all plugins and also try to switch to Twenty Fifteen But still problem remains!!!

    Any suggestion what else I can try?

Viewing 7 replies - 16 through 22 (of 22 total)
  • Thread Starter rish30990

    (@rish30990)

    Here I am back with my issue! Previously I thought it got resolved fully But few days ago I came to know that it got resolved partially. The solution which I used sure works but not with all problems

    The problems solved with the above mentioned solution is I can view dashboard and can update pages. But the problem that I have not resolved with it I can’t add new pages and can’t add pages in menus.

    So I have no choice but to make it “not resolved” to “resolved” again because problem was partially solved.

    Although I couldn’t get error log file to get error because of godaddy. But I somehow manage to know about my problem. I downloaded wp_content via ftp and made a local wordpress setup in localhost (xampp).

    By setting in localhost I came to know about error. Error that accure while adding new page is “Creating default object from empty value of line 639 wp-admin/includes/post.php”

    And below code is present in this line :

    $post->post_content = apply_filters( 'default_content', $post_content, $post );

    I searched a lot about it and found some solution. Many user had same issue and they solved it by optimzing database table and repairing database table. But in my case it didn’t work.

    On what step and when error accure?

    After installing again and again I came to know that the error I am facing is because of database!

    These are the steps I follow

    1. First I make new install of wordpress in localhost
    2. Export database from live project.
    3. Change url from database so that it can be import in local setup.

    Note: On installation wordpress creates some tables in database.

    4. Deleted all table from my local database (those table that created by wordpress on onstallation) so that i can import from live project and database imported.

    5. On login I have been asked about updating database and did.

    Note: This is the step (5th step) that cause all trouble. After database update I couldn’t add pages because of the error that I have mentioned above.

    6. To make it more clear I install another wordpress setup in localhost.

    7. This time also I import database but I skip those table which auto created by wordpress on installation. Mean I only upload those table which was not created by wordpress on istallation.

    Note: By doing this way I didnt face any error! But I didn’t get my whole data also. And media library was not showing any images that was present in upload folder( I copied the wp_content folder in local setup to get my themes, plugins and images).

    And Media library was not showing any images because it didn’t have those enteries in database (bcos I skipped those table during import). Becuase of not showing any images from upload folder, post that use to have featured images those posts are blank now. But images that put on page via <img> tag are showing.

    The question here is why I am facing error only when I update database (when after import database in login screen I have been asked for update).

    What changes I should make in my database to that it can keep up with latest version of wordpress although all issues I am facing because of database but how to solve it.

    Any suggestion regarding my issue?

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Try downloading WordPress again, access your server via SFTP or FTP, or a file manager in your hosting account’s control panel, and delete then replace your copies of everything on the server except the wp-config.php file and the /wp-content/ directory with fresh copies from the download. This will effectively replace all of your core files without damaging your content and settings.

    Some uploaders tend to be unreliable when overwriting files, so don’t forget to delete the original files before replacing them.

    Thread Starter rish30990

    (@rish30990)

    How it can be a solution! I already told in my last reply that I have install fresh copy of wordpress and just copy my old /wp_content / folder in that fresh install. So in new install only wp_content folder is old (from my prev. install) else are all new.

    As I told the problem I am facing is because of database (Error accure only when I import database from previous domain to my fresh install database). After import when on login screen database update option appear then I did update and problem start coming afterward.

    So database update option on login screen after importing database is the root of issue.

    It can be solved if I got any Idea about removing this error : “Creating default object from empty value of line 639 wp-admin/includes/post.php”

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    How it can be a solution! … As I told the problem I am facing is because of database.

    Well, because *if* the problem is the database, then you’re totally out of luck if you don’t have a backup, so I’m trying to help you through other things in the hope that it’s not the database.

    It can be solved if I got any Idea about removing this error

    That’s what we’re trying to do, it sounds like a file problem, hence my suggestion.

    If it’s not that, try deactivating all plugins. If that resolves the issue, reactivate each one individually until you find the cause.

    If that does not resolve the issue, try switching to the Twenty Sixteen theme to rule-out a theme-specific issue (theme functions can interfere like plugins).

    Thread Starter rish30990

    (@rish30990)

    Ok I finally solved my problem completely. No issue has left in my project (checked all and everything is fine now). I am sharing solution for future viewers so they can get help from this post.

    What was the problem and what causing it?

    Problem : I was not able to Add, update pages. And I couldn’t check about error in error log file because didn’t have access of that file.

    How I found error: Since I didn’t have errorlog file, I could not find out error easily. So to find out error I use different approach instead of errorlog file. Because I couldn’t see error in my live project so I decide to copy my project in local server (xampp).

    I install fresh copy of wordpress and deleted its /wp_content/ folder So that I can paste /wp_content/ folder from my live project. Mean I simply replace the fresh installed wp_content folder with my live project’s wp_content folder in order to get my pics, themes, plugins in my fresh installed wordpress.

    Next step was to get all data from my database. So I export database from live project and import it in my fresh local wordpress setup database. Although side of exported database was almost 9mb and import capacity of local setup was only 2mb. So to solve this issue I open the exported file in editor (notepad++) and copy the sql queries from it and paste in different file so that I can divide whole code in different files to reduce memory. So I make 6 parts of exported file and each part was below 2 mb. And finally imported it one by one. But don’t forget its important to change the url from exported file. I used find and replace option to change all url and domain name according to my local setup.

    So finally all work from my side over and then tried login then on login screen I was asked to update database so I did. After login when I try to add pages then it was not adding like in my live project. But thats what I wanted because I wanted to know error that accure while adding pages. And since my site was on localhost this time so I can see the error message on top of the screen. The error was Creating default object from empty value of line 639 wp-admin/includes/post.php.

    I searched about it and found that many user solved this error by optimazing database table or by repairing database table. But in my case those solutions didn’t work!

    What was the cause of problem: After installing wordpress again in local and importing database again I came to know that the problem starts when I update database on login screen (After import database from my live project I always being asked at login screen to update it and without update I couldn’t do login so I have no choice but to update).

    Before importing of database everything was fine but all started problematic when I import database. So problem comes when I import database from my previous domain.

    Solution : First I needed to find out what was the actual problem in database. To find out the problem, I have no choice but to import it again and again by deleting prev. data from database.

    At first I deleted whole table (those table that wordpress created on installation) from wordpress database so that I can upload all table from live project’s database. But that cause error.

    Since that method failed to remove error so I tried to upload in different way. This time in new installed wordpress database I didn’t delete any table from database. I just tried to insert data without deleting previous data from new installed wordpress database.

    Changes to be made before importing database file: SInce this time I don’t wanted to delete tables from fresh installed wordpress databse to import new data in it I need to do some changes.

    First Did some changes in exported file: From that First I needed to do some changes in my exported file. In exported sql file I replace all queries of creating table. Mean there was queries like that create table ‘table name’. I use find and replace option and change this query into this – create table if not exist ‘table name’. The benefit of this change is that, If I tried to upload without this change then my file’s queries won’t execute because it will show error that “Table already exist” and data won’t upload.

    Second did some changes in new database: I didn’t want to delete table this time before import the database, But I delete whole data from whose tables. That was necessary Because because while upload I will get error about duplicate primary key.

    After these changes I imported file to my database. And did update on login screen. Although by this approach my all prev. issues was resolved (adding pages) but got one new issue. In front end of only my front page was running! Other pages was showing message like “Object not found”.

    I solved that issue by deleting .htaacess file and click on save permalink option from dashboard -> setting -> permalinks. And that problem also got resolve. All issues fixed.. Hope this will help someone.

    Thanks for the time Mr. James Huff

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Thanks for sharing your solution!

    Thread Starter rish30990

    (@rish30990)

    Ok earlier I got the main Cause of my problem so I am sharing it so that this can be helpful to anybody. As my above mentioned solution works without any problem but if anyone want to do in easy and quick way then here is the solution

    As I told the problem was I couldn’t add pages in wordpress. The reason (which I came to know later) behind was that “wp_posts” table somehow lost its auto increment functionality (may be because of update or import database). Mean ID of table must be auto increment and in my case it was auto increment before update but later it was’t.

    So I just make it auto increment again by going in structure of table and change the setting or ID field to make it auto increment. And problem got solve in 1 minute. Hope it will be helpful for someone.

Viewing 7 replies - 16 through 22 (of 22 total)
  • The topic ‘I am getting internal server error, after updating wordpress to version 4.5.3’ is closed to new replies.