Skip to main content
Stack Overflow
  1. About
  2. For Teams

Return to Question

Commonmark migration
Source Link

I am trying to switch from a very basic webpage into anthor one but i face some issues with the result once i click on getAll

My previous webpage (the wroking one )

<html>
<head>
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
</head>
<body>
 <button onclick="getAll()"> Get All The Users </button>
 <div id="users"></div>
 <script>
 function getAll()
 
 {
 $("#users").html("");
 
 
 
 $.getJSON("http://localhost:8080/users", function(data)
 {
 for (var i in data) {
 $('#users').append("<p>ID: " + data[i].id + "</p>")
 $('#users').append("<p>First name: " + data[i].fname + "</p>")
 $('#users').append("<p>Last name: " + data[i].lname + "</p><br>")
 }
 }); 
 
 }
 
 </script>
</body>
</html>

Here is the error:

Uncaught ReferenceError: getAll is not defined
 at HTMLButtonElement.onclick (testt.html:96)
onclick @ @ testt.html:96
testt.html:145 
Uncaught ReferenceError: screenfull is not defined
 at HTMLDivElement.<anonymous> (testt.html:145)
(anonymous) @ testt.html:145

EDITED After Nina ́s answer i get the desired result but the homepage looks like this:

[The result][2]The result

So it distorts the upper part of my homepage. [2]: https://i.sstatic.net/IST0A.png

I am trying to switch from a very basic webpage into anthor one but i face some issues with the result once i click on getAll

My previous webpage (the wroking one )

<html>
<head>
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
</head>
<body>
 <button onclick="getAll()"> Get All The Users </button>
 <div id="users"></div>
 <script>
 function getAll()
 
 {
 $("#users").html("");
 
 
 
 $.getJSON("http://localhost:8080/users", function(data)
 {
 for (var i in data) {
 $('#users').append("<p>ID: " + data[i].id + "</p>")
 $('#users').append("<p>First name: " + data[i].fname + "</p>")
 $('#users').append("<p>Last name: " + data[i].lname + "</p><br>")
 }
 }); 
 
 }
 
 </script>
</body>
</html>

Here is the error:

Uncaught ReferenceError: getAll is not defined
 at HTMLButtonElement.onclick (testt.html:96)
onclick @ @ testt.html:96
testt.html:145 
Uncaught ReferenceError: screenfull is not defined
 at HTMLDivElement.<anonymous> (testt.html:145)
(anonymous) @ testt.html:145

EDITED After Nina ́s answer i get the desired result but the homepage looks like this:

[The result][2]

So it distorts the upper part of my homepage. [2]: https://i.sstatic.net/IST0A.png

I am trying to switch from a very basic webpage into anthor one but i face some issues with the result once i click on getAll

My previous webpage (the wroking one )

<html>
<head>
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
</head>
<body>
 <button onclick="getAll()"> Get All The Users </button>
 <div id="users"></div>
 <script>
 function getAll()
 
 {
 $("#users").html("");
 
 
 
 $.getJSON("http://localhost:8080/users", function(data)
 {
 for (var i in data) {
 $('#users').append("<p>ID: " + data[i].id + "</p>")
 $('#users').append("<p>First name: " + data[i].fname + "</p>")
 $('#users').append("<p>Last name: " + data[i].lname + "</p><br>")
 }
 }); 
 
 }
 
 </script>
</body>
</html>

Here is the error:

Uncaught ReferenceError: getAll is not defined
 at HTMLButtonElement.onclick (testt.html:96)
onclick @ @ testt.html:96
testt.html:145 
Uncaught ReferenceError: screenfull is not defined
 at HTMLDivElement.<anonymous> (testt.html:145)
(anonymous) @ testt.html:145

EDITED After Nina ́s answer i get the desired result but the homepage looks like this:

The result

So it distorts the upper part of my homepage.

deleted 99 characters in body
Source Link

I am trying to switch from a very basic webpage into anthor one but i face some issues with the result once i click on getAll

[Check My new webpage][1]

