Hi, I've a no-wordpress website in the root of my domain and a WordPress install inside /present/ directory. The page mydomain.com/1788/ exists on the website, but it doesn't exists under wordpress (/present/1788/). I created a new Custom post type, If I give it the slug /1788/ and Blocks is active I get this error message:
Fatal error: Uncaught InvalidArgumentException in /var/www/html/mjchs/present/wp-content/plugins/de-toolset-blocks/vendor/toolset/toolset-common/inc/autoloaded/post_type/from_types.php:345 Stack trace:
#0 /var/www/html/mjchs/present/wp-content/plugins/de-toolset-blocks/vendor/toolset/toolset-common/inc/autoloaded/post_type/repository.php(131): Toolset_Post_Type_From_Types->set_registered_post_type()
#1 /var/www/html/mjchs/present/wp-includes/class-wp-hook.php(287): Toolset_Post_Type_Repository->finish_loading_registered_post_types()
#2 /var/www/html/mjchs/present/wp-includes/class-wp-hook.php(311): WP_Hook->apply_filters()
#3 /var/www/html/mjchs/present/wp-includes/plugin.php(484): WP_Hook->do_action()
#4 /var/www/html/mjchs/present/wp-settings.php(557): do_action()
#5 /var/www/html/mjchs/present/wp-config.php(90): require_once('/var/www/html/m...')
#6 /var/www/html/mjchs/present/wp-load.php(37): require_once('/var/www/html/m...')
#7 /var/www/html/mjchs/present/wp-admin/admin.php(34): require_once('/var/www/html/m...')
#8 in /var/www/html/mjchs/present/wp-content/plugins/de-toolset-blocks/vendor/toolset/toolset-common/inc/autoloaded/post_type/from_types.php on line 345
If I deactivate Blocks it works, if use a different slug with Blocks it works fine. I tried cleaning the DB with WP Sweep to remove orphans items. I also searched '1788' with Better Search Replace plugin and I didn't find anything.
Can you help me?
Hello, thanks for the report. I'm able to see the same issue if I create a CPT in my local site using any numeric slug, regardless of having a non-WP site in the same domain. Let me ask my 2nd tier support team to take a look. It seems that we should either support numeric slugs in Blocks or prevent creating CPTs with numeric slugs in Types. Until I get some feedback, you might be able to work around this temporarily by using a slug that begins with a text character like "temp1788" instead. If the CPT is created with Types, you can edit the CPT in Toolset > Post Types and use the Rewrite option "Custom URL Format" to change the URL slug to 1788 (screenshot). Then the CPT URLs will include .../1788/... instead of .../temp1788/..., and Blocks will not throw a Fatal Error. I'll let you know what I find out from 2nd tier support.
Quick update- my 2nd tier team has escalated this issue to the developers and we're waiting for feedback. I'll keep you posted here.
This issue will be resolved in the next release of Views/Blocks. I'll keep you posted as I receive information about that release schedule.
Unfortunately there was a miscommunication among the team, and this issue was not resolved in today's hotfix release. The team has pushed this issue into the following release, and I'll keep you updated on the schedule here.
Hello, our team is now in the process of pushing out the latest Toolset release. If you have not yet been prompted to update to the latest versions, you may need to go to wp-admin > Plugins > Add New, then click the Commercial tab. In the Toolset Installer panel, click "Check for Updates", and the automatic installer should find the latest versions of Toolset plugins ready to install. The fix for this issue is included in the latest updates. Thanks for your patience while we worked to resolve this issue. Feel free to close here or let me know if the issue is not fully resolved.