#!/bin/sh #--------------------------------------------------------------------- # /srv/www/admin/yapsGUI_send.cgi __FLI4LVER__ # # Last Update: $Id$ # # report errors to: Christoph Schulz #--------------------------------------------------------------------- SEC_REALM='sms' SEC_ACTION='send' . ./sec-lib.cgi # variablen einlesen eval "`proccgi $*`" echo "Content-Type: text/html; charset=iso-8859-1" echo "Pragma: no-cache" echo "Expires: 0" echo "" #if [ -d $YAPSGUI_LOGPATH ] # then # else # mkdir $YAPSGUI_LOGPATH #fi if [ -n "$FORM_RecipientM" ] then FORM_Recipient=$FORM_RecipientM fi if [ -n "$FORM_SenderM" ] then FORM_Sender=$FORM_SenderM fi if [ -z "$FORM_Recipient" ] then ErrorMessage="$ErrorMessage
  • Kein Empfänger angegeben" fi if [ -z "$FORM_Sender" ] then ErrorMessage="$ErrorMessage
  • Kein Absender angegeben" fi if [ -z "$FORM_Message" ] then ErrorMessage="$ErrorMessage
  • Keine Nachricht angegeben" fi if [ -n "$ErrorMessage" ] then echo "

    Es sind Fehler aufgetreten:

    " exit fi echo " yaps-GUI

    Bitte warten... Nachricht wird versandt...

    Nachricht an yaps übergeben - Ergebnis:

    Absender " # Absender echo "$FORM_Sender" echo "
    Empfänger " # Empfänger echo "$FORM_Recipient" echo "
    Nachricht " # Nachricht echo "$FORM_Message" echo "
    Status
    "
    # Status
    if [ "$FORM_Debug" = "1" ]
    then
     DebugLevel="-v"
    fi
    if [ "$FORM_Debug" = "2" ]
    then
     DebugLevel="-vv"
    fi
    if [ "$FORM_Debug" = "3" ]
    then
     DebugLevel="-vvv"
    fi
    if [ "$FORM_Debug" = "4" ]
    then
     DebugLevel="-vvvv"
    fi
    if [ "$FORM_RequestConfirm" = "1" ]
    then
       ReqCon="-r"
    fi
    
    Datum=`date +"%d%m%y%H%M"`
    if [ -z "$FORM_Sender" ]
    then
    # echo "yaps -v $FORM_Recipient $FORM_Message"
    yaps $DebugLevel $ReqCon $FORM_Recipient "$FORM_Message" # -l $YAPSGUI_LOGPATH$Datum.$FORM_Sender.$FORM_Recipient.$FORM_Message
     else
    # echo "yaps -c $FORM_Sender -v $FORM_Recipient $FORM_Message "
    yaps -c $FORM_Sender $ReqCon $DebugLevel $FORM_Recipient "$FORM_Message" # -l $YAPSGUI_LOGPATH$Datum.$FORM_Sender.$FORM_Recipient.$FORM_Message
    fi
    echo "
    "