Tell us what you are trying to do?
Create a view for a custom post type
Is there any documentation that you are following?
https://toolset.com/2019/06/visually-create-and-design-views-using-block-editor/
Is there a similar example that we can see?
Not on the front end. The problem starts with adding a view widget to a block. A warning about "no correct JSON format" appears. I have no idea where or what to change.
What is the link to your site?
hidden link
The server meets toolset needs, explicitly checked that with their team.
Please tell me what further information you need?
Hi,
Thank you for contacting us and I'd be happy to assist.
The warning suggests that something is interfering with the normal processing of the blocks editor.
To troubleshoot this, I'll suggest the following steps:
1. Please make sure that WordPress, active theme and plugins are all updated to the latest versions.
2. It would be interesting to test this with all non-Toolset plugins disabled and a default theme like Twenty Twenty-One.
If it's fixed, you can start adding the disabled items, one-by-one, to narrow down to a possible conflicting one.
3. In case the issue still persists, I'll need to see how this View block is being used in the admin area and you can share temporary admin login details in reply to this message.
Note: Your next reply will be private please make a complete backup copy, before sharing the access details.
regards,
Waqar
Thank you for sharing the access details, but I keep getting the incorrect password message.
Can you please check the username and password again and make sure that this user has the "administrator" role?
I've set your next reply as private again.
The access details worked, thank you.
I can see the issue on your website, while creating a new view, using the blocks based editor.
While troubleshooting earlier, did you also checked with Cloudflare disabled?
If you've already checked that, I'll need your permission to download a clone/snapshot of your website, to investigate this on a different server.
( ref: https://toolset.com/faq/provide-supporters-copy-site/ )
Hi Waqar,
yes, I disabled CF with non-toolset plugins off and 2021 theme on. No changes.
So yes, paid version of Updraft is there, just create a site key on your server using Updraft and then log in to my site -> Updraft -> clone/migrate -> send a backup and enter the site key for save transmission.
Regards,
Sven
Thank you for the permission and I was able to deploy your website's clone on my server.
I'm currently running some tests on it and will share my findings, as soon as this testing completes.
Thank you for your patience.
Hi Sven,
Just wanted to let you know that, I'm still investigating this view creation issue and will be able to share an update, in a couple of hours.
regards,
Waqar
Thank you for waiting.
During troubleshooting, I was able to narrow down this issue, to the following line of code in the website's "wp-config.php" file:
define( 'WP_REST_API', true );
The quote characters used around the "WP_REST_API" are not correct and it should be changed to:
define( 'WP_REST_API', true );
This screenshot will make the difference more clear:
hidden link
Once this line is fixed, the error "The response is not a valid JSON response." will be fixed.
Wrong quotation marks confirmed and fixed.
But no effect. Started a new template and got same error again.
-> Re-checked the config file, can confirm that changes have been saved to correct quotation marks.
-> plugins off exept for Toolset. Added single field 'Karteikopf' in block editor, no styling, no additional text, just the naked field. On updating I received the same "JSON" error message as before
So from my perspective there must be something else. If you need additional info about server or cloudflare, plz let me know.
Thanks for the update.
I'm now seeing a different error on your website, which is not seen on your website's clone on my server.
Screenshot: hidden link
Something on your server is blocking the WordPress REST API endpoint for the user information (and could be blocking other endpoints too) which results in 403 forbidden errors.
( similar report of this error at WordPress forum: https://wordpress.org/support/topic/wp-rest-api-users-endpoint-returns-403-error/ )
I'll recommend testing this with Cloudflare disabled again, to see if it is related to Cloudflare or the server. You can then get in touch with the support team of the Cloudflare or the server, accordingly.
Hi Waqar,
that is actually a MiniOrange 2FA plugin feature to prevent 3rd party from requesting user info via the REST API. It has been installed about 6:00 pm GMT+1 today thus it's rather not the cause of the prior issue.
If you watched it earlier than 6:00 pm GMT please leave me feedback.
If that MiniOrange feature generally might be a new issue for Toolset Views I can switch that feature off easily via the plugin settings.
At the moment I still feel it's something different.
Earlier, the cause of the error "The response is not a valid JSON response." was different (wrong quotation marks).
Now, it is being shown for a different reason, as suggested in my last reply.
Did you get a chance to test this with the "MiniOrange 2FA" plugin disabled?
Actually no, as MiniOrange caused several new issues. I love that with their 198 bucks premium account ... NOT. I suggest you close this ticket and as soon as the urgently needed 2FA works as it should, I'll test Views again and in case, I'll open a new ticket. Thank you so far for your assistance. Greatly appreciated.
You're very welcome and I'm going to mark this ticket as resolved.
Please feel free to share your test results with us, in case the issue still persists.
( you can include this ticket's link so that we can connect the background info )