Tag Archives: কেস স্টাডি

AppML কেস স্টাডি – কর্মকর্তা-কর্মচারী (AppML Case Study – Employees)

Huge Sell on Popular Electronics

এইচটিএমএল

এইচটিএমএল সোর্স:


<!DOCTYPE html>
 <html lang="en-US">
 <title>Employees</title>
 <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
 <script src="http://www.w3schools.com/appml/2.0.3/appml.js"></script>
 <body>
 
 <div class="container">
 <h1>Employees</h1>
 
 <div id="Form01" class="jumbotron" style="display:none" appml-data="local?model=model_employeesform" 
                                                                 appml-controller="myFormController">
   <div appml-include-html="inc_formcommands.htm"></div>
   <div class="form-group">
     <label>Last Name:</label>
     <input id="LastName" class="form-control">
   </div>
   <div class="form-group">
     <label>First Name:</label>
     <input id="FirstName" class="form-control">
   </div>
   <div class="form-group">
     <label>Date of Birth:</label>
     <input id="BirthDate" class="form-control">
   </div>
   <div class="form-group">
     <label>Photo:</label>
     <input id="Photo" class="form-control">
   </div>
   <div class="form-group">
     <label>Notes:</label>
     <input id="Notes" class="form-control">
   </div>
 </div>
 
 <div appml-data="local?model=model_employeeslist">
   <div appml-include-html="inc_listcommands.htm"></div>
   <div appml-include-html="inc_filter.htm"></div>
   <table class="table table-striped table-bordered">
   <tr>
     <th></th>
     <th>Last Name</th>
     <th>First Name</th>
     <th>Date of Birth</th>
   </tr>
   <tr appml-repeat="records">
     <td style="cursor:pointer"
     onclick="appml('Form01').run({{EmployeeID}})">
     <span class="glyphicon glyphicon-edit"></span>
     </td>
     <td>{{LastName}}</td>
     <td>{{FirstName}}</td>
     <td>{{BirthDate}}</td>
   </tr>
   </table>
 </div>
 
 </div>
 
 <script>
 function myFormController($appml) {
     if ($appml.message == "ready") {return -1;}
     if ($appml.message == "loaded") {
         document.getElementById("Form01").style.display = "";
     }
 }
 </script>
 
 </body>
 </html>

 

 

মডেল

এই অ্যাপ্লিকেশনের মধ্যে ব্যবহৃত মডেল

লিস্ট মডেল


 

{
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT * FROM Employees",
 "orderby" : "LastName"
 },
 "filteritems" : [
 {"item" : "LastName"},
 {"item" : "FirstName"}
 ],
 "sortitems" : [
 {"item" : "LastName"},
 {"item" : "FirstName"}
 ]
 }

 

 

ফরম মডেল


 {
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT * FROM Employees",
 "maintable" : "Employees",
 "keyfield" : "EmployeeID"
 },
 "updateItems" : [
 {"item" : "LastName"},
 {"item" : "FirstName"},
 {"item" : "BirthDate"},
 {"item" : "Photo"},
 {"item" : "Notes"}
 ]
 }

 

AppML কেস স্টাডি – শ্রেণীবিভাগ সমূহ (AppML Case Study – Categories)

Huge Sell on Popular Electronics

এইচটিএমএল

এইচটিএমএল সোর্স:


<!DOCTYPE html>
 <html lang="en-US">
 <title>Categories</title>
 <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
 <script src="http://www.w3schools.com/appml/2.0.3/appml.js"></script>
 <body>
 
 <div class="container">
 <h1>Categories</h1>
 
 <div id="Form01" class="jumbotron" style="display:none" appml-data="local?model=model_categoriesform" 
                                                                 appml-controller="myFormController">
   <div appml-include-html="inc_formcommands.htm"></div>
   <div class="form-group">
     <label>CategoryName:</label>
     <input id="CategoryName" class="form-control">
   </div>
   <div class="form-group">
     <label>Description:</label>
     <input id="Description" class="form-control">
   </div>
 </div>
 
 <div appml-data="local?model=model_categorieslist">
   <div appml-include-html="inc_listcommands_nofilter.htm"></div>
   <table class="table table-striped table-bordered">
   <tr>
     <th></th>
     <th>Category</th>
     <th>Description</th>
   </tr>
   <tr appml-repeat="records">
     <td style="cursor:pointer"
     onclick="appml('Form01').run({{CategoryID}})">
     <span class="glyphicon glyphicon-edit"></span>
     </td>
     <td>{{CategoryName}}</td>
     <td>{{Description}}</td>
     </tr>
   </table>
 </div>
 
 </div>
 
 <script>
 function myFormController($appml) {
     if ($appml.message == "ready") {return -1;}
     if ($appml.message == "loaded") {
         document.getElementById("Form01").style.display = "";
     }
 }
 </script>
 
 </body>
 </html>

 

 

মডেল

এই অ্যাপ্লিকেশনের মধ্যে ব্যবহৃত মডেল

লিস্ট মডেল


 {
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT * FROM Categories"
 }
 }

 

 

ফরম মডেল


 {
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT * FROM Categories",
 "maintable" : "Categories",
 "keyfield" : "CategoryID"
 },
 "updateItems" : [
 {"item" : "CategoryName"},
 {"item" : "Description"}
 ]
 }

 

AppML কেস স্টাডি – কোনো পরিবহনে মাল লেনদেনকারী (AppML Case Study – Shippers)

Huge Sell on Popular Electronics

এইচটিএমএল

এইচটিএমএল সোর্স:


<!DOCTYPE html>
 <html lang="en-US">
 <title>Shippers</title>
 <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
 <script src="http://www.w3schools.com/appml/2.0.3/appml.js"></script>
 <body>
 
 <div class="container">
 <h1>Shippers</h1>
 
 <div id="Form01" class="jumbotron" style="display:none" appml-data="local?model=model_shippersform" 
                                                                appml-controller="myFormController">
 <div appml-include-html="inc_formcommands.htm"></div>
 <div class="form-group">
 <label>ShipperName:</label>
 <input id="ShipperName" class="form-control">
 </div>
 <div class="form-group">
 <label>Phone:</label>
 <input id="Phone" class="form-control">
 </div>
 </div>
 
 <div appml-data="local?model=model_shipperslist">
   <div appml-include-html="inc_listcommands_nofilter.htm"></div>
   <table class="table table-striped table-bordered">
   <tr>
     <th></th>
     <th>Shipper</th>
     <th>Phone</th>
   </tr>
   <tr appml-repeat="records">
     <td style="cursor:pointer"
     onclick="appml('Form01').run({{ShipperID}})">
     <span class="glyphicon glyphicon-edit"></span>
     </td>
     <td>{{ShipperName}}</td>
     <td>{{Phone}}</td>
   </tr>
   </table>
 </div>
 
 </div>
 
 <script>
 function myFormController($appml) {
     if ($appml.message == "ready") {return -1;}
     if ($appml.message == "loaded") {
         document.getElementById("Form01").style.display = "";
     }
 }
 </script>
 
 </body>
 </html>

 

 

মডেল

এই অ্যাপ্লিকেশনের মধ্যে ব্যবহৃত মডেল

লিস্ট মডেল


 

 {
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT * FROM Shippers"
 }
 }

 

 

ফরম মডেল


 {
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT * FROM Shippers",
 "maintable" : "Shippers",
 "keyfield" : "ShipperID"
 },
 "updateItems" : [
 {"item" : "ShipperName"},
 {"item" : "Phone"}
 ]
 }

 

 

 

AppML কেস স্টাডি – সরবরাহকারী পাইকার পরিবেশক (AppML Case Study – Suppliers)

Huge Sell on Popular Electronics

এইচটিএমএল

এইচটিএমএল সোর্স:


<!DOCTYPE html>
 <html lang="en-US">
 <title>Suppliers</title>
 <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
 <script src="http://www.w3schools.com/appml/2.0.3/appml.js"></script>
 <body>
 
 <div class="container">
 <h1>Suppliers</h1>
 
 <div id="Form01" class="jumbotron" style="display:none" appml-data="local?model=model_suppliersform"
                                                                  appml-controller="myFormController">
   <div appml-include-html="inc_formcommands.htm"></div>
   <div class="form-group">
     <label>SupplierID:</label>
     <input id="SupplierID" class="form-control">
   </div>
   <div class="form-group">
     <label>SupplierName:</label>
     <input id="SupplierName" class="form-control">
   </div>
   <div class="form-group">
     <label>ContactName:</label>
     <input id="ContactName" class="form-control">
   </div>
   <div class="form-group">
     <label>Address:</label>
     <input id="Address" class="form-control">
   </div>
   <div class="form-group">
     <label>PostalCode:</label>
     <input id="PostalCode" class="form-control">
   </div>
   <div class="form-group">
     <label>City:</label>
     <input id="City" class="form-control">
   </div>
   <div class="form-group">
     <label>Country:</label>
     <input id="Country" class="form-control">
   </div>
   <div class="form-group">
     <label>Adress:</label>
     <input id="Phone" class="form-control">
   </div>
 </div>
 
 <div appml-data="local?model=model_supplierslist">
   <div appml-include-html="inc_listcommands.htm"></div>
   <div appml-include-html="inc_filter.htm"></div>
   <table class="table table-striped table-bordered">
   <tr>
     <th></th>
     <th>Supplier</th>
     <th>City</th>
     <th>Country</th>
     <th></th>
   </tr>
   <tr appml-repeat="records">
     <td style="cursor:pointer"
       onclick="appml('Form01').run({{SupplierID}})">
       <span class="glyphicon glyphicon-edit"></span>
     </td>
     <td>{{SupplierName}}</td>
     <td>{{City}}</td>
     <td>{{Country}}</td>
     <td><a href='' onclick="openProducts({{SupplierID}});return false;">Products</a></td>
   </tr>
   </table>
 </div>
 
 <div id="ProductsSection" class="jumbotron" style="display:none" appml-data="local?model=model_productslist" appml-controller="myProductsController">
 <button onclick="document.getElementById('ProductsSection').style.display='none';" type="button" class="close"><span>&times;</span></button>
 <h2>{{records[0]['SupplierName']}}</h2>
 <table class="table table-striped table-bordered">
 <tr>
   <th>Product</th>
   <th>Category</th>
   <th>Supplier</th>
 </tr>
 <tr appml-repeat="records">
   <td>{{ProductName}}</td>
   <td>{{CategoryName}}</td>
   <td>{{SupplierName}}</td>
 </tr>
 </table>
 </div>
 </div>
 
 <script>
 function openProducts(id) {
     appml("ProductsSection").clearQuery();
     appml("ProductsSection").setQuery("Products.SupplierID", id); 
     appml("ProductsSection").run();
 }
 function myFormController($appml) {
     if ($appml.message == "ready") {return -1;}
     if ($appml.message == "loaded") {
         document.getElementById("Form01").style.display = "";
     }
 }
 function myProductsController($appml) {
     if ($appml.message == "ready") {return -1;}
     if ($appml.message == "loaded") {
         document.getElementById("ProductsSection").style.display = "";
     }
 }
 </script>
 
 </body>
 </html>

 

 

মডেল

এই অ্যাপ্লিকেশনের মধ্যে ব্যবহৃত মডেল

লিস্ট মডেল


{
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT * FROM Suppliers",
 "orderby" : "SupplierName"
 },
 "filteritems" : [
 {"item" : "SupplierName"},
 {"item" : "City"},
 {"item" : "Country"}
 ],
 "sortitems" : [
 {"item" : "SupplierName"},
 {"item" : "City"},
 {"item" : "Country"}
 ],
 "rowsperpage" : 10
 }

 

 

ফরম মডেল


 

{
 "database" : {
 "connection" : "localmysql",
 "maintable" : "Customers",
 "keyfield" : "CustomerID",
 "sql" : "SELECT * FROM Customers"
 },
 "updateItems" : [
 {"item" : "CustomerName"},
 {"item" : "Address"},
 {"item" : "PostalCode"},
 {"item" : "City"},
 {"item" : "Country"}
 ]
 }

 

 

 

AppML কেস স্টাডি – পণ্য (AppML Case Study – Products)

Huge Sell on Popular Electronics

এইচটিএমএল

এইচটিএমএল সোর্স:


<!DOCTYPE html>
 <html lang="en-US">
 <title>Products</title>
 <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
 <script src="http://www.w3schools.com/appml/2.0.3/appml.js"></script>
 <body>
 
 <div class="container">
 <h1>Products</h1>
 
 <div id="Form01" class="jumbotron" style="display:none" appml-controller="myFormController">
   <div appml-include-html="inc_formcommands.htm"></div>
   <div class="form-group">
     <label>ProductName:</label>
     <input id="ProductName" class="form-control">
   </div>
   <div class="form-group">
     <label>Supplier:</label>
     <div appml-data="local?model=model_dropdown_suppliers">
       <select id="SupplierID" class="form-control">
       <option appml-repeat="records" value="{{SupplierID}}">{{SupplierName}}</option>
       </select>
     </div>
   </div>
   <div class="form-group">
     <label>Category:</label>
     <div appml-data="local?model=model_dropdown_categories">
       <select id="CategoryID" class="form-control">
       <option appml-repeat="records" value="{{CategoryID}}">{{CategoryName}}</option>
     </select>
   </div>
   </div>
   <div class="form-group">
     <label>Unit:</label>
     <input id="Unit" class="form-control">
   </div>
   <div class="form-group">
     <label>Price:</label>
     <input id="Price" onchange="myValidator(this)" class="form-control">
   </div>
 </div>
  
 <div appml-data="local?model=model_productslist" appml-controller="myListController">
 <div appml-include-html="inc_listcommands.htm"></div>
 <div appml-include-html="inc_productsquery_local.htm"></div>
 <table class="table table-striped table-bordered">
 <tr>
   <th></th>
   <th>Product Name</th>
   <th>Category</th>
   <th>Supplier</th>
   <th>Price</th> 
 </tr>
 <tr appml-repeat="records">
   <td style="cursor:pointer"
     onclick="appml('Form01').run({{ProductID}})">
     <span class="glyphicon glyphicon-edit"></span>
   </td>
   <td>{{ProductName}}</td>
   <td>{{CategoryName}}</td>
   <td>{{SupplierName}}</td>
   <td>{{Price}}</td> 
 </tr>
 </table>
 </div>
 <h3 id="sumprice"></h3>
 
 </div>
 
 <script>
 function myValidator(item) {
     var obj = appml("Form01");
     obj.message = "validate";
     obj.validate = {};
     obj.validate.item = item.id;
     obj.validate.value = item.value;
     myFormController(obj);
 }
 function myListController($appml) {
     if ($appml.message == "done") {
         var i, x, tot = 0;
         x = $appml.data.records;
         for (i = 0; i < x.length; i++) {
             tot += Number(x[i].Price);
         }
         document.getElementById("sumprice").innerHTML =
         x.length + " products. Total price " + tot; 
     }
     if ($appml.message == "display") {
         if ($appml.display.name == "ProductName") {
             $appml.display.value = $appml.display.value.toUpperCase();
         }
     }
 }
 function myFormController($appml) {
     if ($appml.message == "ready") {
         $appml.dataSource = "local?model=model_productsform";
         return -1;
     }
     if ($appml.message == "loaded") {
         document.getElementById("Form01").style.display = "";
     }
     if ($appml.message == "validate") {
         if ($appml.validate.item == "Price") { 
             if (isNaN($appml.validate.value)) { 
                 $appml.setError(15, "Price must be a number");
                 return; 
             }
         }
     }
 }
 </script>
 
 </body>
 </html>

 

 

মডেল

এই অ্যাপ্লিকেশনের মধ্যে ব্যবহৃত মডেল

লিস্ট মডেল


{
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT ProductID,ProductName,CategoryName,SupplierName,Price FROM ((Products LEFT JOIN Suppliers ON Products.SupplierID=Suppliers.SupplierID) LEFT JOIN Categories ON Products.CategoryID=Categories.CategoryID)",
 "orderby" : "ProductName"
 },
 "filteritems" : [
 {"item" : "ProductName", "label" : "Name"},
 {"item" : "Products.SupplierID", "type" : "number", "hidden" : "true"},
 {"item" : "Suppliers.SupplierID", "label" : "Supplier"}, 
 {"item" : "Categories.CategoryID", "label" : "Category"}
 ],
 "sortitems" : [
 {"item" : "ProductName"}
 ]

 

 

ফরম মডেল


 

 {
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT * FROM Products",
 "maintable" : "Products",
 "keyfield" : "ProductID"
 },
 "updateItems" : [
 {"item" : "ProductName"},
 {"item" : "SupplierID"},
 {"item" : "CategoryID"},
 {"item" : "Unit"},
 {"item" : "Price"}
 ]
 }

 

 

 

AppML কেস স্টাডি – গ্রাহকরা (AppML Case Study – Customers)

Huge Sell on Popular Electronics

এইচটিএমএল

এইচটিএমএল সোর্স:


 

<!DOCTYPE html>
 <html lang="en-US">
 <title>Customers</title>
 <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
 <script src="http://www.w3schools.com/appml/2.0.3/appml.js"></script>
 <body>
 
 <div class="container">
 <h1>Customers</h1>
 
 <div id="Form01" class="jumbotron" style="display:none" appml-data="local?model=model_customersform"
                                                                 appml-controller="myFormController">
   <div appml-include-html="inc_formcommands.htm"></div>
   <div class="form-group">
     <label for="customername">CustomerName:</label>
     <input id="customername" class="form-control">
   </div>
   <div class="form-group">
     <label for="contactname">ContactName:</label>
     <input id="contactname" class="form-control">
   </div>
   <div class="form-group">
     <label for="address">Address:</label>
     <input id="address" class="form-control">
   </div>
     <div class="form-group">
     <label for="city">City:</label>
   <input id="city" class="form-control">
   </div>
   <div class="form-group">
     <label for="postalcode">PostalCode:</label>
     <input id="postalcode" class="form-control">
   </div>
   <div class="form-group">
     <label for="country">Country:</label>
   <  input id="country" class="form-control">
   </div>
 </div>
 
 <div appml-data="local?model=model_customerslist">
   <div appml-include-html="inc_listcommands.htm"></div>
   <div appml-include-html="inc_filter.htm"></div>
   <table class="table table-striped table-bordered">
   <tr>
     <th></th>
     <th>Customer</th>
     <th>City</th>
     <th>Country</th>
   </tr>
   <tr appml-repeat="records">
     <td style="cursor:pointer;width:34px;"
       onclick="appml('Form01').run({{CustomerID}});">
       <span class="glyphicon glyphicon-edit"></span>
     </td>
     <td>{{CustomerName}}</td>
     <td>{{City}}</td>
     <td>{{Country}}</td>
   </tr>
   </table>
 </div>
 
 </div>
 
 <script>
 function myFormController($appml) {
     if ($appml.message == "ready") {return -1; }
     if ($appml.message == "loaded") {
         document.getElementById("Form01").style.display = "";
     }
 }
 </script>
 
 </body>
 </html>

 

