Class: Amrita::HtmlTagInfo

Class Amrita::HtmlTagInfo |
In: | lib/amrita/tag.rb
Parent: | TagInfo

Methods

new

Included modules

Amrita

Public Class methods

new()

    # File lib/amrita/tag.rb, line 280
        def initialize
          super

          pptype1 = )html head body table ul ol div br table tr)
          pptype1.each do |name|
            get_tag_info(name).pptype = 1
          end

          pptype2 = )title link meta tr li th td h1 h2 h3 h4 h5 h6 p)
          pptype2.each do |name|
            get_tag_info(name).pptype = 2
          end
          empty = )area base basefont bgsound br col frame hr img input isindex
    	         keygen link meta nextid param spacer wbr)
          empty.each do |name|
            get_tag_info(name).can_be_empty = true
          end

          get_tag_info(:a).set_url_attr(:href)
          get_tag_info(:base).set_url_attr(:href)
          get_tag_info(:img).set_url_attr(:src)
          get_tag_info(:img).set_url_attr(:usemap)
          get_tag_info(:form).set_url_attr(:action)
          get_tag_info(:link).set_url_attr(:href)
          get_tag_info(:area).set_url_attr(:href)
          get_tag_info(:body).set_url_attr(:background)
          get_tag_info(:script).set_url_attr(:src)
          get_tag_info(:object).set_url_attr(:classid)
          get_tag_info(:object).set_url_attr(:codebase)
          get_tag_info(:object).set_url_attr(:data)
          get_tag_info(:object).set_url_attr(:archive)
          get_tag_info(:object).set_url_attr(:usemap)
          get_tag_info(:applet).set_url_attr(:codebase)
          get_tag_info(:applet).set_url_attr(:archive)
          get_tag_info(:applet).set_url_attr(:usemap)
          get_tag_info(:q).set_url_attr(:cite)
          get_tag_info(:blockquote).set_url_attr(:cite)
          get_tag_info(:ins).set_url_attr(:cite)
          get_tag_info(:del).set_url_attr(:cite)
          get_tag_info(:frame).set_url_attr(:longdesc)
          get_tag_info(:frame).set_url_attr(:src)
          get_tag_info(:iframe).set_url_attr(:longdesc)
          get_tag_info(:iframe).set_url_attr(:src)
          get_tag_info(:head).set_url_attr(:profile)

          BLOCK.each do |t|
            get_tag_info(t).tag_class = TagBlock
          end

          INLINE.each do |t|
            get_tag_info(t).tag_class = TagInline
          end

          EMPTY.each do |t|
            get_tag_info(t).tag_class = TagEmpty
          end

          LIST.each do |t|
            get_tag_info(t).tag_class = TagList
          end

          ITEM.each do |t|
            get_tag_info(t).tag_class = TagItem
          end

          )thead tbody tfoot).each do |t|
            get_tag_info(t).tag_class = TagTableSection
          end

          )dt dd).each do |t|
            get_tag_info(t).tag_class = TagDT
          end

          get_tag_info(:pre).tag_class = TagPre
          get_tag_info(:p).tag_class = TagP

        end