Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/analyze.php on line 89

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/toolbox.php on line 161

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/WikiSh.php on line 248

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/WikiSh.php on line 4642

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/SecLayer.php on line 138

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/SecLayer.php on line 138

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/SecLayer.php on line 230

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/SecLayer.php on line 230

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/SecLayer.php on line 233

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/SecLayer.php on line 304

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/SecLayer.php on line 304

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/SecLayer.php on line 307

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/powertools.php on line 92

Deprecated: Array and string offset access syntax with curly braces is deprecated in /homepages/39/d252297167/htdocs/pmwiki/cookbook/mini.php on line 102

Warning: Cannot modify header information - headers already sent by (output started at /homepages/39/d252297167/htdocs/pmwiki/cookbook/analyze.php:89) in /homepages/39/d252297167/htdocs/pmwiki/pmwiki.php on line 1760
CCL | WikiSh / WikiShRC
Recent Changes - Search:
  • nothing to see here. Sorry.

edit SideBar

WikiShRC

  1. PLEASE NOTE: This page is a SHARED page! If you edit it then you will make a copy
  2. in your LOCAL configuration and you will no longer use the shared page.

set -s ShoutPage = "Site.ShoutBox"

function ProcShout {

   # If the user set the nickname on the form, use it
   if test -n ⚠ ${shoutname}
   then
      set -s --session shoutname = ⚠ ${shoutname}
   fi
   if test -z ⚠ ${~shoutname}
   then
      set -s --session shoutname = 
   fi
   set -s shoutname = ⚠ ${~shoutname}
   set -s --form shoutname = ⚠ ${shoutname}
   if test -n ⚠ ${shoutname}
   then
      set -s shoutid = "⚠ ${shoutname}: "
   else
      set -s shoutid = ""
   fi
   if test -n ⚠ ${shoutsave} && test -n ⚠ ${shouttext}
   then
      echo "⚠ ${NOW}: ⚠ ${shoutid}⚠ ${shouttext}" >>⚠ ${ShoutPage}
   fi

}

function ListShout {

   if test -n ⚠ ${shoutlines}
   then
      set lines = ⚠ ${shoutlines}
      set deadline = 0
   else
      if test -n ⚠ ${1}
      then
         set lines = ⚠ ${1}
      else
         set lines = 100
      fi
      if test -n "⚠ ${2}"
      then
        set deadline = ⚠ ${NOW} - ⚠ ${2}
      else
         set deadline = ⚠ ${NOW} - 7200
      fi
   fi
   tail -n ⚠ ${lines} ⚠ ${ShoutPage} | while read -IFS:": " timestamp rest
   do
      if test ⚠ ${timestamp} >= ⚠ ${deadline}
      then
         echo "⚠ ${rest}"
      fi
   done
   if test -n ⚠ ${shoutname}
   then
      set -s ShoutShowHide = 'hide'
      set -s ShoutNameLabel = 'Name:'
   else
      set -s ShoutShowHide = 'show'
      set -s ShoutNameLabel = "Name:"
   fi

}

function CleanShout {

   if test -z ⚠ ${shoutclean}
   then
      return
   fi
   set boundary = ⚠ ${NOW} - 3600
   if test -f Tmp.Shout
   then
      rm Tmp.Shout
   fi
   cat ⚠ ${ShoutPage} | while read --IFS:": " time line
   do
      if test ⚠ ${time} -ge ⚠ ${boundary}
      then
         echo "⚠ ${time}: ⚠ ${line}" >>Tmp.Shout
      fi
   done
   cat Tmp.Shout >⚠ ${ShoutPage}

}

Edit - History - Print - Recent Changes - Search
Page last modified on February 14, 2010, at 11:05 AM