mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-10-29 18:00:23 +00:00
renamed some files and fixed broken link
This commit is contained in:
@@ -20,7 +20,7 @@
|
|||||||
|
|
||||||
<div class="playlist" >
|
<div class="playlist" >
|
||||||
<div id="buttons" class="result">
|
<div id="buttons" class="result">
|
||||||
<a href="admin.php" title="Channel settings" ><img src="/static/settings2.png" class="skip middle" alt="Settings"/></a>
|
<a href="php/admin.php" title="Channel settings" ><img src="/static/settings2.png" class="skip middle" alt="Settings"/></a>
|
||||||
<img src="/static/skip.png" class="skip" alt="Skip" title="Skip" onclick="skip();">
|
<img src="/static/skip.png" class="skip" alt="Skip" title="Skip" onclick="skip();">
|
||||||
</div>
|
</div>
|
||||||
<div id="playlist">
|
<div id="playlist">
|
||||||
|
|||||||
@@ -1,30 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
if(isset($_GET["pass"]) && $_GET["pass"]=="bæsj"){
|
|
||||||
|
|
||||||
include("change.php");
|
|
||||||
|
|
||||||
$dir = scandir('../lists');
|
|
||||||
$channels = array();
|
|
||||||
foreach($dir as $file){
|
|
||||||
if(strpos($file, '.json') !== FALSE){
|
|
||||||
$name='./lists/'.$file;
|
|
||||||
$data = json_decode(file_get_contents($name));
|
|
||||||
unlink($name);
|
|
||||||
checkFile($name); //should create a new file with correct stuff, in change
|
|
||||||
processList($data);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}else{
|
|
||||||
echo("kek");
|
|
||||||
}
|
|
||||||
|
|
||||||
function processList($list, $name){
|
|
||||||
foreach($list as $item){
|
|
||||||
//get id and title
|
|
||||||
addSong($name, $id, $title); //in change
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
?>
|
|
||||||
@@ -4,11 +4,11 @@
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<?php
|
<?php
|
||||||
$files = scandir('oldFiles/');
|
$files = scandir('../oldFiles/');
|
||||||
foreach($files as $list) {
|
foreach($files as $list) {
|
||||||
if($list != "." && $list != "..")
|
if($list != "." && $list != "..")
|
||||||
{
|
{
|
||||||
$file = file_get_contents("oldFiles/".$list);
|
$file = file_get_contents("../oldFiles/".$list);
|
||||||
$data = json_decode($file);
|
$data = json_decode($file);
|
||||||
if(count($data) > 0)
|
if(count($data) > 0)
|
||||||
{
|
{
|
||||||
@@ -27,7 +27,7 @@
|
|||||||
array_shift($data[0]);
|
array_shift($data[0]);
|
||||||
array_shift($data[3]);
|
array_shift($data[3]);
|
||||||
}
|
}
|
||||||
file_put_contents("oldFiles/".$list, json_encode($array));
|
file_put_contents("../oldFiles/".$list, json_encode($array));
|
||||||
echo $list."\n";
|
echo $list."\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user