Skip to content

Instantly share code, notes, and snippets.

@duogeekdev
duogeekdev / gist:578e91895befcc361bc7
Created May 9, 2015 22:14
Allowing Unfiltered WordPress Uploads for Administrators
<?php
define( 'ALLOW_UNFILTERED_UPLOADS', true );
@duogeekdev
duogeekdev / gist:666c67ec7e2ceceec7d7
Created May 9, 2015 22:16
Override File Permissions
<?php
define( 'FS_CHMOD_FILE', 0755 );
define( 'FS_CHMOD_DIR', 0644 );
<?php
define( 'AUTOSAVE_INTERVAL', 120 ); // in seconds
@duogeekdev
duogeekdev / gist:be159ea4c60bac7a2164
Created May 9, 2015 22:18
Increase PHP Memory Limit
<?php
define( 'WP_MEMORY_LIMIT', '256M' ); // for front end
define( 'WP_MAX_MEMORY_LIMIT', '256M' ); // for admin end
@duogeekdev
duogeekdev / gist:dad0a55257e9b0da2881
Created May 9, 2015 22:19
Custom User / UserMeta Tables
<?php
define( 'CUSTOM_USER_TABLE', $table_prefix . 'custom_users' );
define( 'CUSTOM_USER_META_TABLE', $table_prefix . 'custom_usermeta' );
@duogeekdev
duogeekdev / gist:d76884c1a06f56f14298
Created May 9, 2015 22:21
Setup PHP Ini Settings
<?php
/** Turns the output of errors on or off, you really never want this on, you should only view errors by reading the log file. */
ini_set('display_errors', WP_DEBUG_DISPLAY);
/** Tells whether script error messages should be logged to the server's error log or error_log. */
ini_set('log_errors', 'On');
/** http://us.php.net/manual/en/timezones.php */
ini_set('date.timezone', 'America/Indianapolis');
<?php
define ( 'COOKIE_DOMAIN', 'www.domain.com' );
@duogeekdev
duogeekdev / gist:80ced57d29bdd7611ab4
Created May 9, 2015 22:23
Disable JavaScript concatenation
<?php
define( 'CONCATENATE_SCRIPTS', false );
@duogeekdev
duogeekdev / gist:5a1d21476350855fa557
Created May 9, 2015 22:06
Set akismet key for multisite network
<?php
define( 'WPCOM_API_KEY','your-akismet-key' );
@duogeekdev
duogeekdev / gist:8f22a45f372796e59bac
Created May 9, 2015 22:04
Disable the Theme and Plugin Editors
<?php
define( 'DISALLOW_FILE_EDIT', true );