]> git.plutz.net Git - busy/blobdiff - Error.page
implemented bitcoin donations and advertisement (via http://bitcoinadvertisers.com)
[busy] / Error.page
index 61af555b1a72397ebd7b41dc67e08c85b16dbac0..98538b9b480dedcbf906b023ef963af273359c11 100644 (file)
 # You should have received a copy of the GNU Affero General Public License
 # along with Busy.  If not, see <http://www.gnu.org/licenses/>.
  
-reason=$(egrep -o '(^|&)r=.+(&|$)' <<<"${QUERY_STRING}" |sed 's,&,,g;s,r=,,')
+[ -z "$reason" ] && reason=$(egrep -o '(^|&)r=.+(&|$)' <<<"${QUERY_STRING}" |sed 's,&,,g;s,r=,,')
 [ -z "$reason" ] && reason="other"
 
-echo '<h2>Error</h2>'
+echo "
+<div id='MAIN'>
+<h2>Error</h2>
+"
 case "${reason}" in
   tooSmall) echo 'You need to select a file for uploading.'
     ;;
@@ -28,6 +31,9 @@ case "${reason}" in
     ;;
   input) echo 'Invalid set of input data.'
     ;;
+  noaccess) echo '... because you were probably trying to do something nasty.'
+    ;;
   *) echo 'Unknown generic fuckup :-('
     ;;
 esac
+echo "</div>"