Page 1 of 2 12 LastLast
Results 1 to 10 of 14

Thread: Wordpress and Apache

  1. #1

    Default Wordpress and Apache

    In installed worpdress in a subdirectory under /srv/www/htdocs and it seems to be working but when I perform certain operations I get a 404 error object not found.
    The site is under /srv/www/htdocs/test
    When I get the error I see in the url bar http://localhost/wp-admin/options-ge...ge=WP-GPX-Maps (the "test" part in the url is missing)
    I think Apache is not rewriting well but I cant find out why.
    Here's my .htaccess file:

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

  2. #2
    Join Date
    Jun 2008
    Location
    Groningen, Netherlands
    Posts
    19,861
    Blog Entries
    14

    Default Re: Wordpress and Apache

    Quote Originally Posted by roberto_guerra View Post
    In installed worpdress in a subdirectory under /srv/www/htdocs and it seems to be working but when I perform certain operations I get a 404 error object not found.
    The site is under /srv/www/htdocs/test
    When I get the error I see in the url bar http://localhost/wp-admin/options-ge...ge=WP-GPX-Maps (the "test" part in the url is missing)
    I think Apache is not rewriting well but I cant find out why.
    Here's my .htaccess file:

    Code:
    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /test/
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /test/index.php [L]
    </IfModule>
    # END WordPress
    AFAICS you're already giving the answer yourself: Is mod-rewrite installed and loaded ?
    Please show
    Code:
    sudo a2enmod -l
    , between CODE tags, the # in the layout ribbon.
    ° Appreciate my reply? Click the star and let me know why.

    ° Perfection is not gonna happen. No way.

    https://en.opensuse.org/openSUSE:Board#Members
    http://en.opensuse.org/User:Knurpht
    http://nl.opensuse.org/Gebruiker:Knurpht

  3. #3

    Default Re: Wordpress and Apache

    Yes, it is

    Here's the output:
    actions alias auth_basic authn_file authz_host authz_groupfile authz_core authz_user autoindex cgi dir env expires include log_config mime negotiation setenvif ssl socache_shmcb userdir reqtimeout php5 authn_core version rewrite

  4. #4
    Join Date
    Jun 2008
    Location
    Groningen, Netherlands
    Posts
    19,861
    Blog Entries
    14

    Default Re: Wordpress and Apache

    Quote Originally Posted by roberto_guerra View Post
    Yes, it is

    Here's the output:
    actions alias auth_basic authn_file authz_host authz_groupfile authz_core authz_user autoindex cgi dir env expires include log_config mime negotiation setenvif ssl socache_shmcb userdir reqtimeout php5 authn_core version rewrite
    So, mod_rewrite is installed and active. There must be something wrong in your WP config.
    Last edited by hcvv; 24-Apr-2018 at 05:45. Reason: repaired QUOTE tag
    ° Appreciate my reply? Click the star and let me know why.

    ° Perfection is not gonna happen. No way.

    https://en.opensuse.org/openSUSE:Board#Members
    http://en.opensuse.org/User:Knurpht
    http://nl.opensuse.org/Gebruiker:Knurpht

  5. #5

    Default Re: Wordpress and Apache

    It's a basical installation of Wordpress.
    I think it's something related to OpenSuse's Apache default configuration, but I can't find out what...

  6. #6
    Join Date
    Mar 2016
    Location
    Netherlands
    Posts
    7

    Default Re: Wordpress and Apache

    Hello Roberto,

    I recently started a blog myself. (Fossadventures.com) I found some handy articles.

    You could follow this tutorial for the LAMP install:
    https://www.howtoforge.com/tutorial/...opensuse_42.1/

    And then follow this tutorial for the Worpress part:
    https://www.howtoforge.com/tutorial/...use-leap-42-1/

    Replace the nano in the tutorial with your own site name.

    I installed wordpress in the /srv/www/ directory instead of /srv/www/htdocs/.

    (Also I use Nginx instead of Apache).


    I hope this might help you to progress in a different way.

    Best regards,
    Martin

  7. #7

    Default Re: Wordpress and Apache

    Same beahvior in an XAMPP environment under Windows.
    Changing permalink settings in wordpress does not seem to help...

  8. #8
    Join Date
    Jun 2008
    Location
    Groningen, Netherlands
    Posts
    19,861
    Blog Entries
    14

    Default Re: Wordpress and Apache

    Adjust the host to have /srv/www/htdocs/test as the webroot
    ° Appreciate my reply? Click the star and let me know why.

    ° Perfection is not gonna happen. No way.

    https://en.opensuse.org/openSUSE:Board#Members
    http://en.opensuse.org/User:Knurpht
    http://nl.opensuse.org/Gebruiker:Knurpht

  9. #9
    Join Date
    Feb 2010
    Location
    Germany
    Posts
    2,559

    Question Re: Wordpress and Apache

    Quote Originally Posted by roberto_guerra View Post
    In installed worpdress in a subdirectory under /srv/www/htdocs and it seems to be working but when I perform certain operations I get a 404 error object not found.
    The site is under /srv/www/htdocs/test
    Where did you obtain the version of WordPress you're using?

    The openSUSE WordPress package is available from the "openSUSE BuildService - PHP:Applications" repository. <http://download.opensuse.org/reposit...USE_Leap_42.3/>

    Among other things, the openSUSE README mentions:
    Wordpress is installed to /srv/www/wordpress.

    An apache mapping is setup to allow it to be accessed at http://your.domain.com/wp

  10. #10

    Default Re: Wordpress and Apache

    Quote Originally Posted by Knurpht View Post
    Adjust the host to have /srv/www/htdocs/test as the webroot
    I have other test sites in other folders, like this

    /srv/www/htdocs/test2
    /srv/www/htdocs/test3
    /srv/www/htdocs/test4
    and so on

    changing the document root doesn't affect them all?

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •