app proxy - rendering the liquid response

app proxy - rendering the liquid response

Shopify Partner
2 0 0

Based on the documentation, Shopify should be able to render the liquid tags return by the app proxy, but it seems that that is not the case, so for example:




header("Content-Type: application/liquid");
echo "<h1>Hello!</h1>";

$fileContent = file_get_contents('temp.liquid');

  if ($fileContent !== false) {
    // File content has been successfully read
    echo $fileContent;
    echo '{{ product.title }}';
    echo 'sample';
  } else {
      // Error handling if the file couldn't be read
      echo "Unable to read the file.";
}catch(Exception $e){
  echo $e->getMessage();




The above code is not rendering the liquid tags. Only the `sample` are rendered.
Any idea on this? Most of the times there's no output for liquid tags.

Replies 0 (0)