Skip to content

PHP + HTML indentation patternΒ #610

@SnowRunescape

Description

@SnowRunescape

Currently, the indentation with PHP + HTML leaves the code in this way.

<?php
$teste = "dd";
if ($teste == "dd") {
?>
    <div>
        dsadas
    </div>
<?php
}
?>

What do we need to do to leave it like this:

<?php
$teste = "dd";
if ($teste == "dd") {
    ?>
    <div>
        dsadas
    </div>
    <?php
}
?>

Once inside an IF or FOR, we add 4 spaces for indentation. It doesn't make sense for it to stay in the same sequence as the IF, or even worse, at the beginning of the line without any indentation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions