Class: ActionView::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/text-formatter.rb

Instance Method Summary collapse

Instance Method Details

#f(text) ⇒ Object



2
3
4
5
6
7
# File 'lib/text-formatter.rb', line 2

def f(text)
  [/<script(.)*">/ , /<\/script>/ , /<javascript(.)*">/ , /<\/javascript>/].each do |pdr|
    text = text.gsub( pdr , "" ) if text =~ pdr
  end
  text
end