assign vaiables from string values
I have this string where the values can be in any order and any number of sets with ='
For example this string: "bb=also aa=This cc=is dd=a ee=string" I want to process the string and set the respective variables to the value so that: $bb=also $aa=This $cc=is $ee=string $dd=a |
This seems to work for me
Code:
eval "bb=also aa=This cc=is dd=a ee=string" |
Thanks Chris. That worked perfectly!
|
nice one chrism
|
All times are GMT -5. The time now is 06:15 PM. |