All pastes #50429 Raw Edit

Unnamed

public text v1 · immutable
#50429 ·published 2006-04-21 15:33 UTC
rendered paste body
WEBSITE_DIR=$(echo ${SERVER_NAME#www.})
PAGE_DIR=$(dirname $SCRIPT_NAME)
FIXED_PAGE_DIR=$(basename $PAGE_DIR)
PAGE_NAME=$(basename ${SCRIPT_NAME%.html})
TEMPLATE_DIR="/var/www/$WEBSITE_DIR/template"

CSS_DIR="/css"
IMAGE_DIR="/Images"


#       This below is not a true breadcrumb trail and didn't look good, so therefore i commented it out-jz
#       echo "<a href="$SERVER_NAME">ISTS Mid Congress</a> >>  <a href="$PAGE_NAME.html">$PAGE_NAME</a>"

#This code generates the navigation menu


COL1=$(
ls $PAGE_NAME/../*.html | {
while read i
do
        let navcounter++
        if [ $navcounter -gt 15 ]; then
                break
        else
                href=$(echo ${i##$PAGE_NAME/} | sed -e "s/ /-/g" | sed -e "s/.html//g")
                link=$(echo $href | sed "s/-/ /g")

if ["$link" != "index"]; then
     echo "<div class=\"navbar_item\"><a href=\"$i\">$link</a></div>"
fi


       fi
done
})