$thebase .= (substr($thebase, -1) eq '/') ? 'default' : '/default';