WP-Filebase icon indicating copy to clipboard operation
WP-Filebase copied to clipboard

Separate JS code to support JSON API requests

Open TishoTM opened this issue 9 years ago • 4 comments

TishoTM avatar Dec 09 '15 06:12 TishoTM

Seperating JS code is a good idea. But how does it support JSON API requests?

fl4p avatar Dec 09 '15 11:12 fl4p

When JSON encoding the articles content, JS code inside the article breaks the JSON string and it becomes impossible to fetch the articles via RESTful API with JSON responses.

TishoTM avatar Dec 09 '15 14:12 TishoTM

Makes sense, but there have to be changed a lot more. What is your application for this, just curious?

fl4p avatar Jan 13 '16 15:01 fl4p

I am mostly using the file browser view inside the articles. There might be other places in the codebase that need revision, but have not looked at those. My particular use case is mobile app fetching the WP articles via api with JSON responses.

TishoTM avatar Jan 15 '16 12:01 TishoTM