var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: Can't stop shell interpreting special characters
I am struggling with the following sample code:
It returns 'c' and the name of a file in the directory I'm in.
array1=(a b c d)
array2=(* * * *)
I can't for the life of me work out how to prevent the shell interpreting the '*' and just get it to return the plain character ... is there a way to do this?
Also, my Learning the Korn Shell book lists several sed-like functions you can use to edit variable names, e.g.
returns 'strings'. But Sed has a function where you can 'store' part of the pattern matched, and get it back in the replacement string, e.g.
returns 'strin'. Does the Korn shell have a similar feature that's not in my book?
print $variable | sed "s/\(strin\)g/\1/"
Last edited by Doug97; 11-23-05 at 18:36.
In your case shell is interpreting *, not '*'
Originally Posted by Doug97