On local machine can’t log in or reset password but I can log in on the live version, user has activation key in database

Your local server probably has problems sending mail. There are ways to fix that, but it is probably easiest to change the password in the database directly. Since you’ve made a copy of your site I am going to assume you have access to the database through something like PhpMyAdmin. Follow these instructions to change … Read more

Add update services on theme activation

Themes don’t currently have activation/deactivation/installation/uninstallation hooks. Your best bet is to “fake” it somehow, perhaps with a function that only executes one time, based on a switch that gets toggled when the function executes. e.g.: <?php function wpse45817_theme_activation() { // globalize our switch global $wpse45817_theme_activation_switch; // Check to see if the switch is set if … Read more

Problem creating a table with dbDelta

if( $installed_ver != $simple_location_version ) { on first run, $installed_ver is an empty string and $simple_location_version is NULL, so this inequality test will fail and your SQL will never be executed. if you check for strict inequality, it will work: if( $installed_ver !== $simple_location_version ) {

Viewing output when the “The plugin generated x characters of unexpected output during activation” error is triggered

Interestingly the ability to display errors and output from a plugin on activation seems to be build in to WordPress. If you take a look at wp-admin/plugins.php there’s a case in the $action switch statement that says error_scrape — hinted at in Lars’ answer. Looks like this: <?php // wp-admin/plugins.php case ‘error_scrape’: if ( ! … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)