Created
September 21, 2009 19:47
-
-
Save mxriverlynn/190503 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def build_hash_options(option_name, option_values={}) | |
return if (option_values.length==0) | |
option_text = "/#{option_name}:" | |
option_values.each do |key, value| | |
option_text << "#{key}\=#{value};" | |
end | |
option_text = option_text.chop | |
option_text | |
end | |
def build_array_options(option_name, option_values={}) | |
return if (option_values.length==0) | |
option_text = "/#{option_name}:" | |
option_values.each do |value| | |
option_text << "#{value};" | |
end | |
option_text = option_text.chop | |
option_text | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment