aaron13100 / 404solution Goto Github PK
View Code? Open in Web Editor NEW404 Solution
Home Page: https://ajexperience.com/wealthpsychology/404-solution/
404 Solution
Home Page: https://ajexperience.com/wealthpsychology/404-solution/
From @raglannyc on September 1, 2016 2:53
It would be great if custom post types were selectable in the Redirect to:
dropdown menu.
I set out to add this feature myself, and it seems to be working, albeit with minimal testing. For the code below, I copied the way regular posts are displayed in admin.php
lines 1709–21, and adapted that to loop through all custom post types.
There are a lot of settings for custom posts regarding hierarchy, search-ability, etc. that I don't know anything about and didn't take into account here.
I added this to admin.php
within the function wbz404_adminRedirectsPage
at line 1775 (sorry for lack of line-breaks, dunno how to get them in here):
$custompostargs = array( 'public' => true, '_builtin' => false ); $custompost_types = get_post_types( $custompostargs, 'objects', 'and' ); foreach ( $custompost_types as $custompost_type ) { $custompost_type_name = $custompost_type->name; $custompost_type_label = $custompost_type->labels->singular_name; $query = "select id from $wpdb->posts where post_status='publish' and post_type='$custompost_type_name' order by post_date desc"; $rows = $wpdb->get_results( $query ); foreach ( $rows as $row ) { $id = $row->id; $theTitle = get_the_title( $id ); $thisval = $id . "|POST"; $selected = ""; if ( isset( $_POST['dest'] ) && $_POST['dest'] == $thisval ) { $selected = " selected"; } echo "<option value=\"" . esc_attr( $thisval ) . "\"" . $selected . ">" . __( $custompost_type_label, '404-redirected' ) . ": " . esc_html( $theTitle ) . "</option>"; } }
And I added this slightly modified version to the function wbz404_adminEditPage
on what is now line 2125. The differences are: using WBZ404_POST
in place of POST
, using a different if
statement for setting the $selected
variable, and using esc_html
on $theTitle
. I didn't decide on those differences, that's how the code differs for retrieving regular WP posts in each of the two functions.
$custompostargs = array( 'public' => true, '_builtin' => false ); $custompost_types = get_post_types( $custompostargs, 'objects', 'and' ); foreach ( $custompost_types as $custompost_type ) { $custompost_type_name = $custompost_type->name; $custompost_type_label = $custompost_type->labels->singular_name; $query = "select id from $wpdb->posts where post_status='publish' and post_type='$custompost_type_name' order by post_date desc"; $rows = $wpdb->get_results( $query ); foreach ( $rows as $row ) { $id = $row->id; $theTitle = get_the_title( $id ); $thisval = $id . "|" . WBZ404_POST; $selected = ""; if ( $redirect['type'] == WBZ404_POST && $redirect['final_dest'] == $id ) { $selected = " selected"; } echo "<option value=\"" . esc_attr( $thisval ) . "\"" . $selected . ">" . __( $custompost_type_label, '404-redirected' ) . ": " . esc_html( $theTitle ) . "</option>"; } }
Think this could be used? I'm happy to help test it in more depth.
_Copied from original issue: ThemeMix/redirectioner
Hi,
when I check my site with GTmetrix I gor 3 different header entries with "seite-nicht-verfügbar":
https://gtmetrix.com/reports/one-million-places.com/s3mfRjir/
cache-control | no-cache, must-revalidate, max-age=0
content-encoding | br
content-length | 174
content-security-policy | upgrade-insecure-requests
content-type | text/html; charset=UTF-8
date | Sat, 27 Feb 2021 17:15:51 GMT
expect-ct | max-age=7776000, enforce
expires | Wed, 11 Jan 1984 05:00:00 GMT
location | https://one-million-places.com/seite-nicht-verfuegbar
referrer-policy | no-referrer-when-downgrade
server | LiteSpeed
set-cookie | abj404_solution_REQUEST_URI=%2Fimages%2Flogo%2Flogo.png; expires=Sat, 27-Feb-2021 17:19:51 GMT; Max-Age=240; path=/; secure
set-cookie | abj404_solution_REQUEST_URI_SHORT=%2Fimages%2Flogo%2Flogo.png; expires=Sat, 27-Feb-2021 17:15:56 GMT; Max-Age=5; path=/; secure
status | 301
strict-transport-security | max-age=63072000; includeSubDomains; preload
vary | Accept-Encoding,User-Agent,Accept-Encoding
x-content-type-options | nosniff
x-redirect-by | 404-solution/404-solution.php
x-xss-protection | 1; mode=block
Is this a bug? I can´t find any problems on the post. What´s the problem here?
Michael
From @adhorrig on June 20, 2016 9:18
What I Expected To Happen
I expected the Timber Pagination to work as normal - as it does when 404-Redirected is not activated.
What Happened Instead
404-Redirect does not acknowledge the pagination but instead redirects me back to the initial page. I.e. if I am on 'http://localhost:8888/cd-wordpress/news/' and click 'Next' at the end of the list of posts, I'm redirected to 'http://localhost:8888/cd-wordpress/news/' - the same page. I expect to be redirected to 'http://localhost:8888/cd-wordpress/news/page/2'.
Steps to Reproduce the Bug
Activate Timber and set up Pagination i.e. - functions.php:
global $paged;
if (!isset($paged) || !$paged){
$paged = 1;
}
$args = array(
'posts_per_page' => 10,
'paged' => $paged
);
query_posts($args);
$context['posts'] = Timber::get_posts();
$context['pagination'] = Timber::get_pagination();
And then HTML:
{% for post in posts %}
<li class="article-pagination">
{% if post.link %}
<img src="{{post.thumbnail.src}}"/>
<a href="{{post.link}}" class="{{post.class}}">{{post.title}}</a>
</li>
{% endfor %}
</ul>
{% if pagination.prev %}
<a href="{{pagination.prev.link}}" class="prev {{pagination.prev.link|length ? '' : 'invisible'}}"><button class="btn btn-default">Previous</button></a>
{% endif %}
{% if pagination.next %}
<a href="{{pagination.next.link}}" class="next {{pagination.next.link|length ? '' : 'invisible'}}"> <button class="btn btn-default">Next</button></a>
{% endif %}
Test out the pagination, then activate 404-Redirected and try again. You should experience what I describe above.
_Copied from original issue: ThemeMix/redirectioner number eleven
Hi Aaron
404 Solution Version 2.28.1
WordPress: 6.0
PHP: 7.4.30
PHP time limit and max input time = 120
PHP Memory limit = 768M
Hosting: Siteground shared
Active plugins:
404 Solution | Versione 2.28.1 di Aaron J
Complianz | GDPR/CCPA Cookie Consent | Versione 6.2.4 di Really Simple Plugins
GA Google Analytics | Versione 20220517 di Jeff Starr
Oxygen | Versione 4.0.1 di Soflyy
Wordfence Security | Versione 7.5.11 di Wordfence
WP Mautic | Versione 2.4.2 di Mautic community
Yoast SEO | Versione 19.2 di Team Yoast
Log size is limited by config parameter
As you can see from the attached image taken in WordPress->Settings->404 Solution->Options
The Maximum log disk usage was (is?) set to MB 100 but the current size is 242 MB (and 731.577 records) as reported in the following line in Options page.
If I check directly in the MySQL Database, I get the same values
I think because of this big log table, may be also limited by the shared hosting constraints, 404 solution doesn't work properly:
Question:
Can you suggest me the SQL Command to delete most of the 404 entries in the right way?
I would say something like:
DELETE FROM abj404_logsv2 WHERE timestamp < '2022-06-01'
but I do not know if I should first delete related records in other tables, like abj404_redirects
Don't know. May be leave 404 Solution unmanaged for 2 year like I did
I have the page
/en-au/ltux-v2/Example-data
when I open an url that is almost the same
/en-au/ltux-v2/Example-dat (missing "e" at the end)
It is detected in the interface as a 404 (such a smooth and efficient interface - love it), but I was of the impression that the 404solution plugin would auto correct this by finding the best valid path and forward, as I got this setting on:
Is this a bug, or did I misunderstand how it is meant to flow? Could it be affected because I got a multisite wordpress configuration?
Info
Two-part issue here.
I have a redirect for /demo-page
which does not work when someone goes to /demo-page/
with the /
at the end. Is that intended behavior? Doesn't make sense to me.
I have twice created a second redirect for /demo-page/
and twice it has disappeared from my list of redirects and the redirect stopped working. I do not know what is making it disappear. I created it for a third time just now, tested it, it worked, and it's still in the list of redirects.
From @raglannyc on September 1, 2016 2:53
It would be great if custom post types were selectable in the Redirect to: dropdown menu.
I set out to add this feature myself, and it seems to be working, albeit with minimal testing. For the code below, I copied the way regular posts are displayed in admin.php lines 1709–21, and adapted that to loop through all custom post types.
There are a lot of settings for custom posts regarding hierarchy, search-ability, etc. that I don't know anything about and didn't take into account here.
I added this to admin.php within the function wbz404_adminRedirectsPage at line 1775 (sorry for lack of line-breaks, dunno how to get them in here):
$custompostargs = array( 'public' => true, '_builtin' => false ); $custompost_types = get_post_types( $custompostargs, 'objects', 'and' ); foreach ( $custompost_types as $custompost_type ) { $custompost_type_name = $custompost_type->name; $custompost_type_label = $custompost_type->labels->singular_name; $query = "select id from $wpdb->posts where post_status='publish' and post_type='$custompost_type_name' order by post_date desc"; $rows = $wpdb->get_results( $query ); foreach ( $rows as $row ) { $id = $row->id; $theTitle = get_the_title( $id ); $thisval = $id . "|POST"; $selected = ""; if ( isset( $_POST['dest'] ) && $_POST['dest'] == $thisval ) { $selected = " selected"; } echo "<option value=\"" . esc_attr( $thisval ) . "\"" . $selected . ">" . __( $custompost_type_label, '404-redirected' ) . ": " . esc_html( $theTitle ) . "</option>"; } }
And I added this slightly modified version to the function wbz404_adminEditPage on what is now line 2125. The differences are: using WBZ404_POST in place of POST, using a different if statement for setting the $selected variable, and using esc_html on $theTitle. I didn't decide on those differences, that's how the code differs for retrieving regular WP posts in each of the two functions.
$custompostargs = array( 'public' => true, '_builtin' => false ); $custompost_types = get_post_types( $custompostargs, 'objects', 'and' ); foreach ( $custompost_types as $custompost_type ) { $custompost_type_name = $custompost_type->name; $custompost_type_label = $custompost_type->labels->singular_name; $query = "select id from $wpdb->posts where post_status='publish' and post_type='$custompost_type_name' order by post_date desc"; $rows = $wpdb->get_results( $query ); foreach ( $rows as $row ) { $id = $row->id; $theTitle = get_the_title( $id ); $thisval = $id . "|" . WBZ404_POST; $selected = ""; if ( $redirect['type'] == WBZ404_POST && $redirect['final_dest'] == $id ) { $selected = " selected"; } echo "<option value=\"" . esc_attr( $thisval ) . "\"" . $selected . ">" . __( $custompost_type_label, '404-redirected' ) . ": " . esc_html( $theTitle ) . "</option>"; } }
Think this could be used? I'm happy to help test it in more depth.
_Copied from original issue: ThemeMix/redirectioner number nineteen
Redirects should persist even when the site changes its URL.
The redirects no longer work.
The captured 404 captured the original subdirectory and has to be manually updated in order to become functional again.
The plugin should store redirects without the site's subdirectory.
No error, wp-cli cron should run without any error
Fatal error: Uncaught Error: Call to a member function getOptions() on null in /home/..../wp-content/plugins/404-solution/includes/DataAccess.php:808
Run wp cron event run --due-now
Stack Trace
Fatal error: Uncaught Error: Call to a member function getOptions() on null in /home/.../wp-content/plugins/404-solution/includes/DataAccess.php:808 Stack trace: #0 /home/.../wp-includes/class-wp-hook.php(286): ABJ_404_Solution_DataAccess::deleteOldRedirectsCron() #1 /home/.../wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters('', Array) #2 /home/.../wp-includes/plugin.php(531): WP_Hook->do_action(Array) #3 phar:///usr/local/bin/wp/vendor/wp-cli/cron-command/src/Cron_Event_Command.php(288): do_action_ref_array('abj404_cleanupC...', Array) #4 phar:///usr/local/bin/wp/vendor/wp-cli/cron-command/src/Cron_Event_Command.php(259): Cron_Event_Command::run_event(Object(stdClass)) #5 [internal function]: Cron_Event_Command->run(Array, Array) #6 phar:///usr/local/bin/wp/vendor/wp-cli/wp-cli/php/WP_CLI/Dispatcher/CommandFactory.php(93): call_user_func(Array, Array, Array) #7 [internal function]: WP_CLI\Dispatcher\CommandFactory::WP_CLI\Dispatcher in /home/.../wp-content/plugins/404-solution/includes/DataAccess.php on line 808 ABJ404-SOLUTION Fatal error handler: {"type":1,"message":"Uncaught Error: Call to a member function getOptions() on null in /home/.../wp-content/plugins/404-solution/includes/DataAccess.php:808 Stack trace: #0 /home/.../wp-includes/class-wp-hook.php(286): ABJ_404_Solution_DataAccess::deleteOldRedirectsCron() #1 /home/.../wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters('', Array) #2 /home/.../wp-includes/plugin.php(531): WP_Hook->do_action(Array) #3 phar:///usr/local/bin/wp/vendor/wp-cli/cron-command/src/Cron_Event_Command.php(288): do_action_ref_array('abj404_cleanupC...', Array) #4 phar:///usr/local/bin/wp/vendor/wp-cli/cron-command/src/Cron_Event_Command.php(259): Cron_Event_Command::run_event(Object(stdClass)) #5 [internal function]: Cron_Event_Command->run(Array, Array) #6 phar:///usr/local/bin/wp/vendor/wp-cli/wp-cli/php/WP_CLI/Dispatcher/CommandFactory.php(93): call_user_func(Array, Array, Array) #7 [internal function]: WP_CLI\Dispatcher\CommandFactory::WP_CLI\Dispatcher","file":"/home/.../wp-content/plugins/404-solution/includes/DataAccess.php","line":808}, Additional info: (none)
Plugin Activation doesn't work.
Plugin could not be activated because it triggered a fatal error.
Fatal error: Call to a member function errorMessage() on a non-object in /chroot/home/totalfoo/totalfood.com/html/wordpress/wp-content/plugins/404-solution/includes/ErrorHandler.php on line 36 Fatal error: Call to a member function errorMessage() on a non-object in /chroot/home/totalfoo/totalfood.com/html/wordpress/wp-content/plugins/404-solution/includes/ErrorHandler.php on line 69
(opened for @totalfood from issue #4)
I love 404 Solution more than other plugin making 301 redirects. I would like to transfer all redirects data from other plugin to 404 solution, but i can't find import button.
DB version: 2.32.2, PHP: 8.2.8, WordPress: 6.2.2, MySQL: 5.7.27, WP Memory Limit: 40M, mbstring Extension: true, [2.32.2]
I exprected if there is export, there should be import too
Can't find import button
open "Tools" tab
From @fdeitelhoff on July 3, 2016 19:21
A new button in the "Captured 404 URLs" tab would be awesome that moves all captured 404 urls to the trash.
I have to select them manually one by one and moving them just in 25er batches. And this time I have 297 pages of captured urls to this is a huge time waste.
_Copied from original issue: ThemeMix/redirectioner
From @schlessera on November 9, 2016 18:57
Item counts in table pagination areas should use a localization function that can account for singular and plural translations. See: https://codex.wordpress.org/Function_Reference/_n
Item count just translates the word items
:
__( 'items', '404-redirected' )
Can be seen in source code.
Copied from original issue: ThemeMix/redirectioner#26
I am getting the following error while adding any redirect to an external site.
Error: Data not formatted properly.
Error: unable to add new redirect.
Plugin version: 2.23.8, PHP: 7.2.34, WordPress: 5.6.2, MySQL: 5.7.33, WP Memory Limit: 40M, mbstring Extension: true
From @schlessera on November 9, 2016 18:53
Admin notice in two lines
Add an URL that doesn't start with a /
.
Copied from original issue: ThemeMix/redirectioner#25
v2.29.0
WP Admin panel can be loaded
wp admin panel crashed
FYI, I updated Site Kit by Google to latest version (1.93.0) in wp admin panel and the wp admin panel cannot be loaded.
==================
File /public_html/edu/wp-content/plugins/404-solution/includes/WordPress_Connector.php 的第 104 行 發生錯誤 (error occurred at line 104) (Error Type: E_ERROR)。ErrorMessage: Uncaught TypeError: property_exists(): Argument #1 ($object_or_class) must be of type object|string, array given in /public_html/edu/wp-content/plugins/404-solution/includes/WordPress_Connector.php:104
Stack trace:
#0 /public_html/edu/wp-content/plugins/404-solution/includes/WordPress_Connector.php(104): property_exists(Array, 'slug')
#1 /public_html/edu/wp-includes/class-wp-hook.php(308): ABJ_404_Solution_WordPress_Connector::excludePluginsFromAutoUpdate(NULL, Array)
#2 /public_html/edu/wp-includes/plugin.php(205): WP_Hook->apply_filters(NULL, Array)
#3 /public_html/edu/wp-admin/includes/update.php(1088): apply_filters('auto_update_plu...', NULL, Array)
#4 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Util/Auto_Updates.php(105): wp_is_auto_update_forced_for_item('plugin', NULL, Array)
#5 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Util/Auto_Updates.php(54): Google\Site_Kit\Core\Util\Auto_Updates::sitekit_forced_autoupdates_status()
#6 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Authentication/Authentication.php(932): Google\Site_Kit\Core\Util\Auto_Updates::is_plugin_autoupdates_enabled()
#7 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Util/Method_Proxy_Trait.php(25): Google\Site_Kit\Core\Authentication\Authentication->inline_js_base_data(Array)
#8 /public_html/edu/wp-includes/class-wp-hook.php(308): Google\Site_Kit\Core\Authentication\Authentication->Google\Site_Kit\Core\Util{closure}(Array)
#9 /public_html/edu/wp-includes/plugin.php(205): WP_Hook->apply_filters(Array, Array)
#10 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php(721): apply_filters('googlesitekit_i...', Array)
#11 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php(356): Google\Site_Kit\Core\Assets\Assets->get_inline_base_data()
#12 [internal function]: Google\Site_Kit\Core\Assets\Assets->Google\Site_Kit\Core\Assets{closure}('googlesitekit-b...')
#13 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Assets/Script_Data.php(51): call_user_func(Object(Closure), 'googlesitekit-b...')
#14 [internal function]: Google\Site_Kit\Core\Assets\Script_Data->Google\Site_Kit\Core\Assets{closure}('googlesitekit-b...')
#15 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Assets/Asset.php(129): call_user_func(Object(Closure), 'googlesitekit-b...')
#16 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php(979): Google\Site_Kit\Core\Assets\Asset->before_print()
#17 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php(988): Google\Site_Kit\Core\Assets\Assets->run_before_print_callbacks(Object(WP_Scripts), Array)
#18 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php(988): Google\Site_Kit\Core\Assets\Assets->run_before_print_callbacks(Object(WP_Scripts), Array)
#19 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php(988): Google\Site_Kit\Core\Assets\Assets->run_before_print_callbacks(Object(WP_Scripts), Array)
#20 /public_html/edu/wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php(154): Google\Site_Kit\Core\Assets\Assets->run_before_print_callbacks(Object(WP_Scripts), Array)
#21 /public_html/edu/wp-includes/class-wp-hook.php(308): Google\Site_Kit\Core\Assets\Assets->Google\Site_Kit\Core\Assets{closure}('')
#22 /public_html/edu/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters('', Array)
#23 /public_html/edu/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#24 /public_html/edu/wp-admin/admin-header.php(146): do_action('admin_print_scr...')
#25 /public_html/edu/wp-admin/admin.php(239): require_once('/home2/takwing1...')
#26 {main}
thrown
I found that your plugin breaks my entire wordpress after an update.
On line 719 of SpellChecker.php - PLEASE remove " : int" on the function "getMaxAcceptableDistance"
I have disable auto updates on your plugin because of this.
Maybe this works on newer versions of PHP but not ~5.6
From @pbowyer on January 31, 2017 9:30
A site uses a CPT for events. Once the event is past they unpublish the CPT post, which every time creates a new 404 error.
Rather than create individual redirects, it would be great to create one regular expression rule for all matching 404's:
404s matching /events/.+ => /events/?finished=1
_Copied from original issue: ThemeMix/redirectioner
Add an option to delete logs older than X days to the tools page. This makes more sense than deleting based on redirect type.
Add an option on the options page to delete logs older than X days automatically.
From @RenewSurfaces on September 29, 2016 13:54
What I Expected To Happen
Enter an URL into URL box under "Add manual Redirect" the URL displays in the Page Redirects.
What Happened Instead
Enter an URL into URL box under "Add manual Redirect" the URL does not display in the Redirect.
Steps to Reproduce the Bug
Following instructions above, unfortunately i think the bug may be caused by the version of WordPress which i just check and is :- 4.5.4 I cannot currently update it as our theme has compatibility issues we're trying to get resolved currently.
Is there a workaround we can use temporarily?
_Copied from original issue: ThemeMix/redirectioner number twenty-two.
Redirect to the post with the closest matching name or slug.
An automatic redirect sent me to the wrong post.
The site should redirect to site.com/financial-consulting-product-2 but it does not because the automatic redirect was used.
This was found using version 2.1.0 with WooCommerce and changing the product status to and from "hidden."
2.23.3
That the plugin lets me change the site to which a user should be redirected after he enters a wrong url
Error Message: "Task failled successfully (:D)" shows up and the previous entered site is changed to "Standard 404-Site"
I just created some 301 redirects before that step and than wanted to change that setting
2.24.7
Your 404 solution plugin causing 1.5 minute loading delay on "Offers for WooCommerce" (plugin by www.angelleye.com) list-view when your plugin is active. As soon as i disable your 404 plugin, offers list view loads within 1 second. Pls fix.
Read "What I Expected To Happen".
Read "What I Expected To Happen".
Hi,
I have just updated the Error 404 plugin to version 2.2.14 on my wordpress site. When I click on the 404 solution menu item I see the page but with a lot of warnings;
Warning: strcmp() expects parameter 1 to be string, array given in /home/brazil16/public_html/wp-content/plugins/404-solution/includes/php/FunctionsMBString.php on line 13
And I can't see any of the redirects I have setup.
Plugin version: 2.21.4, PHP: 7.2.19, WordPress: 5.2.2, MySQL: 5.6.40, WP Memory Limit: 40M, mbstring Extension: true
From @totalfood on October 3, 2016 16:15
We were looking for an simpler way to do a '301 to Homepage' in the Captured 404 URLs tab.
Each Captured 404 URL has to be individually directed to Homepage
Add a '301 to Homepage' option to the "Mark As Ignored/Trash" Dropdown Menu in the Captured 404 URLs tab. Set "Homepage:" field in Options tab. This would save a LOT of time, especially if you have a lot of 404s! Thank you.
Copied from original issue: ThemeMix/redirectioner#23
When I install 404 Solution I want all of the existing 404 Redirected URLs to be carried over so I don't lose any of the existing redirects.
All of the redirects are lost.
Install 404 Solution.
Hey Aaron, plugin is working great so far on my work site, and I've installed on my other Wordpress sites to use as well.
One small issue I noticed is that both the Page Redirects and Captured 404 URLs are not recording hits like 404 Redirect used to. I would always use that data to focus on addressing the 404s that were getting a lot of hits.
Hope you can fix this in the next update as it's very helpful. Thanks!
I expect the plugin to activate.
Fatal error: Call to a member function readFileContents() on a non-object in /home/howthing/public_html/wp-content/plugins/404-solution/includes/DataAccess.php on line 54
ABJ404-SOLUTION Fatal error handler: {"type":1,"message":"Call to a member function readFileContents() on a non-object","file":"/home/howthing/public_html/wp-content/plugins/404-solution/includes/DataAccess.php","line":54}
I don't know.
Contents of: /home/customer/www/accessible-techcomm.org/public_html/wp-content/uploads/temp_abj404_solution/abj404_debug.txt:
2022-08-22 10:36:41 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:36:41 EDT (DEBUG): Displaying sub page: abj404_options
2022-08-22 10:42:06 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:42:06 EDT (DEBUG): Displaying sub page: abj404_options
2022-08-22 10:42:33 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:42:33 EDT (DEBUG): Displaying sub page: abj404_tools
2022-08-22 10:44:38 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:44:38 EDT (DEBUG): Displaying sub page: abj404_stats
2022-08-22 10:44:59 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:44:59 EDT (DEBUG): Displaying sub page: abj404_logs
2022-08-22 10:44:59 EDT (DEBUG): 500 log records displayed on the page.
2022-08-22 10:46:39 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:46:39 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:46:39 EDT (DEBUG): Found 39 rows to display before log data and 39 rows to display after log data for page: abj404_captured
2022-08-22 10:47:40 EDT (DEBUG): Processing request for action: bulktrash
2022-08-22 10:47:40 EDT (DEBUG): In doBulkAction. Action: bulktrash
2022-08-22 10:47:40 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:47:40 EDT (DEBUG): Found 35 rows to display before log data and 35 rows to display after log data for page: abj404_captured
2022-08-22 10:49:25 EDT (DEBUG): Processing request for action: bulktrash
2022-08-22 10:49:25 EDT (DEBUG): In doBulkAction. Action: bulktrash
2022-08-22 10:49:25 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:49:25 EDT (DEBUG): Found 29 rows to display before log data and 29 rows to display after log data for page: abj404_captured
2022-08-22 10:49:32 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:49:32 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:49:34 EDT (DEBUG): Found 500 rows to display before log data and 500 rows to display after log data for page: abj404_captured
2022-08-22 10:49:42 EDT (DEBUG): Processing request for action: emptyCapturedTrash
2022-08-22 10:49:42 EDT (DEBUG): doEmptyTrash deleted 2247 rows total. (abj404_captured)
2022-08-22 10:49:42 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:49:42 EDT (DEBUG): Found 0 rows to display before log data and 0 rows to display after log data for page: abj404_captured
2022-08-22 10:49:50 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:49:50 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:49:50 EDT (DEBUG): Found 29 rows to display before log data and 29 rows to display after log data for page: abj404_captured
2022-08-22 10:51:08 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:51:08 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:51:08 EDT (DEBUG): Found 29 rows to display before log data and 29 rows to display after log data for page: abj404_captured
2022-08-22 10:51:09 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:51:09 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:51:09 EDT (DEBUG): Found 29 rows to display before log data and 29 rows to display after log data for page: abj404_captured
2022-08-22 10:51:10 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:51:10 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:51:10 EDT (DEBUG): Found 29 rows to display before log data and 29 rows to display after log data for page: abj404_captured
2022-08-22 10:51:37 EDT (DEBUG): Processing request for action: bulktrash
2022-08-22 10:51:37 EDT (DEBUG): In doBulkAction. Action: bulktrash
2022-08-22 10:51:37 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:51:37 EDT (DEBUG): Found 28 rows to display before log data and 28 rows to display after log data for page: abj404_captured
2022-08-22 10:53:30 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:53:30 EDT (DEBUG): Displaying sub page: abj404_redirects
2022-08-22 10:53:30 EDT (DEBUG): Found 23 rows to display before log data and 23 rows to display after log data for page: abj404_redirects
2022-08-22 10:56:22 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:56:22 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:56:22 EDT (DEBUG): Found 28 rows to display before log data and 28 rows to display after log data for page: abj404_captured
2022-08-22 10:56:59 EDT (DEBUG): Processing request for action: (none)
2022-08-22 10:56:59 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:56:59 EDT (DEBUG): Found 1 rows to display before log data and 1 rows to display after log data for page: abj404_captured
2022-08-22 10:57:01 EDT (DEBUG): Processing request for action: emptyCapturedTrash
2022-08-22 10:57:01 EDT (DEBUG): doEmptyTrash deleted 1 rows total. (abj404_captured)
2022-08-22 10:57:02 EDT (DEBUG): Displaying sub page: abj404_captured
2022-08-22 10:57:02 EDT (DEBUG): Found 0 rows to display before log data and 0 rows to display after log data for page: abj404_captured
2022-08-22 12:49:42 EDT (DEBUG): ABJ_404_Solution_SpellChecker/savePostHandler: Ignored savePost change (uninteresting post statuses). Action: save, ID: 4983, statuses: (not found)/auto-draft, agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 OPR/90.0.4480.48
2022-08-22 12:50:05 EDT (DEBUG): ABJ_404_Solution_SpellChecker/savePostHandler: Ignored savePost change (uninteresting post types). Action: save, ID: 4984, types: (not found)/revision, agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 OPR/90.0.4480.48
2022-08-22 12:50:05 EDT (DEBUG): ABJ_404_Solution_SpellChecker/savePostHandler: Ignored savePost change (uninteresting post statuses). Action: save, ID: 4983, statuses: (not found)/draft, agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 OPR/90.0.4480.48
2022-08-22 12:50:10 EDT (DEBUG): ABJ_404_Solution_SpellChecker/savePostHandler: Ignored savePost change (uninteresting post statuses). Action: save, ID: 4983, statuses: (not found)/draft, agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 OPR/90.0.4480.48
2022-08-22 12:51:15 EDT (DEBUG): ABJ_404_Solution_SpellChecker/savePostHandler: Ignored savePost change (uninteresting post statuses). Action: save, ID: 4983, statuses: (not found)/draft, agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:103.0) Gecko/20100101 Firefox/103.0
2022-08-22 12:54:46 EDT (DEBUG): ABJ_404_Solution_SpellChecker/savePostHandler: Ignored savePost change (uninteresting post statuses). Action: save, ID: 4983, statuses: (not found)/trash, agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 OPR/90.0.4480.48
2022-08-22 12:54:58 EDT (DEBUG): ABJ_404_Solution_SpellChecker/savePostHandler: Ignored savePost change (uninteresting post types). Action: delete, ID: 4984, types: (not found)/revision, agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 OPR/90.0.4480.48
2022-08-22 12:54:58 EDT (DEBUG): ABJ_404_Solution_SpellChecker/savePostHandler: Ignored savePost change (uninteresting post statuses). Action: delete, ID: 4983, statuses: (not found)/trash, agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 OPR/90.0.4480.48
2022-08-22 14:57:27 EDT (DEBUG): Processing 404 for URL: /thomas | Redirect: {"id":0} | is_single(): | is_page(): | is_feed(): | is_trackback(): | is_preview(): | options: auto_redirects: 1, auto_score: 90, auto_cats: 1, auto_tags: 1, dest404page: 0|0, HTTP_USER_AGENT: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 OPR/90.0.4480.48, REMOTE_ADDR: 173.66.46.33rhvd208d7g, REQUEST_URI: /thomas
2022-08-22 14:57:27 EDT (DEBUG): No posts or pages matching slug: thomas
2022-08-22 14:57:27 EDT (DEBUG): Found 49 likely match IDs.
2022-08-22 14:57:27 EDT (DEBUG): Logging redirect. Referer: | Current user: webdiva | From: /thomas to: 404, Reason: gave up. , Ignore msg(s): , Execution time: 0.32 seconds, permalinks found: {"514|1":"85.7143","288|1":"77.7778","1094|1":"77.7778","37|1":"75.0000","33|1":"75.0000"}
2022-08-22 15:08:54 EDT (DEBUG): Processing 404 for URL: /thomas | Redirect: {"id":0} | is_single(): | is_page(): | is_feed(): | is_trackback(): | is_preview(): | options: auto_redirects: 1, auto_score: 90, auto_cats: 1, auto_tags: 1, dest404page: 0|0, HTTP_USER_AGENT: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:103.0) Gecko/20100101 Firefox/103.0, REMOTE_ADDR: 173.66.46.33rhvd208d7g, REQUEST_URI: /thomas
2022-08-22 15:08:54 EDT (DEBUG): No posts or pages matching slug: thomas
2022-08-22 15:08:54 EDT (DEBUG): Found 49 likely match IDs.
2022-08-22 15:08:54 EDT (DEBUG): Logging redirect. Referer: | Current user: webdiva | From: /thomas to: 404, Reason: gave up. , Ignore msg(s): , Execution time: 0.3 seconds, permalinks found: {"514|1":"85.7143","288|1":"77.7778","1094|1":"77.7778","37|1":"75.0000","33|1":"75.0000"}
2022-08-22 15:16:50 EDT (DEBUG): Processing 404 for URL: /thomas | Redirect: {"id":0} | is_single(): | is_page(): | is_feed(): | is_trackback(): | is_preview(): | options: auto_redirects: 1, auto_score: 90, auto_cats: 1, auto_tags: 1, dest404page: 0|0, HTTP_USER_AGENT: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 OPR/90.0.4480.48, REMOTE_ADDR: 173.66.46.33rhvd208d7g, REQUEST_URI: /thomas
2022-08-22 15:16:50 EDT (DEBUG): No posts or pages matching slug: thomas
2022-08-22 15:16:50 EDT (DEBUG): Found 49 likely match IDs.
2022-08-22 15:16:50 EDT (DEBUG): Logging redirect. Referer: | Current user: webdiva | From: /thomas to: 404, Reason: gave up. , Ignore msg(s): , Execution time: 0.3 seconds, permalinks found: {"514|1":"85.7143","288|1":"77.7778","1094|1":"77.7778","37|1":"75.0000","33|1":"75.0000"}
2022-08-22 15:27:17 EDT (DEBUG): Processing request for action: (none)
2022-08-22 15:27:17 EDT (DEBUG): No tab selected. Displaying the "redirects" tab.
2022-08-22 15:27:17 EDT (DEBUG): Displaying sub page: abj404_redirects
2022-08-22 15:27:17 EDT (DEBUG): Found 23 rows to display before log data and 23 rows to display after log data for page: abj404_redirects
2022-08-22 15:27:28 EDT (DEBUG): Processing request for action: (none)
2022-08-22 15:27:28 EDT (DEBUG): Displaying sub page: abj404_tools
2022-08-22 15:28:04 EDT (DEBUG): Processing request for action: (none)
2022-08-22 15:28:04 EDT (DEBUG): Displaying sub page: abj404_options
2022-08-22 15:46:14 EDT (DEBUG): Processing request for action: (none)
2022-08-22 15:46:14 EDT (DEBUG): Displaying sub page: abj404_options
2022-08-22 15:50:47 EDT (DEBUG): Processing request for action: (none)
2022-08-22 15:50:47 EDT (DEBUG): Displaying sub page: abj404_debugfile
Contents of: /home/customer/www/accessible-techcomm.org/public_html/wp-content/uploads/temp_abj404_solution/abj404_debug.txt_old.txt:
(The log file does not exist.)
From @grozzy on September 13, 2016 1:50
Hi there,
I have your great plugin across three sites. Over the past few months though, when I put in a redirection the destination post/page doesn't come up. Instead, I need to sort by view, find that redirection and insert the destination URL after which it then inserts it.
It would be awesome if you could fix this bug.
Copied from original issue: ThemeMix/redirectioner#21
The Empty Trash buttons on the Captured 404 URL's and the page Redirects pages do not work. It states that it has deleted all the items, but the items are still there, when you refresh the page.
From @RenewSurfaces on September 29, 2016 13:54
Enter an URL into URL box under "Add manual Redirect" the URL displays in the Page Redirects.
Enter an URL into URL box under "Add manual Redirect" the URL does not display in the Redirect.
Following instructions above, unfortunately i think the bug may be caused by the version of WordPress which i just check and is :- 4.5.4 I cannot currently update it as our theme has compatibility issues we're trying to get resolved currently.
Is there a workaround we can use temporarily?
_Copied from original issue: ThemeMix/redirectioner
From @adhorrig on June 20, 2016 9:18
I expected the Timber Pagination to work as normal - as it does when 404-Redirected is not activated.
404-Redirect does not acknowledge the pagination but instead redirects me back to the initial page. I.e. if I am on 'http://localhost:8888/cd-wordpress/news/' and click 'Next' at the end of the list of posts, I'm redirected to 'http://localhost:8888/cd-wordpress/news/' - the same page. I expect to be redirected to 'http://localhost:8888/cd-wordpress/news/page/2'.
Activate Timber and set up Pagination i.e. - functions.php:
global $paged;
if (!isset($paged) || !$paged){
$paged = 1;
}
$args = array(
'posts_per_page' => 10,
'paged' => $paged
);
query_posts($args);
$context['posts'] = Timber::get_posts();
$context['pagination'] = Timber::get_pagination();
And then HTML:
{% for post in posts %}
<li class="article-pagination">
{% if post.link %}
<img src="{{post.thumbnail.src}}"/>
<a href="{{post.link}}" class="{{post.class}}">{{post.title}}</a>
</li>
{% endfor %}
</ul>
{% if pagination.prev %}
<a href="{{pagination.prev.link}}" class="prev {{pagination.prev.link|length ? '' : 'invisible'}}"><button class="btn btn-default">Previous</button></a>
{% endif %}
{% if pagination.next %}
<a href="{{pagination.next.link}}" class="next {{pagination.next.link|length ? '' : 'invisible'}}"> <button class="btn btn-default">Next</button></a>
{% endif %}
Test out the pagination, then activate 404-Redirected and try again. You should experience what I describe above.
_Copied from original issue: ThemeMix/redirectioner
It's still showing in my logs
2017-12-07 07:44:42 (INFO): Updating database version from 2.5.2 to 2.5.3 (begin).
2017-12-07 07:44:42 (INFO): Updating database version to 2.5.3 (end).
From @pbowyer on January 31, 2017 9:30
Scenario
A site uses a CPT for events. Once the event is past they unpublish the CPT post, which every time creates a new 404 error.
Solution
Rather than create individual redirects, it would be great to create one regular expression rule for all matching 404's:
404s matching /events/.+ => /events/?finished=1
_Copied from original issue: ThemeMix/redirectioner number twenty nine.
Folks, I'm sorry for opening an issue, but I'm getting more and less desperate to get my job done.
Long story short, my site had a page and a bunch of subpages deleted. I (imagine to) need a regex like the below to just display the default 404 page:
/my-deleted-page/.+
However, 404 Solution sometimes captures the missing pages and redirects them to posts, what's not what I need.
I don't have a custom 404 page, and I don't want to create one, for reasons beyond my own will.
What am I missing?
Thank you very much, any help very appreciated!
Being a typical user, I expected 404 captured URLs to be deleted when doublechecked for deletion in tools, instead of move to trashcan.
So, I ended up with a huge trashcan (almost 100000 lines). Just imagine that when trying to enter into it to search for a way to empty it, the server timeouts and I get a beautiful "503 unavailable"
It would be a tremendous help, to add a button to empty the trashcan for cases like mine, when entering the trashcan is not possible.
Thank you in advance for considering this, and thank you for an excellent plugin!!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.