My previous webpage (the wroking one )

<html>
<head>
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
</head>
<body>
 <button onclick="getAll()"> Get All The Users </button>
 <div id="users"></div>
 <script>
 function getAll()
 
 {
 $("#users").html("");
 
 
 
 $.getJSON("http://localhost:8080/users", function(data)
 {
 for (var i in data) {
 $('#users').append("<p>ID: " + data[i].id + "</p>")
 $('#users').append("<p>First name: " + data[i].fname + "</p>")
 $('#users').append("<p>Last name: " + data[i].lname + "</p><br>")
 }
 }); 
 
 }
 
 </script>
</body>
</html>

Here is the error:

Uncaught ReferenceError: getAll is not defined
 at HTMLButtonElement.onclick (testt.html:96)
onclick @ @ testt.html:96
testt.html:145 
Uncaught ReferenceError: screenfull is not defined
 at HTMLDivElement.<anonymous> (testt.html:145)
(anonymous) @ testt.html:145

EDITED After After Nina ́s answer i get the desired result but the homepage looks like this:

[The result][2]

So it distorts the upper part of my homepage. [1]: https://drive.google.com/open?id=0ByjbQDEh-nyvWHdkSmNsMElIaVU [2]: https://i.sstatic.net/IST0A.png

I am trying to switch from a very basic webpage into anthor one but i face some issues with the result once i click on getAll

[Check My new webpage][1]

My previous webpage (the wroking one )

<html>
<head>
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
</head>
<body>
 <button onclick="getAll()"> Get All The Users </button>
 <div id="users"></div>
 <script>
 function getAll()
 
 {
 $("#users").html("");
 
 
 
 $.getJSON("http://localhost:8080/users", function(data)
 {
 for (var i in data) {
 $('#users').append("<p>ID: " + data[i].id + "</p>")
 $('#users').append("<p>First name: " + data[i].fname + "</p>")
 $('#users').append("<p>Last name: " + data[i].lname + "</p><br>")
 }
 }); 
 
 }
 
 </script>
</body>
</html>

Here is the error:

Uncaught ReferenceError: getAll is not defined
 at HTMLButtonElement.onclick (testt.html:96)
onclick @ @ testt.html:96
testt.html:145 
Uncaught ReferenceError: screenfull is not defined
 at HTMLDivElement.<anonymous> (testt.html:145)
(anonymous) @ testt.html:145

EDITED After Nina ́s answer i get the desired result but the homepage looks like this:

[The result][2]

So it distorts the upper part of my homepage. [1]: https://drive.google.com/open?id=0ByjbQDEh-nyvWHdkSmNsMElIaVU [2]: https://i.sstatic.net/IST0A.png

I am trying to switch from a very basic webpage into anthor one but i face some issues with the result once i click on getAll

My previous webpage (the wroking one )

<html>
<head>
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
</head>
<body>
 <button onclick="getAll()"> Get All The Users </button>
 <div id="users"></div>
 <script>
 function getAll()
 
 {
 $("#users").html("");
 
 
 
 $.getJSON("http://localhost:8080/users", function(data)
 {
 for (var i in data) {
 $('#users').append("<p>ID: " + data[i].id + "</p>")
 $('#users').append("<p>First name: " + data[i].fname + "</p>")
 $('#users').append("<p>Last name: " + data[i].lname + "</p><br>")
 }
 }); 
 
 }
 
 </script>
</body>
</html>

Here is the error:

Uncaught ReferenceError: getAll is not defined
 at HTMLButtonElement.onclick (testt.html:96)
onclick @ @ testt.html:96
testt.html:145 
Uncaught ReferenceError: screenfull is not defined
 at HTMLDivElement.<anonymous> (testt.html:145)
(anonymous) @ testt.html:145

EDITED After Nina ́s answer i get the desired result but the homepage looks like this:

[The result][2]

So it distorts the upper part of my homepage. [2]: https://i.sstatic.net/IST0A.png

added 194 characters in body; added 11 characters in body
Source Link

