]> git.plutz.net Git - serve0/blobdiff - globals.sh
updates in shcgi
[serve0] / globals.sh
similarity index 97%
rename from constants.sh
rename to globals.sh
index 266f73430d6d636fc706368aeafd3dbd878e649f..1445d48e4efceaf049180bca1d1c6a27e24412cb 100755 (executable)
 # You should have received a copy of the GNU Affero General Public License
 # along with Serve0.  If not, see <http://www.gnu.org/licenses/>. 
 
+
 alias _wiki="stx2any --no-template --link-abbrevs --quote -T html"
-[ -z "${_GET[p]}" ] && _GET[p]=list
 file_pattern='^.*(mov|ts|mpg|mpeg|mp4|m4v|avi|mkv|flv|sfv|wmv|ogm|webm|iso|rmvb)$'
 
 data_dirs cache meta mp4 videos thumbs trash by_length transcoded
 
+PAGE="${_GET[p]:-${PAGE:-list}}"
+
 cgi_cookie
 validate(){ printf '%s\n' "$1" |sed -rn '2q;/^('"$2"')$/{p;q};a'"$3"; }