We don't want to have the DIV tag as part of the nest, so tuck the start
& end tags into the if $_GET location statements, so they only appear
with get-branch and never get injected into the tree
Instead of not showing perms span tags, show them with blank content
Due to format changes, we need to change the slice range to 28 and -7
If we are passing a zip target location, this needs to be trimmed to
avoid a double slash
Also, if we don't have an exclude value provided to make an array from,
use an empty array instead
Possibly because index.php is calling lib/settings.php and this in turn
is calling config.php from it's location. Most web servers know you're
calling from the same dir but maybe XAMPP is thinking config.php should
be included from the index.php location? Anyway, fixed with a more
specific path.
Detect if the finfo_open function is available and if not, grab the file
extension and compare against an array to work out accepted text based
and image based file types to know wether to open in editor or pop open
as an image
Reducing bytes in a number of places, plus also:
Switching back to previous match highlighter without image data URI, as
is it more visible
Only setting line class for current line if we haven't selected multiple
lines
No need to set node to nextSibling again, only once is needed
If condition is now else if and calling the get-tree.php script
subsequent times and only if we're opening
This means we fix the open/close dir problem and also reload the dir
each time we open
Now calling /latest-version which is a tidier URL and also passing user
version no to this
This URL now tracks usage via Google Analytics, so I can begin to get an
idea of which version nos users are on, geo data, overall usage etc
No longer using json_encode as it's not JSON encoded, instead splitting
on line breaks and grabbing first array value as the version no
Change onclick event by setting 2nd param to false so it doesn't reload
Broke setting of node.nextSibling down into 2 new items, may revise this
If we're due to load, pass that through to get-tree.php in the
fileControl iFrame to begin the process
Only include settings file if we don't have ICEcoder settings available
Need 4 x vars for fileCounts etc available here
Contain tree within DIV which we can get the innerHTML of later for
branch injection
Need .$location when determining if a dir or not and also as part of the
path
If it's a folder and we have a treeType of branch or branchReload, add
true as the 2nd param, false otherwise
If we have a location, we're branch injecting, so get the target DOM
elem, create a new UL, set the style of it, remove whatever UL may be
there before, take the DIV innerHTML with the UL and /UL tags chopped
off, make it the innerHTML of our UL and finally inject into the DOM at
the right position.
Boot user out if not logged in
If the treeType is branch or branchReload, scan the dir at the specific
location, sort into dir and files arrays, nat case sort them and merge.
This is then finalArray and can be used to create the UL list