BEST SITE FOR WEB DEVELOPERS
AppML. W3Schools in English. Lessons for beginners

Ua

AppML HTML Includes


With AppML, you can include HTML in HTML.


Including HTML in HTML

A good example of this, is to include a standard HTML footer in all your HTML pages.

This is an example of a file containing a standard footer:

inc_footer.htm

<hr style="margin-top:10px;">
<p style="font-size:11px">2016&copy; W3Schools. All rights reserved.</p>
<hr>

In this example the appml-include-html attribute is used to include the file "inc_footer.htm":

Example

<!DOCTYPE html>
<html lang="en-US">

<title>Customers</title>
<link rel="stylesheet" href="style.css">
<script src="https://www.w3schools.com/appml/2.0.3/appml.js"></script>

<body>

<h1>Customers</h1>
<table appml-data="customers.js">
<tr>
  <th>Customer</th>
  <th>City</th>
  <th>Country</th>
</tr>
<tr appml-repeat="records">
  <td>{{CustomerName}}</td>
  <td>{{City}}</td>
  <td>{{Country}}</td>
</tr>
</table>

<div appml-include-html="inc_footer.htm"></div>

</body>
</html>
Try It Yourself »