@mrhaw - What aspect are you asking about ... the PHP insertion issue my post was about or using MODX as a webpage generator not page server?
-
☆ A M B ☆
- 3,141 Posts
As far as I know, the MODX core doesn't escape php tags anywhere - it simply treats them as text. I just tried this by adding in
<?php echo "Hello world!"; ?>
to a chunk, and it outputted exactly that (without the HTML comments you are seeing) into my page front-end.
Maybe you have some kind of processing in a plugin that is escaping the code?
-
☆ A M B ☆
- 3,141 Posts
By the way, that approach to using MODX as a static page generator sounds really interesting. If it's something you'd like to share more about, I think that's great to post on MODX.today someday:
https://modx.today/submit
-
☆ A M B ☆
- 24,524 Posts
It could be the TinyMCE. It has a tendency to be excessively helpful at times.
After 30 plus hours of flying and few jetlagged experiments, Mark was correct, the PHP does not get modified. I tried a few saves direct to the server files, rather than looking at the the MODX output in my browser. And all PHP appeared intact and then functioned properly when requested through the server.
I am assuming that it was the source code viewer that I was using during the early experimentation, that might have been inserting the comment code after the fact.
Thanks to all for the help, that was the last hurdle, now it is "build the pages" time.