-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5c7a7fc
commit 0c5206a
Showing
6 changed files
with
37 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>Admin Panel-Rooms</title> | ||
<?php require('inc/links.php')?> | ||
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN" crossorigin="anonymous"></script> | ||
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/umd/popper.min.js" integrity="sha384-ApNbgh9B+Y1QKtv3Rn7W3mgPxhU9K/ScQsAP7hUibX39j7fakFPskvXusvfa0b4Q" crossorigin="anonymous"></script> | ||
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.min.js" integrity="sha384-JZR6Spejh4U02d8jOt6vLEHfe/JQGiRRSQQxSfFWpi1MquVdAyjUar5+76PVCmYl" crossorigin="anonymous"></script> | ||
|
||
|
||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.4/jquery.min.js"></script> | ||
</head> | ||
<body> | ||
<?php require('inc/header.php')?> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,6 +14,9 @@ | |
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/umd/popper.min.js" integrity="sha384-ApNbgh9B+Y1QKtv3Rn7W3mgPxhU9K/ScQsAP7hUibX39j7fakFPskvXusvfa0b4Q" crossorigin="anonymous"></script> | ||
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.min.js" integrity="sha384-JZR6Spejh4U02d8jOt6vLEHfe/JQGiRRSQQxSfFWpi1MquVdAyjUar5+76PVCmYl" crossorigin="anonymous"></script> | ||
|
||
|
||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.4/jquery.min.js"></script> | ||
|
||
<style> | ||
#dashboard-bar{ | ||
position: fixed; | ||
|
@@ -86,9 +89,9 @@ | |
</div> | ||
|
||
<h6 class="card-subtitle mb-1 fw-bold">Site title</h6> | ||
<p class="card-text">content.</p> | ||
<p class="card-text" id="site-title">content.</p> | ||
<h6 class="card-subtitle mb-1 fw-bold">About Us</h6> | ||
<p class="card-text">content.</p> | ||
<p class="card-text" id="site-about">content.</p> | ||
</div> | ||
</div> | ||
</div> | ||
|
@@ -103,16 +106,19 @@ | |
|
||
function get_general(){ | ||
|
||
let site_title; | ||
let site_about; | ||
let site_title = document.getElementById('site-title'); | ||
let site_about = document.getElementById('site-about'); | ||
|
||
let xhr = new XMLHttpRequest(); | ||
xhr.open("POST","ajax/settings_crud.php",true); | ||
xhr.setRequestHeader('Content-Type','application/x-www-form-urlencoded'); | ||
|
||
xhr.onload =function(){ | ||
general_data = this.responseText; | ||
console.log(general_data); | ||
general_data = JSON.parse(xhr.responseText); | ||
// console.log(general_data); | ||
|
||
site_title.innerText = general_data.site_title; | ||
site_about.innerText = general_data.site_about; | ||
} | ||
|
||
xhr.send('get-general'); | ||
|