Difference between revisions of "Wordpress"
Rootadminacc (talk | contribs) (Created page with "== Wordpress and .htaccess == Add Options +FollowSymLinks if you get the below error on Wordpress sites: ''Forbidden, perhaps you need to chang...") |
Rootadminacc (talk | contribs) |
||
Line 1: | Line 1: | ||
== [[ | == [[Linux#.htaccess | Wordpress and .htaccess]] == | ||
Add Options +FollowSymLinks if you get the below error on Wordpress sites: | Add Options +FollowSymLinks if you get the below error on Wordpress sites: |
Revision as of 11:41, 15 January 2013
Wordpress and .htaccess
Add Options +FollowSymLinks if you get the below error on Wordpress sites:
Forbidden, perhaps you need to change the file permissions for this document or upload an index page
For Pretty Permalinks this is the .htaccess template:
# BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress
The dangers of 777 permissions
If folders/files are set to 777 this can cause escalated conflicts. This could lead to your server being compromised and future errors.
Uploading images or videos fails
When you go into the following place in Plesk:
- Domain/Webspace control panel
- Applications tab
- Manage Installed Applications
- Click the value under Name (normally Wordpress Instance)
- Administrative interface
- Pages
And uploading an image or video fails and you get HTTP Error or 500 Internal Server Error this is normally caused by the following three settings and should be changed in this order:
- Ensure the domain is using PHP Support as Fast CGI
- Navigate to /etc/apache2/mods-available/ or /etc/httpd/conf.d/ in SSH
- Edit the CGI (cgid.conf)/Fast CGI (fcgid.conf) configuration file (depends what the Apache module is for that domain)
/etc/apache2/mods-available/fcgid.conf /etc/httpd/conf.d/fcgid.conf
- Add in one of the below values in between the <IfModule> and </IfModule> tags. It should appear in white if correct.
FcgidMaxRequestLen 134217728 #128MB FcgidMaxRequestLen 268435456 #256MB FcgidMaxRequestLen 536870912 #512MB #or cgid for CGI
- Restart Apache by using /etc/init.d/apache2 restart or /etc/init.d/httpd restart
- Check the user:group that is set for other Wordpress folders
- Change the user/group for wp-content/uploads (normally from www-data) to chown -R ftpuser:psacln /var/www/vhosts/domain.com/httpdocs/wp-content/uploads/
- Remove the mod security entry from .htaccess or the file itself.
http://forum.parallels.com/showthread.php?t=112735
Fast CGI Configuration files
/etc/apache2/mods-available/fcgid.load /etc/apache2/mods-available/fcgid.conf
Additional notes:
- MaxRequestLen is a setting that determines the max file size upload
- mod security was blocking user agent of the flas user
Error Establishing a Database Connection
This is normally caused by the following settings being wrong in wp-config.php:
define('DB_NAME', 'databasename'); /** MySQL database username */ define('DB_USER', 'user'); /** MySQL database password */ define('DB_PASSWORD', 'userpasswordhere'); /** MySQL hostname */ define('DB_HOST', 'localhost');
A good guide is here on Youtube.
Multisite
http://mashable.com/2012/07/26/beginner-guide-wordpress-multisite
http://codex.wordpress.org/Migrating_Multiple_Blogs_into_WordPress_3.0_Multisite
Performance
In order to improve site performance for your Wordpress driven site, you can disable caching plugins on your site by logging into the Wordpress admin dashboard for your site and disable any caching plugins found under the plugins menu. The 2 most popular caching plugins used within Wordpress are WP-super-cache and W3-total-cache
http://www.gowebbaby.com/wordpress-website-running-slow
Asks for FTP account while trying to install
Intergrate with MSSQL
Wordpress requires MySQL to run and most plugins use MYSQL, any plugin would need to be rewritten to use MSSQL.