Greasy Fork is available in English.

Supercharged Local Directory File Browser

Makes directory index pages (either local or remote open directories) actually useful. Adds sidebar and content preview pane; keyboard navigation; sorting; light/dark UI; preview images/fonts in navigable grids; browse subdirectories w/o page reload (“tree view”); media playback, shuffle/loop options; basic playlist (m3u, extm3u) & cuesheet (.cue) support; create, edit, preview, save markdown/plain text files; open font files, view complete glyph repertoire, save glyphs as .svg; more.

< Feedback on Supercharged Local Directory File Browser

Review: OK - script works, but has bugs

§
Posted: 23 November 2018

Can you add support for websites that have Index of... too?

Currently I've wrapped the script in this if statement to check whether if the current page is an Index of... page or not.

if (document.getElementsByTagName('h1')[0].textContent.search('Index of') != -1 && document.getElementsByTagName('title')[0].textContent.search('Index of') != -1){ scripthere };

However if there was a better way to implement this, I would love it if the script is updated to include online Index of... sites (open directories).

gaspar_schottPembuat
§
Posted: 24 November 2018

Hello n0thing,

Can you give me an example of the kind of index page you're talking about? You can already use the script for many non-local directory pages: you just have to add the URL in an @include line at the top of the script (this is typical for all userscripts). If you're not sure how to do that, you'd typically write something like // @include mywebsite.com/directory (The asterisks are "wildcard" characters.) If the script still doesn't work for that site, it may well be that the specific index format is not (yet) supported. Let me know.

—gaspar_schott

§
Posted: 22 Januari 2019
Edited: 22 Januari 2019

Sorry for the late reply, must have missed the notification.

I didn't think to use @include because I wanted it to support "Index of..." sites, such as sh.locker.phinugamma.org/swf/ or f3.to/mbap/images/ so I added the if statement around your script so it will automatically work whenever it detects an "Index of..." site.

Post reply

Sign in to post a reply.