Skip to content

Commit

Permalink
Merge pull request #276 from pi-hole/restructureFolders
Browse files Browse the repository at this point in the history
Restructure folders
  • Loading branch information
AzureMarker authored Dec 30, 2016
2 parents 4c074cf + 4cffd16 commit 72fcf54
Show file tree
Hide file tree
Showing 85 changed files with 177 additions and 186 deletions.
6 changes: 3 additions & 3 deletions api.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php
$api = true;
require "php/password.php";
require "php/auth.php";
require "scripts/pi-hole/php/password.php";
require "scripts/pi-hole/php/auth.php";

check_cors();

include('data.php');
include('scripts/pi-hole/php/data.php');
header('Content-type: application/json');

$data = array();
Expand Down
6 changes: 0 additions & 6 deletions bootstrap/css/bootstrap.min.css

This file was deleted.

7 changes: 0 additions & 7 deletions css/AdminLTE.min.css

This file was deleted.

4 changes: 0 additions & 4 deletions css/font-awesome-4.5.0/css/font-awesome.min.css

This file was deleted.

11 changes: 0 additions & 11 deletions css/ionicons-2.0.1/css/ionicons.min.css

This file was deleted.

6 changes: 3 additions & 3 deletions gravity.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
require "header.php";
require "scripts/pi-hole/php/header.php";
?>
<!-- Title -->
<div class="page-header">
Expand All @@ -20,8 +20,8 @@
<pre id="output" style="width: 100%; height: 100%;" hidden="true"></pre>

<?php
require "footer.php";
require "scripts/pi-hole/php/footer.php";
?>


<script src="js/pihole/gravity.js"></script>
<script src="scripts/pi-hole/js/gravity.js"></script>
6 changes: 2 additions & 4 deletions help.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
require "header.php";
require "scripts/pi-hole/php/header.php";

if(strlen($pwhash) > 0)
{
Expand Down Expand Up @@ -146,7 +146,5 @@
</div>

<?php
require "footer.php";
require "scripts/pi-hole/php/footer.php";
?>

<script src="js/pihole/help.js"></script>
6 changes: 3 additions & 3 deletions index.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
$indexpage = true;
require "header.php";
require "scripts/pi-hole/php/header.php";
?>
<!-- Small boxes (Stat box) -->
<div class="row">
Expand Down Expand Up @@ -213,7 +213,7 @@
<!-- /.row -->
<?php } ?>
<?php
require "footer.php";
require "scripts/pi-hole/php/footer.php";
?>

<script src="js/pihole/index.js"></script>
<script src="scripts/pi-hole/js/index.js"></script>
7 changes: 0 additions & 7 deletions js/pihole/help.js

This file was deleted.

6 changes: 3 additions & 3 deletions list.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
require "header.php";
require "scripts/pi-hole/php/header.php";

$list = $_GET['l'];

