Saving CMS pages from admin back-end and VCS #297
arvislacis
started this conversation in
Ideas
Replies: 1 comment 4 replies
-
I'm not quite sure on the reasoning on the first point - I can only assume it was to make it clear that the content block was a PHP script, but there could very well be other reasons why it is done. On the second point, I believe that's because the content blocks are run through |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Maybe there are some historical or technical reasons but I was thinking about some interesting behavior currently happening when saving CMS pages from admin back-end UI:
<?php
and?>
tags are added to the PHP code section (if they original doesn't exist).Both of these behaviors conflicts with VCS like git and/or different coding standarts, for example, when source code files always should have trailing new-line. Also, for example, Winter CMS doc examples mostly everywhere shows CMS page structure with PHP code section without
<?php
/?>
tags...So I was thinking - are there some particular reason for this? I am mostly referring to the 1st point... Maybe there should be additional configuration options for this, for example, which would not add
<?php
/?>
and another one for trailing new-lines?Or I better should try to achieve this with my own custom plugin functionality?
Beta Was this translation helpful? Give feedback.
All reactions