Would it be possible to build a mysql query to determine the frequency of an image being used in WordPress?
So that it extracts and counts different image hrefs from the wp_posts?
Would it be possible to build a mysql query to determine the frequency of an image being used in WordPress?
So that it extracts and counts different image hrefs from the wp_posts?
2
Answers
thanks for tour quick response. sorry i forgot it makes much more sense to use php:
This query will first select all of the posts in the wp_posts table where the post content contains the [image_href] shortcode. The shortcode is used to insert an image into a WordPress post. The query will then count the number of times each image href is used in the post content. Finally, the query will order the results by the image count in descending order.
To run this query, you will need to connect to your MySQL database and execute the query. You can use a MySQL client such as MySQL Workbench or phpMyAdmin to execute the query.