মডেল

এই অ্যাপ্লিকেশনের মধ্যে ব্যবহৃত মডেল

লিস্ট মডেল


 

{
 "rowsperpage" : 10,
 "database" : {
 "connection" : "localmysql",
 "sql" : "SELECT * FROM Customers",
 "orderby" : "CustomerName"
 },
 "filteritems" : [
 {"item" : "CustomerName", "label" : "Customer"},
 {"item" : "City"},
 {"item" : "Country"}
 ],
 "sortitems" : [
 {"item" : "CustomerName", "label" : "Customer"},
 {"item" : "City"},
 {"item" : "Country"}
 ]
 }

 

ফরম মডেল


{
 "database" : {
 "connection" : "localmysql",
 "maintable" : "Customers",
 "keyfield" : "CustomerID",
 "sql" : "SELECT * FROM Customers"
 },
 "updateItems" : [
 {"item" : "CustomerName"},
 {"item" : "Address"},
 {"item" : "PostalCode"},
 {"item" : "City"},
 {"item" : "Country"}
 ]
 }

 

 

 

AppML কেস স্টাডি – JSON ফাইল (AppML Case Study – JSON Files)

Huge Sell on Popular Electronics

এইচটিএমএল

এইচটিএমএল সোর্স:


<<!DOCTYPE html>
<html lang="en-US">
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
<script src="http://www.w3schools.com/appml/2.0.3/appml.js"></script>
<body>
<div class="container" appml-data="appml.php?model=model_cd_from_json">
<h1>CD Collection</h1>
<h3>Extracted from an XML file</h3>
<div appml-include-html="inc_listcommands_nofilter.htm"></div>
<table class="table table-striped table-bordered">
<tr>
    <th>Title</th>
    <th>Artist</th>
    <th>Country</th>
</tr>
<tr appml-repeat="records">
    <td>{{Title}}</td>
    <td>{{Artist}}</td>
    <td>{{Country}}</td>
</tr>
</table>
</div>
</body>
</html>

 

 

মডেল

এই অ্যাপ্লিকেশনের মধ্যে ব্যবহৃত মডেল


 

{
 "rowsperpage" : 7,
 "data" : {
    "type" : "jsonfile",
    "filename" : "cd_catalog.js",
    "record" : "cd",
    "items" : [
        {"name" : "Title", "nodename" : "title"},
        {"name" : "Artist", "nodename" : "artist"},
        {"name" : "Price", "nodename" : "price"}
    ]
  }
}

 

ফাইল

কমা দিয়ে পৃথক করা টেক্সট ফাইল:


{
"cd" : [
{ "title" : "Empire Burlesque", "artist" : "Bob Dylan", "price" : "10.90" },
{ "title" : "Hide your heart", "artist" : "Bonnie Tyler", "price" : "9.90" },
{ "title" : "Greatest Hits", "artist" : "Dolly Parton", "price" : "9.90" },
{ "title" : "Still got the blues", "artist" : "Bob Dylan", "price" : "10.20" },
{ "title" : "Eros", "artist" : "Eros Ramazzotti", "price" : "9.90" },
{ "title" : "One night only", "artist" : "Bee Gees", "price" : "10.90" },
{ "title" : "Sylvias Mother", "artist" : "Dr.Hook", "price" : "8.10" },
{ "title" : "Maggie May", "artist" : "Rod Stewart", "price" : "8.50" },
{ "title" : "Empire Burlesque", "artist" : "Bob Dylan", "price" : "10.90" },
{ "title" : "Hide your heart", "artist" : "Bonnie Tyler", "price" : "9.90" },
{ "title" : "Greatest Hits", "artist" : "Dolly Parton", "price" : "9.90" },
{ "title" : "Still got the blues", "artist" : "Bob Dylan", "price" : "10.20" },
{ "title" : "Eros", "artist" : "Eros Ramazzotti", "price" : "9.90" },
{ "title" : "One night only", "artist" : "Bee Gees", "price" : "10.90" },
{ "title" : "Sylvias Mother", "artist" : "Dr.Hook", "price" : "8.10" },
{ "title" : "Maggie May", "artist" : "Rod Stewart", "price" : "8.50" },
{ "title" : "Empire Burlesque", "artist" : "Bob Dylan", "price" : "10.90" },
{ "title" : "Hide your heart", "artist" : "Bonnie Tyler", "price" : "9.90" },
{ "title" : "Greatest Hits", "artist" : "Dolly Parton", "price" : "9.90" },
{ "title" : "Still got the blues", "artist" : "Bob Dylan", "price" : "10.20" },
{ "title" : "Eros", "artist" : "Eros Ramazzotti", "price" : "9.90" },
{ "title" : "One night only", "artist" : "Bee Gees", "price" : "10.90" },
{ "title" : "Sylvias Mother", "artist" : "Dr.Hook", "price" : "8.10" },
{ "title" : "Maggie May", "artist" : "Rod Stewart", "price" : "8.50" },
{ "title" : "Empire Burlesque", "artist" : "Bob Dylan", "price" : "10.90" },
{ "title" : "Hide your heart", "artist" : "Bonnie Tyler", "price" : "9.90" },
{ "title" : "Greatest Hits", "artist" : "Dolly Parton", "price" : "9.90" },
{ "title" : "Still got the blues", "artist" : "Bob Dylan", "price" : "10.20" },
{ "title" : "Eros", "artist" : "Eros Ramazzotti", "price" : "9.90" },
{ "title" : "One night only", "artist" : "Bee Gees", "price" : "10.90" },
{ "title" : "Sylvias Mother", "artist" : "Dr.Hook", "price" : "8.10" },
{ "title" : "Maggie May", "artist" : "Rod Stewart", "price" : "8.50" },
{ "title" : "Empire Burlesque", "artist" : "Bob Dylan", "price" : "10.90" },
{ "title" : "Hide your heart", "artist" : "Bonnie Tyler", "price" : "9.90" },
{ "title" : "Greatest Hits", "artist" : "Dolly Parton", "price" : "9.90" },
{ "title" : "Still got the blues", "artist" : "Bob Dylan", "price" : "10.20" },
{ "title" : "Eros", "artist" : "Eros Ramazzotti", "price" : "9.90" },
{ "title" : "One night only", "artist" : "Bee Gees", "price" : "10.90" },
{ "title" : "Sylvias Mother", "artist" : "Dr.Hook", "price" : "8.10" },
{ "title" : "Maggie May", "artist" : "Rod Stewart", "price" : "8.50" }
]
}

 

 

 