Expand Down Expand Up @@ -52,7 +52,7 @@ function getFullName() {
<ul class="list-group" id="list"></ul>

<?php
require "footer.php";
require "scripts/pi-hole/php/footer.php";
?>

<script src="js/pihole/list.js"></script>
<script src="scripts/pi-hole/js/list.js"></script>
6 changes: 3 additions & 3 deletions queries.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
require "header.php";
require "scripts/pi-hole/php/header.php";

// Generate CSRF token
if(empty($_SESSION['token'])) {
Expand Down Expand Up @@ -105,7 +105,7 @@
<!-- /.row -->

<?php
require "footer.php";
require "scripts/pi-hole/php/footer.php";
?>

<script src="js/pihole/queries.js"></script>
<script src="scripts/pi-hole/js/queries.js"></script>
6 changes: 3 additions & 3 deletions queryads.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
require "header.php";
require "scripts/pi-hole/php/header.php";
?>
<!-- Title -->
<div class="page-header">
Expand All @@ -18,8 +18,8 @@
<pre id="output" style="width: 100%; height: 100%;" hidden="true"></pre>

<?php
require "footer.php";
require "scripts/pi-hole/php/footer.php";
?>


<script src="js/pihole/queryads.js"></script>
<script src="scripts/pi-hole/js/queryads.js"></script>
File renamed without changes.
2 changes: 1 addition & 1 deletion js/pihole/gravity.js → scripts/pi-hole/js/gravity.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ function eventsource() {
var alInfo = $("#alInfo");
var alSuccess = $("#alSuccess");
var ta = $("#output");
var source = new EventSource("php/gravity.sh.php");
var source = new EventSource("scripts/pi-hole/php/gravity.sh.php");

ta.html("");
ta.show();
Expand Down
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions js/pihole/list.js → scripts/pi-hole/js/list.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ function sub(index, entry) {
var domain = $("#"+index);
domain.hide("highlight");
$.ajax({
url: "php/sub.php",
url: "scripts/pi-hole/php/sub.php",
method: "post",
data: {"domain":entry, "list":listType, "token":token},
success: function(response) {
Expand All @@ -31,7 +31,7 @@ function refresh(fade) {
list.fadeOut(100);
}
$.ajax({
url: "php/get.php",
url: "scripts/pi-hole/php/get.php",
method: "get",
data: {"list":listType},
success: function(response) {
Expand Down Expand Up @@ -78,7 +78,7 @@ function add() {
alSuccess.hide();
alFailure.hide();
$.ajax({
url: "php/add.php",
url: "scripts/pi-hole/php/add.php",
method: "post",
data: {"domain":domain.val(), "list":listType, "token":token},
success: function(response) {
Expand Down
2 changes: 1 addition & 1 deletion js/pihole/queries.js → scripts/pi-hole/js/queries.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ function add(domain,list) {
alSuccess.hide();
alFailure.hide();
$.ajax({
url: "php/add.php",
url: "scripts/pi-hole/php/add.php",
method: "post",
data: {"domain":domain, "list":list, "token":token},
success: function(response) {
Expand Down
2 changes: 1 addition & 1 deletion js/pihole/queryads.js → scripts/pi-hole/js/queryads.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ function eventsource() {
}

var host = window.location.host;
var source = new EventSource("http://"+host+"/admin/php/queryads.php?domain="+domain.val().toLowerCase()+"&"+exact);
var source = new EventSource("http://"+host+"/admin/scripts/pi-hole/php/queryads.php?domain="+domain.val().toLowerCase()+"&"+exact);

// Reset and show field
ta.empty();
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
16 changes: 8 additions & 8 deletions footer.php → scripts/pi-hole/php/footer.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,16 @@
</footer>
</div>
<!-- ./wrapper -->
<script src="js/other/jquery.min.js"></script>
<script src="js/other/jquery-ui.min.js"></script>
<script src="bootstrap/js/bootstrap.min.js"></script>
<script src="js/other/app.min.js"></script>
<script src="scripts/vendor/jquery.min.js"></script>
<script src="scripts/vendor/jquery-ui.min.js"></script>
<script src="style/vendor/bootstrap/js/bootstrap.min.js"></script>
<script src="scripts/vendor/app.min.js"></script>

<script src="js/other/jquery.dataTables.min.js"></script>
<script src="js/other/dataTables.bootstrap.min.js"></script>
<script src="js/other/Chart.bundle.min.js"></script>
<script src="scripts/vendor/jquery.dataTables.min.js"></script>
<script src="scripts/vendor/dataTables.bootstrap.min.js"></script>
<script src="scripts/vendor/Chart.bundle.min.js"></script>

<script src="js/pihole/footer.js"></script>
<script src="scripts/pi-hole/js/footer.js"></script>

</body>
</html>
File renamed without changes.
File renamed without changes.
File renamed without changes.
26 changes: 13 additions & 13 deletions header.php → scripts/pi-hole/php/header.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
require "php/auth.php";
require "php/password.php";
require "scripts/pi-hole/php/auth.php";
require "scripts/pi-hole/php/password.php";

check_cors();

Expand Down Expand Up @@ -142,34 +142,34 @@
<meta name="msapplication-TileImage" content="img/logo.svg">
<meta name="apple-mobile-web-app-capable" content="yes">

<link href="bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
<link href="css/font-awesome-4.5.0/css/font-awesome.min.css" rel="stylesheet" type="text/css" />
<link href="css/ionicons-2.0.1/css/ionicons.min.css" rel="stylesheet" type="text/css" />
<link href="css/dataTables.bootstrap.min.css" rel="stylesheet" type="text/css" />
<link href="style/vendor/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
<link href="style/vendor/font-awesome-4.5.0/css/font-awesome.min.css" rel="stylesheet" type="text/css" />
<link href="style/vendor/ionicons-2.0.1/css/ionicons.min.css" rel="stylesheet" type="text/css" />
<link href="style/vendor/dataTables.bootstrap.min.css" rel="stylesheet" type="text/css" />

<link href="css/AdminLTE.min.css" rel="stylesheet" type="text/css" />
<link href="css/skin-blue.min.css" rel="stylesheet" type="text/css" />
<link href="style/vendor/AdminLTE.min.css" rel="stylesheet" type="text/css" />
<link href="style/vendor/skin-blue.min.css" rel="stylesheet" type="text/css" />
<link rel="icon" type="image/png" sizes="160x160" href="img/logo.svg" />
<style type="text/css">
.glow { text-shadow: 0px 0px 5px #fff; }
h3 { transition-duration: 500ms }
</style>

<!--[if lt IE 9]>
<script src="js/other/html5shiv.min.js"></script>
<script src="js/other/respond.min.js"></script>
<script src="scripts/vendor/html5shiv.min.js"></script>
<script src="scripts/vendor/respond.min.js"></script>
<![endif]-->
</head>
<body class="skin-blue sidebar-mini <?php if($boxedlayout){ ?>layout-boxed<?php } ?>">
<!-- JS Warning -->
<div>
<link rel="stylesheet" type="text/css" href="css/js-warn.css">
<link rel="stylesheet" type="text/css" href="style/vendor/js-warn.css">
<input type="checkbox" id="js-hide" />
<div class="js-warn" id="js-warn-exit"><h1>Javascript Is Disabled</h1><p>Javascript seems to be disabled. This will break some site features.</p>
<p>To enable Javascript click <a href="http://www.enable-javascript.com/" target="_blank">here</a></p><label for="js-hide">Close</label></div>
</div>
<!-- /JS Warning -->
<script src="js/pihole/header.js"></script>
<script src="scripts/pi-hole/js/header.js"></script>
<!-- Send token to JS -->
<div id="token" hidden><?php echo $token ?></div>
<div class="wrapper">
Expand Down Expand Up @@ -489,7 +489,7 @@
// If auth is required and not set, i.e. no successfully logged in,
// we show the reduced version of the summary (index) page
if(!$auth && (!isset($indexpage) || isset($_GET['login']))){
require "php/loginpage.php";
require "scripts/pi-hole/php/loginpage.php";
require "footer.php";
exit();
}
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
14 changes: 7 additions & 7 deletions settings.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
require "header.php";
require "php/savesettings.php";
require "scripts/pi-hole/php/header.php";
require "scripts/pi-hole/php/savesettings.php";
// Reread ini file as things might have been changed
$setupVars = parse_ini_file("/etc/pihole/setupVars.conf");
?>
Expand Down Expand Up @@ -558,10 +558,10 @@
</div>

<?php
require "footer.php";
require "scripts/pi-hole/php/footer.php";
?>
<script src="js/other/jquery.inputmask.js"></script>
<script src="js/other/jquery.inputmask.extensions.js"></script>
<script src="js/other/jquery.confirm.min.js"></script>
<script src="js/pihole/settings.js"></script>
<script src="scripts/vendor/jquery.inputmask.js"></script>
<script src="scripts/vendor/jquery.inputmask.extensions.js"></script>
<script src="scripts/vendor/jquery.confirm.min.js"></script>
<script src="scripts/pi-hole/js/settings.js"></script>

7 changes: 7 additions & 0 deletions style/vendor/AdminLTE.min.css

Large diffs are not rendered by default.

Loading

0 comments on commit 72fcf54

Please sign in to comment.