Skip to content

Commit

Permalink
Plex Changes
Browse files Browse the repository at this point in the history
  • Loading branch information
elit3ge committed Dec 21, 2015
1 parent 948c0f4 commit 8e58466
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 11 deletions.
5 changes: 3 additions & 2 deletions plex-movies.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,18 @@

include 'config.php';
include 'header.php';
echo "<center>";
include 'plex-header.php';

echo "<title>PlexMovies | ".$site_name."</title>";

$url = $plex_ip."/library/sections/".$plex_mov."/all";
$achxml = simplexml_load_file($url);
echo "<h1>PlexMovies</h1>";
echo "<h1>PlexMovies</h1><br>";
foreach($achxml->Video AS $child) {
echo "<a href='plex-movies-data.php?movieid=".$child['ratingKey']."'>".$child['title']."</a><br>";
}

include 'footer.php';

echo "</center>";
?>
1 change: 0 additions & 1 deletion plex-ondeck.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<?php


// Settings

include 'config.php';
Expand Down
4 changes: 3 additions & 1 deletion plex-radded.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@

include 'config.php';
include 'header.php';
echo "<center>";
include 'plex-header.php';
echo "</center>";

$url = $plex_ip."/library/recentlyAdded";
$achxml = simplexml_load_file($url);

echo "<title> Plex Recently Added | ".$site_name."</title>";
echo "<h1>Plex Recently Added</h1>";
echo "<h1>Plex Recently Added</h1><br>";

echo "<b>Shows</b><br>";
foreach($achxml->Directory AS $child) {
Expand Down
4 changes: 3 additions & 1 deletion plex-shows-eps.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,16 @@

include 'config.php';
include 'header.php';
echo "<center>";
include 'plex-header.php';
echo "</center>";

$epid = $_GET['epid'];

$url = $plex_ip."/library/metadata/".$epid."/children";
$achxml = simplexml_load_file($url);
echo "<title>".$achxml['title1']." | ".$achxml['title2']." | ".$site_name."</title>";
echo "<h1>".$achxml['title1']." | ".$achxml['title2']."</h1>";
echo "<h1>".$achxml['title1']." | ".$achxml['title2']."</h1><br>";
foreach($achxml AS $child) {
//echo "<h1>".$child['title']."</h1>";
echo "<b>Episode:</b> ".$child['index']."<br>";
Expand Down
9 changes: 5 additions & 4 deletions plex-shows-season.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,22 @@

include 'config.php';
include 'header.php';
echo "<center>";
include 'plex-header.php';

$showkey = $_GET['key'];

$url = $plex_ip."/library/metadata/".$showkey."/children";
$achxml = simplexml_load_file($url);
echo "<title>".$achxml['title2']." | ".$site_name."</title>";
echo "<h1>".$achxml['title2']."</h1>";
echo "<h1>".$achxml['title2']."</h1><br>";
foreach($achxml AS $child) {
if ($child['title'] == "All episodes")
{ echo "<a href='plex-shows-eps.php?epid=".$showkey."/allLeaves'>".$child['title']."</a><br>"; }
{ echo "<a href='plex-shows-eps.php?epid=".$showkey."/allLeaves'>".$child['title']."</a><br>"; }
else
{ echo "<a href='plex-shows-eps.php?epid=".$child['ratingKey']."'>".$child['title']."</a><br>"; }
{ echo "<a href='plex-shows-eps.php?epid=".$child['ratingKey']."'>".$child['title']."</a><br>"; }
}

echo "</center>";
include 'footer.php';

?>
5 changes: 3 additions & 2 deletions plex-shows.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,18 @@

include 'config.php';
include 'header.php';
echo "<center>";
include 'plex-header.php';

echo "<title>PlexShows | ".$site_name."</title>";

$url = $plex_ip."/library/sections/".$plex_tv."/all";
$achxml = simplexml_load_file($url);
echo "<h1>PlexShows</h1>";
echo "<h1>PlexShows</h1><br>";
foreach($achxml->Directory AS $child) {
echo "<a href='plex-shows-season.php?key=".$child['ratingKey']."'>".$child['title']."</a><br>";
}

echo "</center>";
include 'footer.php';

?>

0 comments on commit 8e58466

Please sign in to comment.