Files
librespeed-speedtest/examples/example-singleServer-basic.html
T
sstidl e5f54fbd78 Release 5.3.0 (#587)
* Update README.md

Added simple manual instructions

* Link to docker documentation

* Add basic docker compose example

* add descriptive alt-text to GIF

* Fix some typos and formatting

* Updated Docker to use php8.2-apache as the upstream image.

* Clean up apt lists after installation in Dockerfile

* Update Dockerfile

Co-authored-by: Quentame <[email protected]>

* fix typo

* doc: sqlite db persistance explained

* Create docker-publish.yml

* Update docker-publish.yml

* Update docker-publish.yml

* fix action

* switch docker image location

* without image signing

* remove signing

* switch units to Mbit/s

* move examples to folder

* fix ipinfo parsing

* fix regression on getIpinfo

* removed trailing whitespaces

* integrate ios favicon

closes #400

* set single-server-full as index

---------

Co-authored-by: Les W <[email protected]>
Co-authored-by: bt90 <[email protected]>
Co-authored-by: An | Anton Röhm <[email protected]>
Co-authored-by: 0kyn <[email protected]>
Co-authored-by: Marc Zampetti <[email protected]>
Co-authored-by: Peter Dave Hello <[email protected]>
Co-authored-by: Quentame <[email protected]>
Co-authored-by: Stefan STIDL <[email protected]>
2023-11-26 12:46:27 +01:00

39 lines
1.1 KiB
HTML
Executable File

<!DOCTYPE html>
<html>
<meta charset="UTF-8" />
<head>
<title>LibreSpeed Example</title>
<link rel="shortcut icon" href="favicon.ico">
</head>
<script type="text/javascript" src="speedtest.js"></script>
<body>
<h1>LibreSpeed Example</h1>
<h4>IP Address</h4>
<p id="ip"></p>
<h4>Download</h4>
<p id="download"></p>
<h4>Upload</h4>
<p id="upload"></p>
<h4>Latency</h4>
<p id="ping"></p>
<script type="text/javascript">
var s=new Speedtest();
s.onupdate = function (data) { // when status is received, put the values in the appropriate fields
document.getElementById('download').textContent = data.dlStatus + ' Mbit/s'
document.getElementById('upload').textContent = data.ulStatus + ' Mbit/s'
document.getElementById('ping').textContent = data.pingStatus + ' ms, ' + data.jitterStatus + ' ms jitter'
document.getElementById('ip').textContent = data.clientIp
}
s.start(); // start the speed test with default settings
</script>
<a href="https://github.com/librespeed/speedtest">Source code</a>
</body>
</html>