I am new in HTML
i want to make a user list web page. The page reads user.txt and show then left column of the tabel.
And new items in which New User column will be added to user.txt list
Instead of get/post http methos i am trying to use 2 AJAX methods to communicate the server side.
After sending url with AJAX i will call php scripts on the server side
I think first AJAX method for adding is below
XMLHttpRequestObject.open("GET", dataSource);
However. I coulnt find the second. And i dont know how to implement
Here is my code
<!DOCTYPE html>
<SCRIPT language="javascript">
function add(nm, ml) { }
function read(nam,mail) { }
</SCRIPT>
<html>
<body>
<table border = "1">
<thead>
<tbody>
<tr>
<th>Registered Users</th>
<th>New User</th>
</tr>
<tr>
<td></br></td>
<td>
<p><label>Name:
<input name = "name" type = "text">
<p><label>Email:
<input name = "email" type = "text">
</td>
</tr>
<tr>
<td>
<p></p>
<button onclick="read()">Read users list</button>
</td>
<td>
<p></p>
<button onclick="add(name,email)">Add user to list</button>
<p id="demo2"></p>
</td>
</tr>
</tbody>
</thead>
</table>
</body>
</html>