How delete post_content records of specific category from phpmyadmin
How delete post_content records of specific category from phpmyadmin
Yes. You can do. Try using ajax, or better? using wordpress rest api Ajax method: need register your function and action to do Simple example: add_action( ‘wp_ajax_my_action’, ‘my_action’ ); add_action( ‘wp_ajax_nopriv_my_action’, ‘my_action’ ); function my_action() { return json_encode(‘hello word’); } jQuery(document).ready(function() { var data = { ‘action’: ‘my_action’ }; jQuery.post(ajax_url, data, function(response) { alert(response); }); … Read more
Custom User registration system
WP Query – grouping posts by same meta key, adding together values from another key
Figured out the SQL query that can be used to reset the display_name to first_name + last_name. And it’s simpler than the JOINs that I was trying when I posted the question. UPDATE wp_users SET display_name = Concat( (SELECT meta_value FROM wp_usermeta WHERE meta_key = ‘first_name’ AND user_id = id ), ‘ ‘, (SELECT meta_value … Read more
Removing Malware
Creating multiple tables with Plugin
both answers were great and helped me a lot ,i used the following to get to wp-config file without really Knowing all database details require_once(‘../wp-config.php’); include_once (‘../wp-load.php’); $con = mysqli_connect(DB_HOST, DB_USER, DB_PASSWORD , DB_NAME);
Sql query to get all metadata for a post
How delete post_content records of specific category from phpmyadmin
if you are trying to query from the same database in which your WordPress is installed then there is a great way to do sql query with ease. WordPress has a database access abstraction class called wpdb that allows you to run raw mysql query without any issue. You can start using it like one … Read more