sed error "unescaped newline inside substitute pattern"

Kent Stewart kstewart at owt.com
Thu Mar 12 11:05:58 PDT 2009


On Thursday 12 March 2009 10:34:36 am David Banning wrote:
> Here is the php line that gives the error;
>
> cat start_text | sed "s/--maintext--/$test/" > endtext
>
> give error;
>
> sed: 1: "s/--maintext--/ Comment ...": unescaped newline inside substitute
> pattern
>
> where $test contains customer input from a website form
>
> There is something about the content of the text within the variable $test
> that is causing the error.
>
> Any pointers would be helpful.

Well, it might be because "test" is a command line function.

Kent

-- 
kent Stewart
Richland, WA

http://users.owt.com/kstewart/index.html



More information about the freebsd-questions mailing list