WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] After Installation / login can only see front end Home page (.htaccess?) (19 posts)

  1. redsetter
    Member
    Posted 3 years ago #

    Hi I am having trouble running wordpress successfully. I am doing a new install on a new server hosting plan. The Server set is "The Linux Web hosting packages offer a feature full development platform based on CentOS Enterprise Linux, Apache Web server and supporting PHP and Perl"

    All files are put into a folder called public_html. This is a new set up with this server and I wonder could this be the problem as I have used wordpress before but always loaded the files into the root directory or if a subdirectory I would set that in the database. this is not really a subdirectory as this is how the server is set up to find the index of the siteURL

    Things that are happening
    I can do all the 5 step install and activate the site enter basic info go to login page but first after login I get a 500 Internal Server error.

    When I check my files uploaded on the server I do not see my .htaccess file
    nb I do 'check for hidden files' on my ftp program (fetch)

    So I create the .htaccess file with this code in it

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    # END WordPress

    I can then login but the front end home page of wordpress loads and with any other edit command the address changes at the top in the address bar but the frontend home page reloads

    Is this the problem, I don't know .htaccess or what it does but the server peeps suggested that might be redirecting stuff?

    I Keep getting redirected to the wordpress home page 'This is just another wordpress blog'. If i choose edit or any of the options on that page the address in the address bar goes to that request but wordpress front page home page reloads.

    I initially tried version 3.1 and this happened so i tried 3.0.5 but it still happened. I then installed 3.0.0 same process same thing happened. For all these different installs I have completely uninstalled wordpress and deleted database and user. I have installed the 3.1 download on a MAMP set up on my own computer(mac) and it works fine.

    I'm on day 3 of the famous '5 minute install' must be in a bit f a time warp here!

    cheers for any help

  2. redsetter
    Member
    Posted 3 years ago #

    I just tried adding the RewriteBase but no luck. The .htaccess code is in the public_html folder
    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /public_html
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    # END WordPress

  3. arkgroup
    Member
    Posted 3 years ago #

    redsetter,

    This is probably some server error.

    500 error could be caused by:
    1. syntax error in htaccess (to check, just rename existing .htaccess to .htaccess1, if error persist then it's not the .htaccess issue)
    2. wrong permissions and ownership if suphp installed (should be no 777 permissions and ownership like apache/apache or nobody/nobody)
    3. mod_security enabled. If enabled, could be disable by hosting support.
    4. Other server stuff.

    Let hosting support check logs and everything above.

  4. arkgroup
    Member
    Posted 3 years ago #

    Also, RewriteBase /public_html is wrong. Should be just:

    RewriteBase /

  5. govpatel
    Member
    Posted 3 years ago #

    Check your file permissions public_html should 750 your folders 755 and files 644

  6. arkgroup
    Member
    Posted 3 years ago #

    govpatel,

    750 for public_html is not always correct. It depends on the way server configured. I saw different permissions for public_html (private_html, httpdocs, httpsdocs, www, domain.com etc..) folder.

    I suggest not to touch permissions for this folder at all, as it was created by the server automatically and correct.

  7. govpatel
    Member
    Posted 3 years ago #

    they are all root folder names but most cpanel environment I have seen public_html and is set at 750 always check with host if in doubt

  8. redsetter
    Member
    Posted 3 years ago #

    Thanks for all the advice so far but I am still at the same place...stuck

    The hosting company reinstalled my account with all original files and I did a fresh download of wordpress 3.1 installed in no problems but when I first logged in I got the same results.

    (Checked file permissions and the public_html is 750 I am a little nervous to play with file permissions which are automatically set up)

    First login =error 500

    i check files on ftp (fetch) and cannot see .htaccess (I have the box unchecked to not show files beginning with a period

    So I create a .htaccess with notepad plain text no extension using the code

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    # END WordPress

    Upload this. Login in again and I am shown the front end home page even though the address bar says I am in admin

    i check the permissions on this file as I created it realise it is 000 so I change it to 664

    If I look up http://www.mysite.com I am shown the index page that comes automatically with the server, not the front end wordpress page which I assume I should see if it is correctly installed.

    Am I doing everything correct and are there other possible codes for .htaccess i should be using. And why do I have to create the .htaccess file each time? I am working on a mac but fetch is selected to show hidden files when I select the files to 'put'

    this is becoming a bit of an emergency running out of excuses for client!

    many thanks for any help

  9. redsetter
    Member
    Posted 3 years ago #

    Also referring to the instructions

    1. syntax error in htaccess (to check, just rename existing .htaccess to .htaccess1, if error persist then it's not the .htaccess issue)

    I get an error 500 when initially there is no .htaccess file
    When I upload one with the code I can login in but am repeatedly shown the front end home page for wordpress

    When I change the .htaccess to .htaccess1 on the server I get the error 500 again.

    This makes me think it is something in the .htaccess file that is causing the redirect?

  10. govpatel
    Member
    Posted 3 years ago #

    If I look up http://www.mysite.com I am shown the index page that comes automatically with the server, not the front end wordpress page which I assume I should see if it is correctly installed.

    That means that you have place holder in root check if you have index.html or default.html you can delete the place holder.

  11. redsetter
    Member
    Posted 3 years ago #

    thanks I just figured that out but I am still stuck.

    If I delete the .htaccess file I get to the login page but after that I get

    The server encountered an internal error or misconfiguration and was unable to complete your request.

    Please contact the server administrator, webmaster@monicafrawley.com and inform them of the time the error occurred, and anything you might have done that may have caused the error.

    More information about this error may be available in the server error log.

    Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

    I guess it needs to find the .htaccess file. I have tried uploading a blank notepad plain text called .htaccess with full file permission of 777 and it still just shows the wordpress home page even though I am in admin?

  12. govpatel
    Member
    Posted 3 years ago #

    I do not know why you delete .htaccess file as that file needs to be there is hidden file when you log in on server and click on file manager you need to allow to see hidden files.

  13. redsetter
    Member
    Posted 3 years ago #

    thanks I guess I was just trying to troubleshoot things.

    I have put a blank .htaccess file up and I get a server 500 error I have tried playing with all file permissions but still error.

    But

    If i put up a .htaccess file with the code in it as I have been using above I get no 500 error and the front page (wordpress) loads and loads and loads and loads.....

  14. esmi
    Forum Moderator
    Posted 3 years ago #

    You don't use that code in an .htaccess file until you set up custom permalinks. Have you asked your hosts for assistance with this?

  15. budhie
    Member
    Posted 3 years ago #

    Hello,guys.. The file .htaccess is none at the wordpress folder.. There is a file with name wp-config.php in there. If the file .htaccess is none, that file is wp-config.php , soo the file .htaccess is same with the file wp-config.php , sorry i am just can a little an english.

  16. arkgroup
    Member
    Posted 3 years ago #

    redsetter,

    The problem is not in .htaccess if you initially get 500 error without it. There's something else on the server side gives 500 error. Could be mod_security, could be anything else. Hosting support probably encountered such problems before, they should fix it.

    budhie,

    .htaccess and wp-config.php are different files for different purposes. Htaccess file will be created automatically for your wordpress when you enable permalinks.

  17. redsetter
    Member
    Posted 3 years ago #

    Hi thanks to all who helped with this. It was indeed a server security feature. I have posted the resolve emailed to me from my hosting company. Now...a website to build

    thanks again

    The issue was because Sushosin (a security feature) is enabled which was confliciting with a line of code in admin.php. WordPress version 3 has an ini_set in admin.php which tries to change the php memory allocation, suhosin doesn't allow this and as a result the server error was displayed.

    The solution was to add ini_set to Safe Mode disable_functions in the php configuration which solves the issue while also increasing security. No harm to add the solution to your WordPress forum post as it could help others,

  18. arkgroup
    Member
    Posted 3 years ago #

    redsetter,

    Sushosin is a new disaster, seems to be. I've never ever encountered problems related to it, but now it's a second time here at wordpress forum. From now on I'll remember to check for this software if 500 error occures.

  19. SapphireSunHomes
    Member
    Posted 2 years ago #

    I am experiencing the same problem. Where do I find the Safe Mode disable_functions in the php configuration? Once I find it, where do I put the ini_set?

Topic Closed

This topic has been closed to new replies.

About this Topic