generated from nathanwoodburn/python-webserver-template
parent
7bde6e7bd2
commit
3998e1cafc
@ -62,9 +62,6 @@ document.addEventListener('DOMContentLoaded', function() {
|
||||
<div class="card-header bg-success text-white py-3 d-flex justify-content-between align-items-center">
|
||||
<h3 class="h5 mb-0">Result for ${escapeHtml(url)}</h3>
|
||||
<div>
|
||||
<button class="btn btn-sm btn-light" id="refresh-iframe">
|
||||
<i class="bi bi-arrow-clockwise me-1"></i>Refresh
|
||||
</button>
|
||||
<button class="btn btn-sm btn-light ms-2" id="view-source">
|
||||
<i class="bi bi-code-slash me-1"></i>View Source
|
||||
</button>
|
||||
@ -79,7 +76,6 @@ document.addEventListener('DOMContentLoaded', function() {
|
||||
|
||||
// Get reference to the iframe and buttons
|
||||
const iframe = document.getElementById('result-iframe');
|
||||
const refreshButton = document.getElementById('refresh-iframe');
|
||||
const viewSourceButton = document.getElementById('view-source');
|
||||
|
||||
// Create a blob URL from the HTML content
|
||||
@ -89,12 +85,6 @@ document.addEventListener('DOMContentLoaded', function() {
|
||||
// Set the iframe src to the blob URL
|
||||
iframe.src = blobUrl;
|
||||
|
||||
// Add event listener to refresh button
|
||||
refreshButton.addEventListener('click', function() {
|
||||
// Reload the content
|
||||
handleCurlRequest(url);
|
||||
});
|
||||
|
||||
// Add event listener to view source button
|
||||
viewSourceButton.addEventListener('click', function() {
|
||||
// Show source code in a modal or new window
|
||||
|
@ -22,7 +22,7 @@ function getSSL() {
|
||||
history.pushState(null, null, url);
|
||||
|
||||
// Add a loading spinner
|
||||
document.getElementById("ssl-results").innerHTML = `<div style="text-align: center;">
|
||||
document.getElementById("ssl-results").innerHTML = `<div style="text-align: center; margin-bottom: 3rem;">
|
||||
<div class="spinner-border text-primary" role="status">
|
||||
<span class="visually-hidden">Loading...</span>
|
||||
</div></div>`;
|
||||
@ -36,7 +36,7 @@ function getSSL() {
|
||||
if (data.success) {
|
||||
// Display the results
|
||||
document.getElementById("ssl-results").innerHTML = `
|
||||
<div class="card shadow-sm p-4" style="max-width: 950px;margin: auto;">
|
||||
<div class="card shadow-sm p-4" style="max-width: 950px;margin: auto; margin-bottom: 3rem;">
|
||||
<h2 class="mb-3">SSL Certificate Details</h2>
|
||||
<ul class="list-group">
|
||||
<li class="list-group-item"><strong>IP Address:</strong> ${data.ip}</li>
|
||||
|
Loading…
Reference in New Issue
Block a user