I am trying to switch from a very basic webpage into anthor one but i face some issues with the result once i click on getAll

Check My new webpage [Check My new webpage][1]

My previous webpage (the wroking one )

<html>
<head>
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
</head>
<body>
 <button onclick="getAll()"> Get All The Users </button>
 <div id="users"></div>
 <script>
 function getAll()
 
 {
 $("#users").html("");
 
 
 
 $.getJSON("http://localhost:8080/users", function(data)
 {
 for (var i in data) {
 $('#users').append("<p>ID: " + data[i].id + "</p>")
 $('#users').append("<p>First name: " + data[i].fname + "</p>")
 $('#users').append("<p>Last name: " + data[i].lname + "</p><br>")
 }
 }); 
 
 }
 
 </script>
</body>
</html>

Here is the error:

Uncaught ReferenceError: getAll is not defined
 at HTMLButtonElement.onclick (testt.html:96)
onclick @ @ testt.html:96
testt.html:145 
Uncaught ReferenceError: screenfull is not defined
 at HTMLDivElement.<anonymous> (testt.html:145)
(anonymous) @ testt.html:145

EDITED After Nina ́s answer i get the desired result but the homepage looks like this:

[The result][2]

So it distorts the upper part of my homepage. [1]: https://drive.google.com/open?id=0ByjbQDEh-nyvWHdkSmNsMElIaVU [2]: https://i.sstatic.net/IST0A.png

I am trying to switch from a very basic webpage into anthor one but i face some issues with the result once i click on getAll

Check My new webpage

My previous webpage (the wroking one )

<html>
<head>
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
</head>
<body>
 <button onclick="getAll()"> Get All The Users </button>
 <div id="users"></div>
 <script>
 function getAll()
 
 {
 $("#users").html("");
 
 
 
 $.getJSON("http://localhost:8080/users", function(data)
 {
 for (var i in data) {
 $('#users').append("<p>ID: " + data[i].id + "</p>")
 $('#users').append("<p>First name: " + data[i].fname + "</p>")
 $('#users').append("<p>Last name: " + data[i].lname + "</p><br>")
 }
 }); 
 
 }
 
 </script>
</body>
</html>

Here is the error:

Uncaught ReferenceError: getAll is not defined
 at HTMLButtonElement.onclick (testt.html:96)
onclick @ @ testt.html:96
testt.html:145 
Uncaught ReferenceError: screenfull is not defined
 at HTMLDivElement.<anonymous> (testt.html:145)
(anonymous) @ testt.html:145

I am trying to switch from a very basic webpage into anthor one but i face some issues with the result once i click on getAll

[Check My new webpage][1]

My previous webpage (the wroking one )

<html>
<head>
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
</head>
<body>
 <button onclick="getAll()"> Get All The Users </button>
 <div id="users"></div>
 <script>
 function getAll()
 
 {
 $("#users").html("");
 
 
 
 $.getJSON("http://localhost:8080/users", function(data)
 {
 for (var i in data) {
 $('#users').append("<p>ID: " + data[i].id + "</p>")
 $('#users').append("<p>First name: " + data[i].fname + "</p>")
 $('#users').append("<p>Last name: " + data[i].lname + "</p><br>")
 }
 }); 
 
 }
 
 </script>
</body>
</html>

Here is the error:

Uncaught ReferenceError: getAll is not defined
 at HTMLButtonElement.onclick (testt.html:96)
onclick @ @ testt.html:96
testt.html:145 
Uncaught ReferenceError: screenfull is not defined
 at HTMLDivElement.<anonymous> (testt.html:145)
(anonymous) @ testt.html:145

EDITED After Nina ́s answer i get the desired result but the homepage looks like this:

[The result][2]

So it distorts the upper part of my homepage. [1]: https://drive.google.com/open?id=0ByjbQDEh-nyvWHdkSmNsMElIaVU [2]: https://i.sstatic.net/IST0A.png

edited body
Source Link
Loading
Source Link
Loading
default

AltStyle によって変換されたページ (->オリジナル) /