AppML কেস স্টাডি – এক্সএমএল ফাইল (AppML Case Study – XML Files)

Huge Sell on Popular Electronics

এইচটিএমএল

এইচটিএমএল সোর্স:


<!DOCTYPE html>
<html lang="en-US">
<head>
<meta charset="utf-8">
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
<script src="http://www.w3schools.com/appml/2.0.3/appml.js"></script>
</head>
<body>
<div class="container" appml-data="appml.php?model=model_cd_from_xml">
<h1>CD Collection</h1>
<h3>Extracted from an XML file</h3>
<div appml-include-html="inc_listcommands_nofilter.htm"></div>
<table class="table table-striped table-bordered">
<tr>
<th>Title</th>
<th>Artist</th>
<th>Country</th>
</tr>
<tr appml-repeat="records">
<td>{{Title}}</td>
<td>{{Artist}}</td>
<td>{{Country}}</td>
</tr>
</table>
</div>
</body>
</html>

 

 

মডেল

এই অ্যাপ্লিকেশনের মধ্যে ব্যবহৃত মডেল


{
 "rowsperpage" : 7,
 "data" : {
    "type" : "xmlfile",
    "filename" : "cd_catalog.xml",
    "record" : "CD",
    "items" : [
       {"name" : "Artist", "nodename" : "ARTIST"},
       {"name" : "Title", "nodename" : "TITLE"},
       {"name" : "Country", "nodename" : "COUNTRY"}
    ]
 }
}

 

 

ফাইল

কমা দিয়ে পৃথক করা টেক্সট ফাইল:


