Skip to content

Instantly share code, notes, and snippets.

@pelmered
Created February 27, 2017 20:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pelmered/096d436d237454fd78051c14982609c6 to your computer and use it in GitHub Desktop.
Save pelmered/096d436d237454fd78051c14982609c6 to your computer and use it in GitHub Desktop.
Fix issues with symlinked wordpress
<?php
/**
* Fixes issues with symlinked wordpress
*/
if ( defined('ABSPATH') ) {
$fixed_abspath = str_replace( 'wordpress', 'public', ABSPATH );
define('WP_CONTENT_DIR', $fixed_abspath . 'wp-content');
define('WP_PLUGIN_DIR', $fixed_abspath . 'wp-content/plugins');
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment