////
// Custom formatting of ../ autoindex.
//



    /** Amends the autoindex listing, generated by Apache.
      */
    function _amendListing()
    {
        var pre;
        for( var child = document.body.firstChild; child != null; child = child.nextSibling )
        {
            if( child.nodeType != /*element*/1 ) continue;

            if( child.tagName.toLowerCase() == 'pre' )
            {
                pre = child;
                break;
            }
        }
        if( !pre ) return;

        for( var child = pre.firstChild; child != null; child = child.nextSibling )
        {
            if( child.nodeType != /*element*/1 ) continue;

            if( child.tagName.toLowerCase() != 'a' ) continue;

         // var href = child.getAttribute( 'href' );
         //// but IE expands the href, so this is easier:
            var href = child.firstChild.data; // same thing, in these listings
            if(      href == 'a/' ) { appendInListingA( child, '  application' ); replaceAfterListingA( child, '        -  -   application code, Votorola specific' ); }
            else if( href == 'b/' ) { appendInListingA( child, '  build' ); replaceAfterListingA( child, '           -  -  -   build scripts' ); }
            else if( href == 'd/' ) { appendInListingA( child, '  domain' ); replaceAfterListingA( child, '          -  -  -   domain, decision making in the public sphere' ); }
            else if( href == 'g/' ) { appendInListingA( child, '  general' ); replaceAfterListingA( child, '         -  -  -   general code, other domains' ); }
            else if( href == 's/' ) { appendInListingA( child, '  system' ); replaceAfterListingA( child, '          -  -  -   system and site adminstration' ); }
            else if( href == 'home.xht' ) { appendInListingA( child, '                   <- start here' ); replaceAfterListingA( child, '' ); }
        }

    }



//////////////////////////////////////////////////////////////////////////////////////////


    _amendListing();
