Forum
Collection return with Raw and html returning errors...
If I have this:
$item = perch_collection('Items', [
'skip-template' => true,
'template' =>'a template.html',
'filter' => 'slug',
'match' => 'eq',
'value' => perch_get('item'),
'raw' => true
]);
It works. I'm using raw because I need to get latitude and longitude from a map field.
But I would also like to return html, so I'm trying to add return-html:
$item = perch_collection('Items', [
'skip-template' => true,
'template' =>'a template.html',
'return-html' => true,
'filter' => 'slug',
'match' => 'eq',
'value' => perch_get('item'),
'raw' => true
]);
but I get a bunch of errors...
Should it work to call raw and return-html in the same perch_collection call?
which are?
sorry :)
Looks like you'll not be able to do that.
return-html
is designed to work withskip-template
.