Open flyrainaddy opened 9 years ago
Link to website?
I'm getting the same issue. I removed sensitive information with dashes (---). This is hosted with IIS7 using URLRedirect to support permalinks.
stack "SyntaxError: Invalid character\n at m.parseJSON (http://--------/wp-admin/load-scripts.php?c=1&load%5B%5D=jquery-core,jquery-migrate,utils&ver=4.2.2:4:15934)\n at e.parseJSON (http://--------/wp-admin/load-scripts.php?c=1&load%5B%5D=jquery-core,jquery-migrate,utils&ver=4.2.2:8:2922)\n at Pc (http://--------/wp-admin/load-scripts.php?c=1&load%5B%5D=jquery-core,jquery-migrate,utils&ver=4.2.2:4:18327)\n at x (http://--------/wp-admin/load-scripts.php?c=1&load%5B%5D=jquery-core,jquery-migrate,utils&ver=4.2.2:4:21741)\n at b (http://--------/wp-admin/load-scripts.php?c=1&load%5B%5D=jquery-core,jquery-migrate,utils&ver=4.2.2:4:25980)"
responseText "<head><title>Document Moved</title></head>\n<body><h1>Object Moved</h1>This document may be found <a HREF=\"http://--------------------------/wp-json/ccf/forms/59\">here</a></body>{\"ID\":59,\"title\":\"Contact Us\",\"status\":\"publish\",\"type\":\"ccf_form\",\"author\":{\"ID\":4,\"username\":\"----------\",\"name\":\"---------- Johnson\",\"first_name\":\"----------\",\"last_name\":\"Johnson\",\"nickname\":\"----------\",\"slug\":\"----------\",\"URL\":\"\",\"avatar\":\"http:\\/\\/1.gravatar.com\\/avatar\\/13d0c62b54641ef74dd34b950a9b8113?s=96\",\"description\":\"\",\"registered\":\"2015-07-01T18:59:25+00:00\",\"meta\":{\"links\":{\"self\":\"http:\\/\\/--------------------------\\/wp-json\\/users\\/4\",\"archives\":\"http:\\/\\/--------------------------\\/wp-json\\/users\\/4\\/posts\"}}},\"content\":\"\",\"parent\":null,\"link\":\"http:\\/\\/--------------------------\\/?post_type=ccf_form&p=59\",\"date\":\"2015-07-08T10:45:15\",\"modified\":\"2015-07-08T16:23:00\",\"format\":\"standard\",\"slug\":\"59\",\"guid\":\"http:\\/\\/--------------------------\\/?post_type=ccf_form&p=59\",\"excerpt\":null,\"menu_order\":0,\"comment_status\":\"open\",\"ping_status\":\"open\",\"sticky\":false,\"date_tz\":\"Etc\\/GMT-8\",\"date_gmt\":\"2015-07-08T18:45:15\",\"modified_tz\":\"Etc\\/GMT-8\",\"modified_gmt\":\"2015-07-09T00:23:00\",\"password\":\"\",\"meta\":{\"links\":{\"self\":\"http:\\/\\/--------------------------\\/wp-json\\/posts\\/59\",\"author\":\"http:\\/\\/--------------------------\\/wp-json\\/users\\/4\",\"collection\":\"http:\\/\\/--------------------------\\/wp-json\\/posts\",\"replies\":\"http:\\/\\/--------------------------\\/wp-json\\/posts\\/59\\/comments\",\"version-history\":\"http:\\/\\/--------------------------\\/wp-json\\/posts\\/59\\/revisions\"}},\"fields\":[{\"ID\":60,\"type\":\"single-line-text\",\"slug\":\"name\",\"placeholder\":\"\",\"className\":\"\",\"label\":\"Name\",\"description\":\"\",\"value\":\"\",\"required\":true},{\"ID\":61,\"type\":\"email\",\"slug\":\"email\",\"placeholder\":\"\",\"className\":\"\",\"label\":\"Email\",\"description\":\"\",\"value\":\"\",\"required\":true,\"emailConfirmation\":false},{\"ID\":62,\"type\":\"paragraph-text\",\"slug\":\"comments\",\"placeholder\":\"\",\"className\":\"\",\"label\":\"Comments\",\"description\":\"\",\"value\":\"\",\"required\":true}],\"buttonText\":\"Submit Form\",\"description\":\"\",\"completionActionType\":\"text\",\"completionRedirectUrl\":\"\",\"completionMessage\":\"\",\"sendEmailNotifications\":false,\"pause\":false,\"pauseMessage\":\"This form is paused right now. Check back later!\",\"emailNotificationAddresses\":\"----------\",\"emailNotificationFromType\":\"default\",\"emailNotificationFromAddress\":\"\",\"emailNotificationFromField\":\"email\",\"emailNotificationFromNameType\":\"custom\",\"emailNotificationFromName\":\"WordPress\",\"emailNotificationFromNameField\":\"You have no name fields\",\"submissions\":\"0\",\"terms\":[]}"
I'm experiencing the same issue. I found that deactivating Rest API https://wordpress.org/plugins/json-rest-api/ resolved the issue.
When the Rest API is active, new forms can't be saved and an error dialog appears (see attached). Further, the Form Title field in Form Settings displays [object Object]
(see attached).
The following error is in the log:
Undefined offset: 0 in /Users/pea/Sites/wordpress-dev/wp-content/plugins/custom-contact-forms/vendor/wp-api/wp-api/lib/class-wp-json-server.php on line 376
Type: PHP Notice
Line: 376
File: /Users/pea/Sites/wordpress-dev/wp-content/plugins/custom-contact-forms/vendor/wp-api/wp-api/lib/class-wp-json-server.php
Looking into this further, it seems the RestAPI (older version) is included in the plugin. Is there some way to disable that so that the RestAPI plugin can be activated independently and/or the error can be fixed?
For me, the RestAPI is critical, so I can't use this plugin until the apparent incompatibility is resolved.
@misfist which version of the REST API are you using?
@y2k4life seems like you have a permalinks issue.
I'm using WP REST API v2 (2.0-beta5).
I can not save forms,even I deactivating all other plugins and activating the Twenty Fifteen theme. the message is Custom Contact Forms is experiencing issues. There is an issue with synchronizing data. Please try deactivating all other plugins and activating the TwentyFifteen theme. If this fixes the problem, you have a plugin or theme conflict. If it does not, please post in the support forums or Github.