Module: CGI::Html4Fr

Defined in:
lib/cgi/html.rb

Overview

Mixin module for generating HTML version 4 with framesets.

Instance Method Summary (collapse)

Instance Method Details

- (Object) doctype

The DOCTYPE declaration for this version of HTML



991
992
993
# File 'lib/cgi/html.rb', line 991

def doctype
  %|<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">|
end

- (Object) element_init

Initialise the HTML generation methods for this version.



996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
# File 'lib/cgi/html.rb', line 996

def element_init
  methods = ""
  # - -
  for element in %w[ FRAMESET ]
    methods += <<-BEGIN + nn_element_def(element) + <<-END
      end
    END
  end

  # - O EMPTY
  for element in %w[ FRAME ]
    methods += <<-BEGIN + nOE_element_def(element) + <<-END
      end
    END
  end
  eval(methods)
end