ऐपएमएल ट्यूटोरियल

ऐपएमएल होम AppML कैसे करें ऐपएमएल डेटा ऐपएमएल में शामिल हैं ऐपएमएल नियंत्रक ऐपएमएल संदेश ऐपएमएल मॉडल ऐपएमएल एपीआई

ऐपएमएल मामले

केस परिचय केस टेक्स्ट फ़ाइल केस एक्सएमएल फाइल केस JSON फ़ाइल केस ग्राहक केस उत्पाद केस सप्लायर्स केस शिपर्स केस श्रेणियाँ केस कर्मचारी

ऐपएमएल क्लाइंट

ऐपएमएल क्लाइंट ऐपएमएल प्रोटोटाइप ऐपएमएल सूचियां ऐपएमएल फॉर्म ऐपएमएल वेबएसक्यूएल

ऐपएमएल सर्वर

ऐपएमएल पीएचपी एपीपीएमएल एएसपी

ऐपएमएल क्लाउड

गूगल क्लाउड एसक्यूएल अमेज़ॅन आरडीएस एसक्यूएल

ऐपएमएल संदर्भ

ऐपएमएल संदर्भ ऐपएमएल डेटाफाइल्स ऐपएमएल डेटाबेस ऐपएमएल एपीआई ऐपएमएल आर्किटेक्चर ऐपएमएल इतिहास

ऐपएमएल कैसे करें


2 आसान चरणों में AppML एप्लिकेशन कैसे बनाएं


1. HTML और CSS का उपयोग करके एक पेज बनाएं

एचटीएमएल

<!DOCTYPE html>
<html lang="en-US">
<link rel="stylesheet" href="style.css">
<title>Customers</title>
<body>

<h1>Customers</h1>

<table>
<tr>
  <th>Customer</th>
  <th>City</th>
  <th>Country</th>
</tr>
<tr>
  <td>{{CustomerName}}</td>
  <td>{{City}}</td>
  <td>{{Country}}</td>
</tr>
</table>

</body>
</html>

{{ }} कोष्ठक AppML डेटा के लिए प्लेसहोल्डर हैं

सीएसएस

body {
  font: 14px Verdana, sans-serif;
}

h1 {
  color: #996600;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  border: 1px solid grey;
  padding: 5px;
  text-align: left;
}

table tr:nth-child(odd) {
  background-color: #f1f1f1;
}

सीएसएस को अपनी पसंदीदा स्टाइल शीट से बदलने के लिए स्वतंत्र महसूस करें।


2. ऐपएमएल जोड़ें

अपने पेज में डेटा जोड़ने के लिए AppML का उपयोग करें:

उदाहरण

<!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>

</body>
</html>

ऐपएमएल समझाया:

<script src="https://www.w3schools.com/appml/2.0.3/appml.js"> आपके पेज पर AppML जोड़ता है।

appml-data = "customers.js" AppML डेटा (customers.js) को एक HTML एलिमेंट (<table>) से जोड़ता है।

इस मामले में हमने JSON फ़ाइल का उपयोग किया है:

appml-repeat="records" डेटा ऑब्जेक्ट में प्रत्येक आइटम (रिकॉर्ड) के लिए एक HTML तत्व (<tr>) को दोहराता है।

{{ }} कोष्ठक AppML डेटा के लिए प्लेसहोल्डर हैं