kirby-json-api
kirby-json-api copied to clipboard
How could I return "coverimage" with URL instead of filename?
Hello, Thanks for this great plugin. by default, the ""coverimage", will only return the filename eg. "coverimage": "extending.png", How can I make it return with the image url instead? I have no experience with PHP, so Im not too sure how to implement this. Thanks
I think I found a temporary solution, by adding this line 'content_url' => new StaticField($page->contentURL()),
Now the it will return
"content_url": "http://localhost:8888/kirby/content/2-blog/20160802-extending-kirby", "coverimage": "extending.png",
and then I can just do content_url+'/'+coverimage