Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revisit the complete logic of the
DisallowAlternativePHPTags
Sniff.…
… New & improved version. Includes additional unit tests.
- Loading branch information
Showing
7 changed files
with
179 additions
and
104 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
WordPress/Tests/PHP/DisallowAlternativePHPTagsUnitTest.inc.fixed
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<div> | ||
<?php echo $var; ?> | ||
Some content here. | ||
<?php echo $var; ?> | ||
<p>Some text <?php echo $var; ?> and some more text</p> | ||
<?php echo $var . ' and some more text to make sure the snippet works'; ?> | ||
<p>Some text <?php echo $var ?> and some more text</p> | ||
<?php | ||
echo $var; | ||
?> | ||
<?php echo $var;?> | ||
<script type="text/php" language="php"> | ||
echo $var; | ||
</script> | ||
<script language='PHP' type='text/php'> | ||
echo $var; | ||
</script> | ||
</div> |
Oops, something went wrong.