Title: json_encode and Really Simple SSL problem
Last modified: August 31, 2016

---

# json_encode and Really Simple SSL problem

 *  Resolved [wmerussi](https://wordpress.org/support/users/wmerussi/)
 * (@wmerussi)
 * [10 years ago](https://wordpress.org/support/topic/json_encode-and-really-simple-ssl-problem/)
 * I have this plugin installed in my WordPress.org website and when I run the json_encode()
   it appends `<!-- Really Simple SSL mixed content fixer active -->` on the result,
   so my ajax call returns error because of the `<` of the beggining of the appended
   comment.
 * How may I fix it?
 * Here is the code:
 *     ```
       'error': function(jqXHR, status, error) {
       console.log(status);
       console.log(error);
       console.log(jqXHR.responseText);
       ```
   
 * `echo json_encode(array("bookmark" => 0));`
 * And it returns:
 *     ```
       parsererror
       SyntaxError: Unexpected token < in JSON at position 14(…)
       {"bookmark":0}<!-- Really Simple SSL mixed content fixer active -->
       ```
   
 * [https://wordpress.org/plugins/really-simple-ssl/](https://wordpress.org/plugins/really-simple-ssl/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Contributor [Rogier Lankhorst](https://wordpress.org/support/users/rogierlankhorst/)
 * (@rogierlankhorst)
 * [10 years ago](https://wordpress.org/support/topic/json_encode-and-really-simple-ssl-problem/#post-7396865)
 * Hi,
 * You can remove the comment by adding a filter in your functions.php:
 *     ```
       /*
          Remove the comment from the output
       */
   
       function rsssl_remove_comment($html) {
         $html = str_replace("<!-- Really Simple SSL mixed content fixer active -->", "", $html);
         return $html;
       }
       add_filter("rsssl_fixer_output","rsssl_remove_comment");
       ```
   
 * That should solve your problem.
 *  Thread Starter [wmerussi](https://wordpress.org/support/users/wmerussi/)
 * (@wmerussi)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/json_encode-and-really-simple-ssl-problem/#post-7397154)
 * It worked, thank you so much!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘json_encode and Really Simple SSL problem’ is closed to new replies.

 * ![](https://ps.w.org/really-simple-ssl/assets/icon-256x256.png?rev=2839720)
 * [Really Simple Security - Simple and Performant Security (formerly Really Simple SSL)](https://wordpress.org/plugins/really-simple-ssl/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/really-simple-ssl/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/really-simple-ssl/)
 * [Active Topics](https://wordpress.org/support/plugin/really-simple-ssl/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/really-simple-ssl/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/really-simple-ssl/reviews/)

## Tags

 * [ajax](https://wordpress.org/support/topic-tag/ajax/)
 * [javascript](https://wordpress.org/support/topic-tag/javascript/)
 * [jquery](https://wordpress.org/support/topic-tag/jquery/)
 * [json](https://wordpress.org/support/topic-tag/json/)
 * [php](https://wordpress.org/support/topic-tag/php/)

 * 2 replies
 * 2 participants
 * Last reply from: [wmerussi](https://wordpress.org/support/users/wmerussi/)
 * Last activity: [9 years, 11 months ago](https://wordpress.org/support/topic/json_encode-and-really-simple-ssl-problem/#post-7397154)
 * Status: resolved