Permalink Finder Plugin sanitize_url is deprecated
Permalink finder word-press plugin by Keith Graham is one of my favorite word-press plugin. It helps me in redirecting some of my old links in some forums to my new posts or pages.
This plugin has not been updated for last two years. Recently it started showing following error on 404 pages
“Notice: sanitize_url is deprecated since version 2.8! Use esc_url_raw() instead. in /wp-includes/functions.php on line 34”
Till the plugin gets updated, here is the solution to remove the error “sanitize_url is deprecated”
Open the file “/wp-content/plugins/permalink-finder/includes/pf-404.php” for editing. My favorite editors are Genie in Linux and Notepad ++ in Windows
Open the file in your favourite editor, search for ‘ $flink=sanitize_url($flink); ‘ It will be on line 385. Replace it with ‘ $flink=esc_url_raw($flink); ‘
Check the site with some random characters for forcing 404 page.
This plugin is no more maintained. last update was 4 years ago, as of now I am using the plugin ” WP 404 Auto Redirect to Similar Post ” for last few days. The plugin works perfectly out of box, no configuration is required.