bug: replace incorrect many posts
-
I found bug about posts update.
Moving files O.K.Thre are short name files in my site.
Ex.) 1.jpg, 2.pngThis plugin updates content of posts by MySQL replace function.
From $search_url to $replace_url php vars.
But $search_url and $replace_url was removed file extension.
So many posts match, then replace.I tried this:
... class OrganizeMediaLibrary { ... function regist($re_id_attache, $target_folder, $character_code){ ... $search_url = str_replace('.'.$ext, '', $url_attach); $replace_url = str_replace('.'.$ext, '', $new_url_attach); // ↓modify $search_url = $url_attach; $replace_url = $new_url_attach; ...
I think its O.K.
Is there any reason for remove file extension?
Thanks.
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘bug: replace incorrect many posts’ is closed to new replies.