#!/bin/sh # first sh box parser for titannit mfg obi . /tmp/localhoster/hoster.sh SRC=$1 INPUT=$2 PAGE=$3 URL=http://cricfree.sc/ PARSER=`echo $SRC | tr '/' '\n' | tail -n1 | sed 's/.sh//'` NAME=CricFree FILENAME="$PARSER $INPUT $PAGE" FILENAME=`echo $FILENAME | tr '&' '.' | tr '/' '.' | tr '?' '.' | tr '=' '.' | sed 's/ \+/./g' | sed 's/\.\+/./g'` #rm -rf $TMP > /dev/null 2>&1 mkdir $TMP > /dev/null 2>&1 if [ `echo $SRC | grep ^"/mnt/parser" | wc -l` -gt 0 ];then TYPE="$SRC - Shell script" elif [ `echo $SRC | grep ^"/var/swap" | wc -l` -gt 0 ];then TYPE="Swap - Shell script" elif [ `echo $SRC | grep ^"/mnt/swapextensions" | wc -l` -gt 0 ];then TYPE="Mnt - Shell script" else TYPE="Flash - Shell script" fi init() { # if [ "$ARCH" != "sh4" ] || [ -e /etc/.beta ];then rm -f /mnt/network/cookies > /dev/null 2>&1 rm -rf $TMP > /dev/null 2>&1 echo "$NAME ($TYPE)#$SRC $SRC mainmenu#http://atemio.dyndns.tv/mediathek/menu/$PARSER.jpg#$PARSER.jpg#TiThek#0" # fi } mainmenu() { echo "Channels#$SRC $SRC search /#http://atemio.dyndns.tv/mediathek/menu/category.jpg#category.jpg#$NAME#0" > $TMP/$FILENAME.list echo "$TMP/$FILENAME.list" } search() { rm $TMP/cache.$FILENAME.* > /dev/null 2>&1 rm $TMP/$FILENAME.* > /dev/null 2>&1 if [ ! -e "$TMP/$FILENAME.list" ]; then piccount=0 $curlbin $URL/$PAGE -o $TMP/cache.$FILENAME.1 cat $TMP/cache.$FILENAME.1 | tr '\n' '\r' | tr '\r' ' ' | tr '\n' ' ' | tr '\t' ' ' | sed 's/ \+/ /g' | sed 's!