thymeleaf / thymeleafexamples-layouts

Layouts - Companion application for the "Thymeleaf Layouts" article at the Thymeleaf website: http://www.thymeleaf.org/documentation.html http://www.thymeleaf.org
Apache License 2.0
245 stars 174 forks source link

Garbage project and article not running or working #9

Closed 7-- closed 5 years ago

7-- commented 5 years ago

Screenshot from 2019-07-28 17-25-23 What is this garbage why would you upload when it's not broken.

This article is all wrong. I tried it in my own project and the thymleaf framework is broken: Caused by: org.thymeleaf.exceptions.TemplateInputException: Error resolving template [fragments/footer], template might not exist or might not be accessible by any of the configured Template Resolvers (template: "greeting" - line 19, col 13)

<html  xmlns="http://www.w3.org/1999/xhtml" 
    xmlns:th="http://www.thymeleaf.org" >
<head>
<link rel="stylesheet" th:href="@{global.css}" />
<link rel="stylesheet" th:href="@{coin-lend.css}" />

</head>

<body class="Site">

    </h1>
    <div class="Site-content">

        <div id="main">

                <div th:replace="fragments/footer :: footer"></div>

        </div>
........
</head>
<body th:fragment="menu">
    <ul  id="nav">
        <li><a href="/"> Analysis</a></li>
        <li><a href="/steps">Getting Started</a></li>

    </ul>
</body>
</html>

Screenshot from 2019-07-28 17-31-03 https://www.thymeleaf.org/doc/articles/layouts.html

7-- commented 5 years ago

I found your issue. No where do you specify that the fragments folder needs to be inside the templates folder. Please update the article immidietly explaining the correct file paths.

7-- commented 5 years ago

Your project still doesnt run. You'll have to fix that

danielfernandez commented 5 years ago

I'm glad you found the issue in your code. I'm closing this and locking the conversation due to your inacceptable language. Please keep from using this tone in Thymeleaf's support infrastructure in the future.