# Plex Web Export

**URL:** <https://forums.plex.tv/t/plex-web-export/5807>\
**Category:** Dev/API Corner\
**Tags:** other-dev\
**Created:** [October 6, 2010, 11:36am UTC](https://forums.plex.tv/t/plex-web-export/5807 "2010-10-06T11:36:18Z")\
**Posts on this page:** 20\
**Page:** 3

<div class="post-metadata">

**Author:** ![Dachande663](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/dachande663/32/403_2.png) [@Dachande663](https://forums.plex.tv/u/Dachande663)\
**Post date:** [October 16, 2010, 7:41am UTC](https://forums.plex.tv/t/plex-web-export/5807/41 "2010-10-16T07:41:04Z")

</div>

> [@](#):
>
> I'm a total beginner but when I run the command line in terminal I get -bash: /Applications/plexexport/cli.php: Permission denied. What am I doing wrong?  
> Thanks in advance for the help.

  
  
@AdamH: Make sure you execute the file as PHP i.e. in Terminal type "php cli.php" (without the quotes) rather than just cli.php. Otherwise Terminal will attempt to execute the file as if it were a bash script.  
  
  

> [@](#):
>
> I get the following result when I run a command from Terminal on my laptop to the server (htpc). It almost wants to work, is this the wrong way to go about this? It runs fine when I run it on the server.  
> Fatal error: Call to undefined function imagecreatefromstring() in /Volumes/server/Documents/Plex/plexexport/cli.php on line 379

  
@daa: do you have GD enabled in PHP? To test, make a file on the server your using e.g. test.php, in it enter: \<?php phpinfo(); ?\>, and run it. If you scroll down there is a section entitled GD which will state whether it's enabled or not.

---

<div class="post-metadata">

**Author:** ![jernomer](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/jernomer/32/266_2.png) [@jernomer](https://forums.plex.tv/u/jernomer)\
**Post date:** [October 16, 2010, 3:22pm UTC](https://forums.plex.tv/t/plex-web-export/5807/42 "2010-10-16T15:22:46Z")

</div>

Wow, this is great.  
  
  
  
However, I cannot seem to figure out how to get the items in alphabetical order. They seem to be, for the most part, but there are a number of items that aren’t in order. I even noticed this in the TV Shows section of the preview link in the first post. The only pattern I can see is that a bunch of my newly added TV shows are showing up at the bottom of the list. Any ideas on what might be going on?  
  
  
  
EDIT: Also, one other thing. Is it possible to leave the tagline blank for TV shows if one isn’t present? Right now, all of my TV shows have the tagline of “undefined”.

---

<div class="post-metadata">

**Author:** ![Dachande663](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/dachande663/32/403_2.png) [@Dachande663](https://forums.plex.tv/u/Dachande663)\
**Post date:** [October 16, 2010, 3:59pm UTC](https://forums.plex.tv/t/plex-web-export/5807/43 "2010-10-16T15:59:38Z")

</div>

Hmm, taglines shouldn’t show up if undefined, I’ll fix that.  
  
  
  
As for sorting, it currently just spits them out as Plex API does. I’m hoping to add proper sorting at some point (name, year, rating etc)

---

<div class="post-metadata">

**Author:** ![jernomer](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/jernomer/32/266_2.png) [@jernomer](https://forums.plex.tv/u/jernomer)\
**Post date:** [October 16, 2010, 4:23pm UTC](https://forums.plex.tv/t/plex-web-export/5807/44 "2010-10-16T16:23:55Z")

</div>

> [@](#):
>
> Hmm, taglines shouldn't show up if undefined, I'll fix that.  
>   
> As for sorting, it currently just spits them out as Plex API does. I'm hoping to add proper sorting at some point (name, year, rating etc)

  
  
Thanks for the reply. Yeah, some kind of sorting would be great, or at least just alphabetical in the meantime.

---

<div class="post-metadata">

**Author:** ![mkh](https://avatars.discourse-cdn.com/v4/letter/m/4af34b/32.png) [@mkh](https://forums.plex.tv/u/mkh)\
**Post date:** [October 16, 2010, 5:02pm UTC](https://forums.plex.tv/t/plex-web-export/5807/45 "2010-10-16T17:02:04Z")

</div>

Dachande663 : Got a request…  
  
  
  
It would be AWSOME to have some sort of icon/label to show movies are in HD… (720 or 1080)  
  
  
  
The **info** line shows alot of info like the resolution, so if 720 is in this line show som ekind of info in the index page on top of the thumb created for the movie?  
  
  
  
(sorry my bad english, being drunk dont make it easyer…)  
  
  
  
  
  
In short, I want to add ALL my movies in 1 section and then be able to see which movies are HD… 😃  
  
  
  
  
  
/mkh

---

<div class="post-metadata">

**Author:** ![Dachande663](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/dachande663/32/403_2.png) [@Dachande663](https://forums.plex.tv/u/Dachande663)\
**Post date:** [October 16, 2010, 5:03pm UTC](https://forums.plex.tv/t/plex-web-export/5807/46 "2010-10-16T17:03:50Z")

</div>

@mkh I was trying to add the icons similar to the Plex client itself, may have have to resume that hunt.

---

<div class="post-metadata">

**Author:** ![mkh](https://avatars.discourse-cdn.com/v4/letter/m/4af34b/32.png) [@mkh](https://forums.plex.tv/u/mkh)\
**Post date:** [October 16, 2010, 5:10pm UTC](https://forums.plex.tv/t/plex-web-export/5807/47 "2010-10-16T17:10:52Z")

</div>

Yep, start hunting 😃  
  
  
  
  
  
In the end we (I) will get the perfect setup.  
  
  
  
  
  
Automatic Trailer download  
  
Automatic Backdrop download  
  
Automatic TV Show download  
  
Automatic TV Show rename  
  
Automatic Update of overall Plex Media Index page (which is, sorry plex team more usefull than the org one…)  
  
  
  
  
  
nufff said…

---

<div class="post-metadata">

**Author:** ![Dachande663](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/dachande663/32/403_2.png) [@Dachande663](https://forums.plex.tv/u/Dachande663)\
**Post date:** [October 17, 2010, 5:23pm UTC](https://forums.plex.tv/t/plex-web-export/5807/48 "2010-10-17T17:23:17Z")

</div>

Okay people, pushed out a big update today. You can now **sort collections**.  
  
  
  
At the moment you can sort by name, rating and release date. I might add more in future (such as file size) but have held off until I can work some more tweaks out of the Plex API. All the sorting is done in the initial export so it should be fairly quick when browsing. I’ve also tweaked a lot of other sections, especially live filtering, so it should be more responsive (and carry across sections).  
  
  
  
I’m working on fixing some bugs at the moment (a nasty file size one has popped up I can’t quite seem to nip) and adding extra data (such as AAC logos etc). As ever, let me know if you have any problems 🙂  
  
  
  
I’d also just like to say thank you to all those who I’ve been PMing to try and fix bugs, you’ve been brilliant helps!

---

<div class="post-metadata">

**Author:** ![xiocc](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/xiocc/32/1475_2.png) [@xiocc](https://forums.plex.tv/u/xiocc)\
**Post date:** [October 17, 2010, 6:42pm UTC](https://forums.plex.tv/t/plex-web-export/5807/49 "2010-10-17T18:42:08Z")

</div>

Awesome, thanks! Looks like it has been a nasty and rainy Sunday in the UK too 😉 Perfect for coding 😛

---

<div class="post-metadata">

**Author:** ![bam2000](https://avatars.discourse-cdn.com/v4/letter/b/858c86/32.png) [@bam2000](https://forums.plex.tv/u/bam2000)\
**Post date:** [October 17, 2010, 8:53pm UTC](https://forums.plex.tv/t/plex-web-export/5807/50 "2010-10-17T20:53:44Z")

</div>

hi,   
  
i have tried to install this, but i only get the message  
  
  
  
  
  
carsten-1:~ carsten$ php /Users/carsten/Downloads/plexexport/cli.php   
  
22:51:51 Welcome to the Plex Exporter v1  
  
22:51:51 Error: Data directory is not writeable  
  
22:51:51 Error: Failed one or more dependancy checks; aborting  
  
carsten-s-1:~ carsten$   
  
  
  
i have installed and activated php like in this tutorial ([http://www.sysadminslife.com/apple/mac-os-x-10-6-php-unter-snow-leopard-installieren/](http://www.sysadminslife.com/apple/mac-os-x-10-6-php-unter-snow-leopard-installieren/))  
  
and i have changed all permissions…  
  
  
  
what iam doing wrong ? ☹  
  
  
  
sorry for my bad english 🙂  
  
  
  
  
  
edit:  
  
oh my god, i really should read first ^^  
  
now its scanning, hope it finds anything =)  
  
  
  
  
  
edit again…  
  
  
  
  
  
22:56:28 Welcome to the Plex Exporter v1  
  
22:56:28 Searching for sections in the Plex library at [http://localhost:32400/](http://localhost:32400/)  
  
22:58:28 Error: The Plex library could not be found at [http://localhost:32400/](http://localhost:32400/)  
  
22:58:28 Error: Could not load section data, aborting  
  
  
  
  
  
please help.

---

<div class="post-metadata">

**Author:** ![Dachande663](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/dachande663/32/403_2.png) [@Dachande663](https://forums.plex.tv/u/Dachande663)\
**Post date:** [October 17, 2010, 8:59pm UTC](https://forums.plex.tv/t/plex-web-export/5807/51 "2010-10-17T20:59:09Z")

</div>

@bam2000 Hi, I’ve uploaded a new plexexport.zip file that fixes this bug. If you re-download and try again it should let you proceed. Sorry.

---

<div class="post-metadata">

**Author:** ![bam2000](https://avatars.discourse-cdn.com/v4/letter/b/858c86/32.png) [@bam2000](https://forums.plex.tv/u/bam2000)\
**Post date:** [October 17, 2010, 9:51pm UTC](https://forums.plex.tv/t/plex-web-export/5807/52 "2010-10-17T21:51:48Z")

</div>

ok great thanks 🙂  
  
  
  
its so awesome!  
  
  
  
hope you will ad more amazing new features, i really really like it.

---

<div class="post-metadata">

**Author:** ![jernomer](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/jernomer/32/266_2.png) [@jernomer](https://forums.plex.tv/u/jernomer)\
**Post date:** [October 18, 2010, 12:37am UTC](https://forums.plex.tv/t/plex-web-export/5807/53 "2010-10-18T00:37:34Z")

</div>

> [@](#):
>
> Okay people, pushed out a big update today. You can now \*\*sort collections\*\*.  
>   
> At the moment you can sort by name, rating and release date. I might add more in future (such as file size) but have held off until I can work some more tweaks out of the Plex API. All the sorting is done in the initial export so it should be fairly quick when browsing. I've also tweaked a lot of other sections, especially live filtering, so it should be more responsive (and carry across sections).  
>   
> I'm working on fixing some bugs at the moment (a nasty file size one has popped up I can't quite seem to nip) and adding extra data (such as AAC logos etc). As ever, let me know if you have any problems :)  
>   
> I'd also just like to say thank you to all those who I've been PMing to try and fix bugs, you've been brilliant helps!

  
  
Fantastic update! Thanks for getting all this together.

---

<div class="post-metadata">

**Author:** ![sandman4sure](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/sandman4sure/32/40_2.png) [@sandman4sure](https://forums.plex.tv/u/sandman4sure)\
**Post date:** [October 18, 2010, 10:52am UTC](https://forums.plex.tv/t/plex-web-export/5807/54 "2010-10-18T10:52:47Z")

</div>

Thanks for the great update!  
  
  
  
Small bug: not being able to search for movies using capitals, even if the movie has capitals in the name.  
  
  
  
Movie name: 16 Blocks  
  
Search:

- 16 blocks: works!  
- 16 Blocks: doesn’t find anything.

---

<div class="post-metadata">

**Author:** ![Dachande663](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/dachande663/32/403_2.png) [@Dachande663](https://forums.plex.tv/u/Dachande663)\
**Post date:** [October 18, 2010, 11:57am UTC](https://forums.plex.tv/t/plex-web-export/5807/55 "2010-10-18T11:57:32Z")

</div>

> [@](#):
>
> Thanks for the great update!  
>   
> Small bug: not being able to search for movies using capitals, even if the movie has capitals in the name.  
>   
> Movie name: 16 Blocks  
> Search:  
> - 16 blocks: works!  
> - 16 Blocks: doesn't find anything.

  
  
Added one line and fixed :) Unfortunately my Uni network doesn't allow remote access so I won't be able to upload the change until later tonight :(  
  
Edit: the new version has been uploaded.

---

<div class="post-metadata">

**Author:** ![AOZ801](https://avatars.discourse-cdn.com/v4/letter/a/d9b06d/32.png) [@AOZ801](https://forums.plex.tv/u/AOZ801)\
**Post date:** [October 18, 2010, 5:02pm UTC](https://forums.plex.tv/t/plex-web-export/5807/56 "2010-10-18T17:02:20Z")

</div>

> [@](#):
>
> @AdamH: Make sure you execute the file as PHP i.e. in Terminal type "php cli.php" (without the quotes) rather than just cli.php. Otherwise Terminal will attempt to execute the file as if it were a bash script.  
>   
>   
>   
> @daa: do you have GD enabled in PHP? To test, make a file on the server your using e.g. test.php, in it enter: \<?php phpinfo(); ?\>, and run it. If you scroll down there is a section entitled GD which will state whether it's enabled or not.

  
  
  
I can usually figure these things out but I have no coding or programing background so you will have to be patient this is what I'm getting in the Terminal /Applications/plexexport/php cli.php  
-bash: /Applications/plexexport/php: No such file or directory  
  
What am I doing wrong. I've enabled PHP.

---

<div class="post-metadata">

**Author:** ![Dachande663](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/dachande663/32/403_2.png) [@Dachande663](https://forums.plex.tv/u/Dachande663)\
**Post date:** [October 18, 2010, 9:54pm UTC](https://forums.plex.tv/t/plex-web-export/5807/57 "2010-10-18T21:54:00Z")

</div>

> [@](#):
>
> I can usually figure these things out but I have no coding or programing background so you will have to be patient this is what I'm getting in the Terminal /Applications/plexexport/php cli.php  
> -bash: /Applications/plexexport/php: No such file or directory  
>   
> What am I doing wrong. I've enabled PHP.

  
  
Try this:  
  
php /Applications/plexexport/cli.php  
  
This assumes plexexport is in your applications folder, if it's somewhere else then you must change the command accordingly. What the command does is tell php (the first part i.e. the program to run) to use the file supplied as the first argument (the path to the cli.php file).

---

<div class="post-metadata">

**Author:** ![Dachande663](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/dachande663/32/403_2.png) [@Dachande663](https://forums.plex.tv/u/Dachande663)\
**Post date:** [October 18, 2010, 11:23pm UTC](https://forums.plex.tv/t/plex-web-export/5807/58 "2010-10-18T23:23:23Z")

</div>

Okay, major update just pushed out. You can now **filter by genre**! I’ve had to refactor a lot of the code, but the genres for each collection now appear. You can also sort, filter and search all at the same time. As ever, download the new files, re-run the cli.php script and you should be good to go.

---

<div class="post-metadata">

**Author:** ![AOZ801](https://avatars.discourse-cdn.com/v4/letter/a/d9b06d/32.png) [@AOZ801](https://forums.plex.tv/u/AOZ801)\
**Post date:** [October 19, 2010, 4:16am UTC](https://forums.plex.tv/t/plex-web-export/5807/59 "2010-10-19T04:16:14Z")

</div>

> [@](#):
>
> Try this:  
>   
> php /Applications/plexexport/cli.php  
>   
> This assumes plexexport is in your applications folder, if it's somewhere else then you must change the command accordingly. What the command does is tell php (the first part i.e. the program to run) to use the file supplied as the first argument (the path to the cli.php file).

  
  
Dachande663   
  
Thanks for helping me.....this is what I'm getting php /Applications/plexexport/cli.php  
22:13:53 Welcome to the Plex Exporter v1  
22:13:53 Error: Data directory is not writeable  
22:13:53 Error: Failed one or more dependancy checks; aborting  
  
I've checked to make sure that I have plex-data file and that it's writeable via OSX sharing and it says it's writable? I'm at a loss. I'm sure this is something simple but it's sure giving me a hard time.

---

<div class="post-metadata">

**Author:** ![Dachande663](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/dachande663/32/403_2.png) [@Dachande663](https://forums.plex.tv/u/Dachande663)\
**Post date:** [October 19, 2010, 7:43am UTC](https://forums.plex.tv/t/plex-web-export/5807/60 "2010-10-19T07:43:37Z")

</div>

> [@](#):
>
> Dachande663   
>   
> Thanks for helping me.....this is what I'm getting php /Applications/plexexport/cli.php  
> 22:13:53 Welcome to the Plex Exporter v1  
> 22:13:53 Error: Data directory is not writeable  
> 22:13:53 Error: Failed one or more dependancy checks; aborting  
>   
> I've checked to make sure that I have plex-data file and that it's writeable via OSX sharing and it says it's writable? I'm at a loss. I'm sure this is something simple but it's sure giving me a hard time.

  
  
Two things, can you confirm there is a directory called plex-data located at /Applications/plexexport/plex-data (and not in your home folder say)?  
If so, have you downloaded the latest version of the exporter?

[Previous page](https://forums.plex.tv/t/plex-web-export/5807.md?page=2)

[Next page](https://forums.plex.tv/t/plex-web-export/5807.md?page=4)
