WordPress.org

Support

Support » Localhost Installs » This file doesn't do anything, but loads

This file doesn't do anything, but loads

  • Hello,

    I installed WordPress on a fresh Debian server from Debian package and somehow I cannot get it to work correctly. I have this in my apache configuration:

    host:/etc/apache2/sites-available$ cat wordpress
    ## Virtual host VirtualDocumentRoot
    NameVirtualHost *:80
    <VirtualHost *:80>
      ServerName www.examplesite.com
      UseCanonicalName Off
      VirtualDocumentRoot /usr/share/wordpress
      Options All
    
     # wp-content in /srv/www/wp-content/$0
     RewriteEngine On
     RewriteRule ^/wp-content/(.*)$ /srv/www/wp-content/%{HTTP_HOST}/$1
    </VirtualHost>

    Which apparently works fine, since I reach the site, just that the only reponse I get using a browser is this:

    <?php
    /**
     * Front to the WordPress application. This file doesn't do anything, but loads
     * wp-blog-header.php which does and tells WordPress to load the theme.
     *
     * @package WordPress
     */
    
    /**
     * Tells WordPress to load the WordPress theme and output it.
     *
     * @var bool
     */
    define('WP_USE_THEMES', true);
    
    /** Loads the WordPress Environment and Template */
    require('./wp-blog-header.php');

    Any ideas what am I doing wrong?

Viewing 1 replies (of 1 total)
  • Is PHP installed and configured correctly? Because if you’re seeing what you posted in that 2nd block, it means PHP isn’t installed or configured correctly and your server is serving up PHP files as text to your browser!

Viewing 1 replies (of 1 total)
  • The topic ‘This file doesn't do anything, but loads’ is closed to new replies.