Fix issues in gallery API
Fix issues in gallery API

- Let PHP encode the JSON correctly.
- use == instead of === for comparison to database values for the featured folder ID and name
jbrowneuk/jblog,jbrowneuk/jblog,jbrowneuk/jblog,jbrowneuk/jblog