Merge branch 'master' of http://kithub.ml/karl/Klanding
This commit is contained in:
commit
2110960dc4
30
MediaStatus.php
Normal file
30
MediaStatus.php
Normal file
@ -0,0 +1,30 @@
|
||||
<?php
|
||||
include 'config.php';
|
||||
if ($cpadultsvisible > "0") {
|
||||
$CPAdults = json_decode(file_get_contents("http://$base:$cpadults/api/$CPAdultsAPI/movie.list/?limit_offset=1"), TRUE);
|
||||
}
|
||||
if ($cpkidsvisible > "0") {
|
||||
$CPKids = json_decode(file_get_contents("http://$base:$cpkids/api/$CPKidsAPI/movie.list/?limit_offset=1"), TRUE);
|
||||
}
|
||||
if ($sickvisible > "0") {
|
||||
$SickBeard = json_decode(file_get_contents("http://$base:$sickport/api/$SICKAPI/?cmd=shows.stats"), TRUE);
|
||||
}
|
||||
|
||||
if ($sickvisible > "0") {
|
||||
echo " | ";
|
||||
echo "TV Shows: "; echo $SickBeard["data"]["shows_total"];
|
||||
echo " | ";
|
||||
echo "Episodes: "; echo $SickBeard["data"]["ep_total"];
|
||||
echo " | ";
|
||||
}
|
||||
if ($cpadultsvisible > "0") {
|
||||
echo "Adult Movies: "; echo $CPAdults["total"];
|
||||
echo " | ";
|
||||
}
|
||||
if ($cpkidsvisible > "0") {
|
||||
echo "Kids Movies: "; echo $CPKids["total"];
|
||||
echo " | ";
|
||||
}
|
||||
?>
|
||||
|
||||
|
21
Update.bat
21
Update.bat
@ -277,6 +277,27 @@ findstr "widgetcolour" config.php >nul 2>&1
|
||||
goto END
|
||||
:END
|
||||
|
||||
rem API
|
||||
findstr "API" config.php >nul 2>&1
|
||||
if errorlevel 1 goto ONE
|
||||
if errorlevel 0 goto ZERO
|
||||
goto END
|
||||
:ZERO
|
||||
echo APIs Already Updated
|
||||
goto END
|
||||
:ONE
|
||||
echo ^<?php >>config.php
|
||||
echo //// MediaStatus >> config.php
|
||||
echo $MStatusEnabled = "0"; >> config.php
|
||||
echo $SICKAPI = ""; >> config.php
|
||||
echo $CPAdultsAPI = ""; >> config.php
|
||||
echo $CPKidsAPI = ""; >> config.php
|
||||
echo //// >> config.php
|
||||
echo ^?^> >> config.php
|
||||
echo APIs Updated
|
||||
goto END
|
||||
:END
|
||||
|
||||
|
||||
rem Update Version
|
||||
findstr "localversion" config.php >nul 2>&1
|
||||
|
@ -36,6 +36,7 @@
|
||||
Konvos Widget Enabled: <input name="konvosvisible" id="id" type="checkbox" <?php if($konvosvisible > "0") echo "checked=checked; "; ?> /><br />
|
||||
<br />
|
||||
Enable Kodi (MovieLib): <input name="kodivisible" id="id" type="checkbox" <?php if($kodivisible > "0") echo "checked=checked; "; ?> /><br />
|
||||
Kodi Libary Stats: <input name="MStatusEnabled" id="id" type="checkbox" <?php if($MStatusEnabled > "0") echo "checked=checked; "; ?> /><br />
|
||||
<br />
|
||||
Show Version : <input name="showversion" id="id" type="checkbox" <?php if($showversion > "0") echo "checked=checked; "; ?> /> (<?php echo $localversion ?>)<br />
|
||||
<br />
|
||||
|
@ -48,6 +48,7 @@ global $sabpicname;
|
||||
Sick Type : <input type="radio" name="sicktype" value="1" <?php if($sicktype < "2") echo "checked=checked; "; ?>>SickBeard / <input type="radio" name="sicktype" value="2" <?php if($sicktype > "1") echo "checked=checked; "; ?>>SickRage<br />
|
||||
Sick Port: <input type="text" value="<?php echo $sickport ?>" name="sickport" /><br />
|
||||
Sick Name: <input type="text" value="<?php echo $sickname ?>" name="sickname" /><br />
|
||||
Sick API: <input type="text" value="<?php echo $SICKAPI ?>" name="SICKAPI" /><br />
|
||||
Sick Pic:<?php
|
||||
|
||||
echo '<select name="sickpic">'."\n".
|
||||
@ -68,12 +69,14 @@ global $sickpicname;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
</div>
|
||||
<div style="float:right; width:50%; ">
|
||||
Couch Enabled: <input name="couchvisible" id="id" type="checkbox" <?php if($couchvisible > "0") echo "checked=checked; "; ?> /><br />
|
||||
Couch Adults : <input type="radio" name="cpadultsvisible" value="1" <?php if($cpadultsvisible > "0") echo "checked=checked; "; ?>>Enabled / <input type="radio" name="cpadultsvisible" value="2" <?php if($cpadultsvisible < "1") echo "checked=checked; "; ?>>Disabled<br />
|
||||
Couch Adults Port: <input type="text" value="<?php echo $cpadults ?>" name="cpadults" /><br />
|
||||
Couch Adults Name: <input type="text" value="<?php echo $cpadultsname ?>" name="cpadultsname" /><br />
|
||||
Couch Adults API: <input type="text" value="<?php echo $CPAdultsAPI ?>" name="CPAdultsAPI" /><br />
|
||||
Couch Adults Pic: <?php
|
||||
|
||||
echo '<select name="cpapic">'."\n".
|
||||
@ -97,6 +100,7 @@ global $cpadultspicname;
|
||||
Couch Kids : <input type="radio" name="cpkidsvisible" value="1" <?php if($cpkidsvisible > "0") echo "checked=checked; "; ?>>Enabled / <input type="radio" name="cpkidsvisible" value="2" <?php if($cpkidsvisible < "1") echo "checked=checked; "; ?>>Disabled<br />
|
||||
Couch Kids Port: <input type="text" value="<?php echo $cpkids ?>" name="cpkids" /><br />
|
||||
Couch Kids Name: <input type="text" value="<?php echo $cpkidsname ?>" name="cpkidsname" /><br />
|
||||
Couch Kids API: <input type="text" value="<?php echo $CPKidsAPI ?>" name="CPKidsAPI" /><br />
|
||||
Couch Kids Pic: <?php
|
||||
|
||||
echo '<select name="cpkpic">'."\n".
|
||||
|
@ -17,6 +17,7 @@ $customwidgetbackgroud1 = $_POST['customwidget'];
|
||||
$widgetbackgroudcolour1 = $_POST['widgetbackgroudcolour'];
|
||||
$KWorldEnabled1 = $_POST['kworldenabled'];
|
||||
$widgetcolor1 = $_POST['widgetcolor'];
|
||||
$MStatusEnabled1 = $_POST['MStatusEnabled'];
|
||||
|
||||
//
|
||||
$fl='../config.php';
|
||||
@ -73,6 +74,12 @@ $content = preg_replace( '/\$widgetcolour = \"(.*?)\";/', '$widgetcolour = "#'
|
||||
} else {
|
||||
$content = preg_replace( '/\$kodivisible = \"(.*?)\";/', '$kodivisible = "1";', $content);
|
||||
}
|
||||
// mediaStatus Settings
|
||||
if (empty($MStatusEnabled1)) {
|
||||
$content = preg_replace( '/\$MStatusEnabled = \"(.*?)\";/', '$MStatusEnabled = "0";', $content);
|
||||
} else {
|
||||
$content = preg_replace( '/\$MStatusEnabled = \"(.*?)\";/', '$MStatusEnabled = "1";', $content);
|
||||
}
|
||||
// Widget Config
|
||||
if (empty($widgetbackgroud1)) {
|
||||
$content = preg_replace( '/\$widgetbackgroud = \"(.*?)\";/', '$widgetbackgroud = "0";', $content);
|
||||
|
@ -17,6 +17,9 @@ $cpkidsvisible1 = $_POST['cpkidsvisible'];
|
||||
$cpkidsname1 = $_POST['cpkidsname'];
|
||||
$cpkidspicname1 = $_POST['cpkpic'];
|
||||
$cpkids1 = $_POST['cpkids'];
|
||||
$SICKAPI1 = $_POST['SICKAPI'];
|
||||
$CPAdultsAPI1 = $_POST['CPAdultsAPI'];
|
||||
$CPKidsAPI1 = $_POST['CPKidsAPI'];
|
||||
//
|
||||
$fl='../config.php';
|
||||
/*read operation ->*/ $tmp = fopen($fl, "r"); $content=fread($tmp,filesize($fl)); fclose($tmp);
|
||||
@ -49,6 +52,7 @@ if ($sicktype1 > "1") {
|
||||
}
|
||||
$content = preg_replace( '/\$sickport = \"(.*?)\";/', '$sickport = "'.$sickport1.'";', $content);
|
||||
$content = preg_replace( '/\$sickname = \"(.*?)\";/', '$sickname = "'.$sickname1.'";', $content);
|
||||
$content = preg_replace( '/\$SICKAPI = \"(.*?)\";/', '$SICKAPI = "'.$SICKAPI1.'";', $content);
|
||||
$content = preg_replace( '/\$sickpicname = \"(.*?)\";/', '$sickpicname = "'.$sickpicname1.'";', $content);
|
||||
// End of Sick Settigns
|
||||
|
||||
@ -66,6 +70,7 @@ if ($cpadultsvisible1 > "1") {
|
||||
$content = preg_replace( '/\$cpadultsvisible = \"(.*?)\";/', '$cpadultsvisible = "1";', $content);
|
||||
}
|
||||
$content = preg_replace( '/\$cpadultsname = \"(.*?)\";/', '$cpadultsname = "'.$cpadultsname1.'";', $content);
|
||||
$content = preg_replace( '/\$CPAdultsAPI = \"(.*?)\";/', '$CPAdultsAPI = "'.$CPAdultsAPI1.'";', $content);
|
||||
$content = preg_replace( '/\$cpadultspicname = \"(.*?)\";/', '$cpadultspicname = "'.$cpadultspicname1.'";', $content);
|
||||
$content = preg_replace( '/\$cpadults = \"(.*?)\";/', '$cpadults = "'.$cpadults1.'";', $content);
|
||||
// CPKids Visible Update
|
||||
@ -75,6 +80,7 @@ if ($cpkidsvisible1 > "1") {
|
||||
$content = preg_replace( '/\$cpkidsvisible = \"(.*?)\";/', '$cpkidsvisible = "1";', $content);
|
||||
}
|
||||
$content = preg_replace( '/\$cpkidsname = \"(.*?)\";/', '$cpkidsname = "'.$cpkidsname1.'";', $content);
|
||||
$content = preg_replace( '/\$CPKidsAPI = \"(.*?)\";/', '$CPKidsAPI = "'.$CPKidsAPI1.'";', $content);
|
||||
$content = preg_replace( '/\$cpkidspicname = \"(.*?)\";/', '$cpkidspicname = "'.$cpkidspicname1.'";', $content);
|
||||
$content = preg_replace( '/\$cpkids = \"(.*?)\";/', '$cpkids = "'.$cpkids1.'";', $content);
|
||||
// End of Couch Settigns
|
||||
|
@ -9,5 +9,14 @@ tr { background-color:<?php echo $widgetcolour; ?>;
|
||||
|
||||
}
|
||||
|
||||
#stats {
|
||||
position: fixed;
|
||||
bottom: 0;
|
||||
font-size: 14pt;
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
color: black;
|
||||
background-color: lightblue;
|
||||
}
|
||||
</style>
|
||||
|
||||
|
43
feeds/SickBeard.php
Normal file
43
feeds/SickBeard.php
Normal file
@ -0,0 +1,43 @@
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" type="text/css" href="../css/white.css" />
|
||||
<link rel="stylesheet" type="text/css" href="../css/static.php" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="black" href="../css/black.css" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="white" href="../css/white.css" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="blue" href="../css/blue.css" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="red" href="../css/red.css" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="custom" href="../css/custom.php" />
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.js" type="text/javascript"></script>
|
||||
<style>
|
||||
.hiddenRow { display: none; }
|
||||
</style>
|
||||
<script>
|
||||
function toggleNextRow(row) {
|
||||
var nextRow = $(row).next();
|
||||
nextRow.toggle();
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<table width='275' border='0' cellspacing='0' cellpadding='0'>
|
||||
<tr onclick="toggleNextRow(this)" >
|
||||
<th style='text-align: left;'><font color='white'>Coming Episodes</font></th>
|
||||
</tr>
|
||||
<tr class="hiddenRow">
|
||||
<td bgcolor='#FFFFFF'>
|
||||
<?php
|
||||
include '../config.php';
|
||||
$Sick = json_decode(file_get_contents("http://$base:$sickport/api/$SICKAPI/?cmd=future&sort=date"), TRUE);
|
||||
echo $Sick["data"]["today"][2]["data_show_name"];
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
</form>
|
||||
</td>
|
||||
</table>
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
||||
|
||||
|
10
main.php
10
main.php
@ -8,6 +8,7 @@
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="blue" href="css/blue.css" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="red" href="css/red.css" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="custom" href="css/custom.php" />
|
||||
<link rel="stylesheet" type="text/css" media="screen" href="css/static.php" />
|
||||
<link rel="stylesheet" type="text/css" media="screen" href="css/converse.min.css">
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
|
||||
<script src="builds/converse.min.js"></script>
|
||||
@ -192,7 +193,15 @@ if ($showversion > "0") {
|
||||
echo "<p style=\" text-align: center;\">Version - $localversion</p>";
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
<div id="stats">
|
||||
<?php
|
||||
if ($MStatusEnabled > "0") {
|
||||
include "MediaStatus.php";;
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
<div id="test-popup" class="white-popup mfp-hide">
|
||||
<p style="text-align: center;">
|
||||
@ -221,7 +230,6 @@ if ($konvoschat > "0") {
|
||||
require "konvoschat.php";
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
@ -4,7 +4,7 @@
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<link rel="stylesheet" type="text/css" href="css/white.css" />
|
||||
<link rel="stylesheet" type="text/css" href="../css/static.php" />
|
||||
<link rel="stylesheet" type="text/css" href="css/static.php" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="black" href="css/black.css" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="white" href="css/white.css" />
|
||||
<link rel="alternate stylesheet" type="text/css" media="screen" title="blue" href="css/blue.css" />
|
||||
|
Loading…
x
Reference in New Issue
Block a user