rspec/rules/S1997/rule.adoc

18 lines
433 B
Plaintext
Raw Normal View History

2020-06-30 12:47:33 +02:00
Shared coding conventions allow teams to collaborate efficiently. To avoid the confusion that can be caused by tangling two coding languages in the same file, inline HTML should be avoided.
== Noncompliant Code Example
----
<?php
$name = "George";
?>
<p> Hello <?php echo $name ?>!</p>
----
== Exceptions
2021-01-27 13:42:22 +01:00
File having the extension ``++.phtml++`` are ignored by this rule because they are expected to have mixed PHP and HTML.
2020-06-30 12:47:33 +02:00