<?xml version="1.0" encoding="ISO-8859-1"?>
<CATALOG>
<CD>
<TITLE>Empire Burlesque</TITLE>
<ARTIST>Bob Dylan</ARTIST>
<COUNTRY>USA</COUNTRY>
<COMPANY>Columbia</COMPANY>
<PRICE>10.90</PRICE>
<PUBLISHED>1985</PUBLISHED>
</CD>
<CD>
<TITLE>Hide your heart</TITLE>
<ARTIST>Bonnie Tyler</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>CBS Records</COMPANY>
<PRICE>9.90</PRICE>
<PUBLISHED>1988</PUBLISHED>
</CD>
<CD>
<TITLE>Greatest Hits</TITLE>
<ARTIST>Dolly Parton</ARTIST>
<COUNTRY>USA</COUNTRY>
<COMPANY>RCA</COMPANY>
<PRICE>9.90</PRICE>
<PUBLISHED>1982</PUBLISHED>
</CD>
<CD>
<TITLE>Still got the blues</TITLE>
<ARTIST>Gary Moore</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>Virgin records</COMPANY>
<PRICE>10.20</PRICE>
<PUBLISHED>1990</PUBLISHED>
</CD>
<CD>
<TITLE>Eros</TITLE>
<ARTIST>Eros Ramazzotti</ARTIST>
<COUNTRY>EU</COUNTRY>
<COMPANY>BMG</COMPANY>
<PRICE>9.90</PRICE>
<PUBLISHED>1997</PUBLISHED>
</CD>
<CD>
<TITLE>One night only</TITLE>
<ARTIST>Bee Gees</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>Polydor</COMPANY>
<PRICE>10.90</PRICE>
<PUBLISHED>1998</PUBLISHED>
</CD>
<CD>
<TITLE>Sylvias Mother</TITLE>
<ARTIST>Dr.Hook</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>CBS</COMPANY>
<PRICE>8.10</PRICE>
<PUBLISHED>1973</PUBLISHED>
</CD>
<CD>
<TITLE>Maggie May</TITLE>
<ARTIST>Rod Stewart</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>Pickwick</COMPANY>
<PRICE>8.50</PRICE>
<PUBLISHED>1990</PUBLISHED>
</CD>
<CD>
<TITLE>Romanza</TITLE>
<ARTIST>Andrea Bocelli</ARTIST>
<COUNTRY>EU</COUNTRY>
<COMPANY>Polydor</COMPANY>
<PRICE>10.80</PRICE>
<PUBLISHED>1996</PUBLISHED>
</CD>
<CD>
<TITLE>When a man loves a woman</TITLE>
<ARTIST>Percy Sledge</ARTIST>
<COUNTRY>USA</COUNTRY>
<COMPANY>Atlantic</COMPANY>
<PRICE>8.70</PRICE>
<PUBLISHED>1987</PUBLISHED>
</CD>
<CD>
<TITLE>Black angel</TITLE>
<ARTIST>Savage Rose</ARTIST>
<COUNTRY>EU</COUNTRY>
<COMPANY>Mega</COMPANY>
<PRICE>10.90</PRICE>
<PUBLISHED>1995</PUBLISHED>
</CD>
<CD>
<TITLE>1999 Grammy Nominees</TITLE>
<ARTIST>Many</ARTIST>
<COUNTRY>USA</COUNTRY>
<COMPANY>Grammy</COMPANY>
<PRICE>10.20</PRICE>
<PUBLISHED>1999</PUBLISHED>
</CD>
<CD>
<TITLE>For the good times</TITLE>
<ARTIST>Kenny Rogers</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>Mucik Master</COMPANY>
<PRICE>8.70</PRICE>
<PUBLISHED>1995</PUBLISHED>
</CD>
<CD>
<TITLE>Big Willie style</TITLE>
<ARTIST>Will Smith</ARTIST>
<COUNTRY>USA</COUNTRY>
<COMPANY>Columbia</COMPANY>
<PRICE>9.90</PRICE>
<PUBLISHED>1997</PUBLISHED>
</CD>
<CD>
<TITLE>Tupelo Honey</TITLE>
<ARTIST>Van Morrison</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>Polydor</COMPANY>
<PRICE>8.20</PRICE>
<PUBLISHED>1971</PUBLISHED>
</CD>
<CD>
<TITLE>Soulsville</TITLE>
<ARTIST>Jorn Hoel</ARTIST>
<COUNTRY>Norway</COUNTRY>
<COMPANY>WEA</COMPANY>
<PRICE>7.90</PRICE>
<PUBLISHED>1996</PUBLISHED>
</CD>
<CD>
<TITLE>The very best of</TITLE>
<ARTIST>Cat Stevens</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>Island</COMPANY>
<PRICE>8.90</PRICE>
<PUBLISHED>1990</PUBLISHED>
</CD>
<CD>
<TITLE>Stop</TITLE>
<ARTIST>Sam Brown</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>A and M</COMPANY>
<PRICE>8.90</PRICE>
<PUBLISHED>1988</PUBLISHED>
</CD>
<CD>
<TITLE>Bridge of Spies</TITLE>
<ARTIST>T'Pau</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>Siren</COMPANY>
<PRICE>7.90</PRICE>
<PUBLISHED>1987</PUBLISHED>
</CD>
<CD>
<TITLE>Private Dancer</TITLE>
<ARTIST>Tina Turner</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>Capitol</COMPANY>
<PRICE>8.90</PRICE>
<PUBLISHED>1983</PUBLISHED>
</CD>
<CD>
<TITLE>Midt om natten</TITLE>
<ARTIST>Kim Larsen</ARTIST>
<COUNTRY>EU</COUNTRY>
<COMPANY>Medley</COMPANY>
<PRICE>7.80</PRICE>
<PUBLISHED>1983</PUBLISHED>
</CD>
<CD>
<TITLE>Pavarotti Gala Concert</TITLE>
<ARTIST>Luciano Pavarotti</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>DECCA</COMPANY>
<PRICE>9.90</PRICE>
<PUBLISHED>1991</PUBLISHED>
</CD>
<CD>
<TITLE>The dock of the bay</TITLE>
<ARTIST>Otis Redding</ARTIST>
<COUNTRY>USA</COUNTRY>
<COMPANY>Atlantic</COMPANY>
<PRICE>7.90</PRICE>
<PUBLISHED>1987</PUBLISHED>
</CD>
<CD>
<TITLE>Picture book</TITLE>
<ARTIST>Simply Red</ARTIST>
<COUNTRY>EU</COUNTRY>
<COMPANY>Elektra</COMPANY>
<PRICE>7.20</PRICE>
<PUBLISHED>1985</PUBLISHED>
</CD>
<CD>
<TITLE>Red</TITLE>
<ARTIST>The Communards</ARTIST>
<COUNTRY>UK</COUNTRY>
<COMPANY>London</COMPANY>
<PRICE>7.80</PRICE>
<PUBLISHED>1987</PUBLISHED>
</CD>
<CD>
<TITLE>Unchain my heart</TITLE>
<ARTIST>Joe Cocker</ARTIST>
<COUNTRY>USA</COUNTRY>
<COMPANY>EMI</COMPANY>
<PRICE>8.20</PRICE>
<PUBLISHED>1987</PUBLISHED>
</CD>
</CATALOG>

 

