json - New thumbnail size url in WP returning "0" with Angular and WP-API -
i'm working on project using wp-api , angular.
i added new custom image size functions.php
my /wp-json/posts (the json output) shows url new image size , using url works.
http://localhost/mysite/wp-content/uploads/2015/07/6823214-large-600x300.jpg
but outputting url angular doesn't work (returns "0")
{{house.featured_image.attachment_meta.sizes.blog-thumb.url}}
however still works fine (the original sizes):
{{house.featured_image.attachment_meta.sizes.medium.url}} {{house.featured_image.attachment_meta.sizes.thumbnail.url}}
this might have "-" in name (blog-thumb). tried doing same again using new name (blogthumb) , worked fine!
then make sure added new image size called "test-er" , had same issues first time around.
Comments
Post a Comment