From: jackster the jackle Date: 2008-09-27T11:50:21+09:00 Subject: Trying to use gsub using variables I need to be able to match and substitute text in a string and I'm trying to use gsub with no luck....probably because it's looking for an regular expression. Does anyone know how I can achieve this same thing using another method perhaps? Here is my code that is not working: x = "NEW_WORD" acl.gsub!(/WORD_TO_MATCH_AND_REPLACE/, x ) thanks jackster -- Posted via http://www.ruby-forum.com/.