Forums

Can not display Pages : permalink and htaccess problem ? (15 posts)

  1. sablier
    Member
    Posted 4 years ago #

    I am testing WordPress and I have some problems to display Pages. I haven't any problem with posts.

    My permalink option :
    /%post_id%/%postname%/

    I can not display this page :
    http://www.master-marketing.eu/cms/a-propos/

    I have read many things about permalinks and .htaccess.

    I couldn't find my .htaccess using filezilla. It is why I think my problem is about Server Blockage (for more information : http://codex.wordpress.org/Using_Permalinks.

    I have tried to modify wp-includes/vars.php file replacing
    $is_apache = strstr($_SERVER['SERVER_SOFTWARE'], 'Apache') ? 1 : 0;
    by
    $is_apache = 1;

    Unfortunately I haven't the same code.

    I my wp-includes/vars.php file I have :

    // Server detection
    $is_apache = ((strpos($_SERVER['SERVER_SOFTWARE'], 'Apache') !== false) || (strpos($_SERVER['SERVER_SOFTWARE'], 'LiteSpeed') !== false)) ? true : false;
    $is_IIS = (strpos($_SERVER['SERVER_SOFTWARE'], 'Microsoft-IIS') !== false) ? true : false;

    I have tried to replace :
    $is_apache = ((strpos($_SERVER['SERVER_SOFTWARE'], 'Apache') !== false) ||
    by
    // $is_apache = ((strpos($_SERVER['SERVER_SOFTWARE'], 'Apache') !== false) ||
    and i wrote :
    $is_apache = 1;
    under this line.

    I have got a message error line 46 with wp-includes/vars.php file

    What am I doing wrong? Am I on track to think that it is a server blockage ?

  2. moshu
    Member
    Posted 4 years ago #

    For a permalink glitch you should NOT mess with core files ever!
    Your basic permalinks work fine:
    http://www.master-marketing.eu/cms/1/master-marketing-tic/
    which means you do have a ,htaccess file...

    I couldn't find my .htaccess using filezilla.

    Click View > Show hidden files...

    so it must be something in the content of that Page you cannot display. Do other Pages work normally?

  3. sablier
    Member
    Posted 4 years ago #

    Thank you !

    Ok I found a htaccess file :

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

    I can not display pages. None of it. I have updated my permalinks.

    For example :
    http://www.master-marketing.eu/cms/management-relation-client/
    http://www.master-marketing.eu/cms/test/

    The last one only have one word in it : Test.

    Any idea ?

  4. moshu
    Member
    Posted 4 years ago #

    That's weird... Your category archive links don't work either.

    What happens if you switch to another theme like the default or classic?
    Also, does it work when you set your permalinks to default structure?

  5. sablier
    Member
    Posted 4 years ago #

    I have tried with the default them and it works ! The problem seems to be with the morning after theme !?

    When I use the default structure for the permalink I have this message :
    Not Found
    The requested URL /cms/a-propos/ was not found on this server.
    Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

  6. moshu
    Member
    Posted 4 years ago #

    When I use the default structure for the permalink I have this message :
    Not Found
    The requested URL /cms/a-propos/ was not found

    Man, that can NOT happen!
    The default permalink structure looks like
    cms/?page_id=3

  7. sablier
    Member
    Posted 4 years ago #

    You are right. I have just relaoded my page (I am bit tired). With cms/?page_id=2 I still have a blank page.

    Any idea ?

  8. moshu
    Member
    Posted 4 years ago #

    Hmmm..

    I have tried with the default them and it works ! The problem seems to be with the morning after theme !?

    Throw it out.

  9. sablier
    Member
    Posted 4 years ago #

    Bad news ! I like this theme !

  10. moshu
    Member
    Posted 4 years ago #

    On a second thought: there must be something wrong with your server... or some other setup.

    On my local WP install with nice permalinks it works. (I mean I downloaded the theme and installed it on my local test server/WP)

  11. sablier
    Member
    Posted 4 years ago #

    Thank you for this information. I have tried to desactivate all the plugins but I still have the same problem with this theme.

    May be it is my server.

  12. Chrisber
    Member
    Posted 4 years ago #

    I am having the same problem with a new installation at http://www.chrisberryonthe.net/blog/about-me/

  13. moshu
    Member
    Posted 4 years ago #

    No, you have absolutely NOT the same problem.
    You need to read the manual: Using_Permalinks

  14. knoxious
    Member
    Posted 3 years ago #

    hey i have the same problem too..
    but i got it solved.

    1) CHMOD 777 your .htaccess

    2) Update your permalink structure. Once done your should see Successfully Updated.

    3)It should work fine :)

  15. geckospyker
    Member
    Posted 3 years ago #

    I was having a similar problem for a different reason. Most of my WP installations are in the root folder, but I decided to try one in a wordpress named directory instead to see how it worked since I have html files in the root right now (http://glas.earthformed.com/wordpress). Well, when I copied the htaccess file from another wp installation I forgot to remove it's contents before saving it to the wordpress directory. When I tried to view new files I'd created I got error 404 no matter what I did. Well, when I looked closely at the htaccess file, which was set for WP write permissions BTW, I noticed that what wordpress had added had the wordpress/ before all its Rewrite and directive commands. DOH! As soon as I removed what was there before and left what WP had written for me everything worked just fine. Look very closely at your .htaccess file if you are having an issue like this. Especially if you've moved directories recently.

Topic Closed

This topic has been closed to new replies.

About this Topic