Skip to content

Formatting isn't working  #5

@ghost

Description

Hi, i'm currently trying to format HTML in a PHP File and it seems like the plugin doesn't work for me... I'm on the last vscode & php version, got the settings set and still only the php is formatted.

"[php]": {
    "editor.formatOnSave": true
    } is set.

This is my code (unformatted):

<?php

$sample = get_sample();
foreach ($sample as $s) {
    if ($s->bool == true) {
        var_dump($s->content);
    }
}

?>

<!-- sample page --> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html>
<head>
<?php include 'headings.php';?>
</head>
<body>
<?php include 'navbar.php';?>
<?php include 'image.php';?>
</body>
</html>

<ul id="nav">
<li>
<a href="Home.html"><?='HOME'?></a>
</li>
<li>
<a>About Me</a>
<ul>
<li>
<a href="Career.html">Career</a>
</li>
<li>
<a href="Coding.html">Coding</a>
</li>
<li>
<a href="Personal.html">Personal</a>
</li>
</ul>
</li>
<li>
<a href="Travels.html">Travel</a>
</li>
<li>
<a href="Contact.html">Contact</a>
</li>
</ul>

Could you please help me ? :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    duplicateThis issue or pull request already exists

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions