bulk delete wordpress media Images from database
go to phpmyadmin and locate your database run sql query below by click sql paste this code one by one.
-
# First:
-
DELETE FROM wp_postmeta
-
WHERE post_id IN
-
(
-
SELECT id
-
FROM wp_posts
-
WHERE post_type = ‘attachment’
-
)
-
;
-
# Second:
-
DELETE FROM wp_posts WHERE post_type = ‘attachment’
How to delete only Unattached wordpress mediafiles?
Really I don’t Know How to identify Unattached and attached media.
These Media attachments are like post or pages. so
How i deleted unattached media files in from wordpress database?
-
DELETE FROM wp_posts WHERE post_type = ‘attachment’
How to bulk delete posts,pages, tags in wordpress?
delete post meta data from database which is unused?
simply run this query
below this will delete unused post meta data from wordpress database thorough phpmyadmin.
DELETE pm
FROM wp_postmeta pm
LEFT JOIN wp_posts wp ON wp.ID = pm.post_id
WHERE wp.ID IS NULL;
Delete All tags in wordpress
Also look at wordpress duplicate content
Ask a Question:
You must be logged in to post a comment.