From: drowe67 Date: Tue, 30 Oct 2012 03:53:16 +0000 (+0000) Subject: perl pbased version that works on IP04 X-Git-Url: http://git.whiteaudio.com/gitweb/?a=commitdiff_plain;h=497353a59ff1a9709fdfe67d13c9129b5deb6db8;p=freetel-svn-tracking.git perl pbased version that works on IP04 git-svn-id: https://svn.code.sf.net/p/freetel/code@895 01035d8c-6547-0410-b346-abe4f91aad63 --- diff --git a/mini-asterisk-gui2/cgi-bin/setlinekey2.cgi b/mini-asterisk-gui2/cgi-bin/setlinekey2.cgi index 85aa6ad8..55efdb0b 100755 --- a/mini-asterisk-gui2/cgi-bin/setlinekey2.cgi +++ b/mini-asterisk-gui2/cgi-bin/setlinekey2.cgi @@ -1,13 +1,19 @@ -#!/bin/sh -x +#!/bin/sh # setlinekey2.cgi # David Rowe 29 Oct 2012 # -# CGI to set the text in "file" from "this" to "that" +# CGI to set the text in "file" from "this" to "that" on lines with text "key" # # Test on host with: # -# $ export QUERY_STRING='file=test.txt&this=IPADDRESS=&that=192.168.1.31&key=mykey'; ./setlinekey.cgi +# $ export QUERY_STRING='file=test.txt&this=host=&that=192.168.1.31&key=Jazmin mini'; ./setlinekey2.cgi # +# using test file: +# +# root:/root> cat test.txt +# host=192.168.1.28 ; Jazmin mini-asterisk do not remove this comment +# dtmfmod=rfc2833 ; Jazmin mini-asterisk do not remove this comment +# host=192.168.1.29 ; SIP mini-asterisk do not remove this comment cat <