AppML কেস স্টাডি – টেক্সট ফাইল (AppML Case Study – Text Files)

Huge Sell on Popular Electronics

এইচটিএমএল

এইচটিএমএল সোর্স:


<!DOCTYPE html>
 <html lang="en-US">
 <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
 <script src="http://www.w3schools.com/appml/2.0.3/appml.js"></script>
 <body>
<div class="container" appml-data="appml.php?model=model_cd_from_txt">
 <h1>CD Collection</h1>
 <h3>Extracted from an XML file</h3>
<div appml-include-html="inc_listcommands_nofilter.htm"></div>
 <table class="table table-striped table-bordered">
 <tr>
    <th>Title</th>
    <th>Artist</th>
    <th>Country</th>
 </tr>
 <tr appml-repeat="records">
    <td>{{Title}}</td>
    <td>{{Artist}}</td>
    <td>{{Country}}</td>
 </tr>
 </table>
 </div>
</body>
 </html>

 

মডেল

এই অ্যাপ্লিকেশনের মধ্যে ব্যবহৃত মডেল


{
 "rowsperpage" : 7,
 "data" : {
    "type" : "csvfile",
    "filename" : "cd_catalog.txt",
    "items" : [
       {"name" : "Title", "index" : 1},
       {"name" : "Artist", "index" : 2},
       {"name" : "Price", "index" : 5}
    ]
 }
}

ফাইল

কমা দিয়ে পৃথক করা টেক্সট ফাইল:


Empire Burlesque,Bob Dylan,USA,Columbia,10.90,1985
Hide your heart,Bonnie Tyler,UK,CBS Records,9.90,1988
Greatest Hits,Dolly Parton,USA,RCA,9.90,1982
Still got the blues,Gary Moore,UK,Virgin records,10.20,1990
Eros,Eros Ramazzotti,EU,BMG,9.90,1997
One night only,Bee Gees,UK,Polydor,10.90,1998
Sylvias Mother,Dr.Hook,UK,CBS,8.10,1973
Maggie May,Rod Stewart,UK,Pickwick,8.50,1990
Empire Burlesque,Bob Dylan,USA,Columbia,10.90,1985
Hide your heart,Bonnie Tyler,UK,CBS Records,9.90,1988
Greatest Hits,Dolly Parton,USA,RCA,9.90,1982
Still got the blues,Gary Moore,UK,Virgin records,10.20,1990
Eros,Eros Ramazzotti,EU,BMG,9.90,1997
One night only,Bee Gees,UK,Polydor,10.90,1998
Sylvias Mother,Dr.Hook,UK,CBS,8.10,1973
Maggie May,Rod Stewart,UK,Pickwick,8.50,1990
Empire Burlesque,Bob Dylan,USA,Columbia,10.90,1985
Hide your heart,Bonnie Tyler,UK,CBS Records,9.90,1988
Greatest Hits,Dolly Parton,USA,RCA,9.90,1982
Still got the blues,Gary Moore,UK,Virgin records,10.20,1990
Eros,Eros Ramazzotti,EU,BMG,9.90,1997
One night only,Bee Gees,UK,Polydor,10.90,1998
Sylvias Mother,Dr.Hook,UK,CBS,8.10,1973
Maggie May,Rod Stewart,UK,Pickwick,8.50,1990
Empire Burlesque,Bob Dylan,USA,Columbia,10.90,1985
Hide your heart,Bonnie Tyler,UK,CBS Records,9.90,1988
Greatest Hits,Dolly Parton,USA,RCA,9.90,1982
Still got the blues,Gary Moore,UK,Virgin records,10.20,1990
Eros,Eros Ramazzotti,EU,BMG,9.90,1997
One night only,Bee Gees,UK,Polydor,10.90,1998
Sylvias Mother,Dr.Hook,UK,CBS,8.10,1973
Maggie May,Rod Stewart,UK,Pickwick,8.50,1990