Difference between revisions of "Wordpress"

From Hackepedia
Jump to navigationJump to search
 
(One intermediate revision by the same user not shown)
Line 8: Line 8:
 
  UPDATE `[[Variables|newprefix]]_usermeta` SET `meta_key` = REPLACE( `meta_key` , 'wp_', '[[Variables|newprefix_]]' );
 
  UPDATE `[[Variables|newprefix]]_usermeta` SET `meta_key` = REPLACE( `meta_key` , 'wp_', '[[Variables|newprefix_]]' );
  
  UPDATE `[[Variables|newprefix]]_options` SET `option_name` = '[[Variables|newprefix]]_user_roles' WHERE `option_name` ='wp_user_roles' AND `blog_id` =0;
+
  UPDATE `[[Variables|newprefix]]_options` SET `option_name` = '[[Variables|newprefix]]_user_roles'  
 +
WHERE `option_name` ='wp_user_roles' AND `blog_id` =0;
  
Replace newprefix in both places with your new prefix.
+
Replace newprefix with your new prefix.

Latest revision as of 13:45, 26 April 2010

If you want to embed php in Wordpress, you will want to install the Exec php plugin.

You do not have sufficient permissions to access this page.

This likely happened due to you renaming the wp_ prefix to something else to prevent SQL injection attacks. If so, there is one last mysql command you should run on your database (after doing a backup).

UPDATE `newprefix_usermeta` SET `meta_key` = REPLACE( `meta_key` , 'wp_', 'newprefix_' );
UPDATE `newprefix_options` SET `option_name` = 'newprefix_user_roles' 
WHERE `option_name` ='wp_user_roles' AND `blog_id` =0;

Replace newprefix with your new prefix.