How is it possible to use php inside an entry-field? When I write e.g. in the summary-field
test <?php echo 'bla'; ?> test
I get exactly the same string in the frontend:
test <?php echo 'bla'; ?> test
How can I manage that the php-command is executed? The template where I am trying to use this allows php to be parsed; changing parsing-stage from output to input changes nothing.
UPDATE 1: I am working with EE 5.3.2
UPDATE 2: The reason I want to do this is the following: I have a snippet which contains the number of mailinglist-subscribers; it just shows the pure number. In (only) one/some of my entries I want to show this number, like "The mailinglist contains 32673 subscribers". If I could use the snippet (like I could in a template) I just would write "The mailinglist contains { snip_number } subscribers." As I assume that the allow-ee-code-plugin might be deprecated for EE5 and is not futuresafe I tried to realize it with php like
The mailinglist contains <?php echo(file_get_contents('/path/getnumbers.php'));?>
UPDATE 3: It seems that the allow-eecode-plugin still is working with EE 5.3.x (as JCOGS points out in his comment). For me with the snippet/partial it still does not work, as
{exp:allow_eecode query="y"}{summary}{/exp:allow_eecode}
allows to parse an exp:query-tag which I enter in the summary-field, but not a snippet/partial.
<?php echo "<?php echo 'bla'; ?>"; ?>
would output that string, just like EE outputting the content from a data field. Also, please rethink your problem if this if your chosen solution (PHP in an entry field EVALed).{if my_snippet_field == "snippet_1"}{snippet_1}{/if}
. It can definitely be done better than that, just an example. If you can explain what you are trying to do, I can open an answer and attack the problem.