Method: Column#to_html

Defined in:
lib/asker/data/column.rb

#to_htmlObject



28
29
30
31
32
33
34
35
36
37
38
# File 'lib/asker/data/column.rb', line 28

def to_html
  case @type
  when "text"
    return @raw
  when "image_url"
    return "<img src=\"#{raw}\" alt=\"image\">"
  when "textfile_path"
    return "<pre>#{raw}</pre>"
  end
  "ERROR type #{@type}"
end