# File lib/cgikit.rb, line 2508
        def to_s
                string = nil
                if @attr_string then
                        string = @attr_string
                elsif body.empty? == false then
                        parser                  = CKHTMLParser.new( parent, body )
                        parser.repetitions      = @repetitions
                        parser.repetition_index = @repetition_index
                        container               = parser.parse

                        if container then string = container
                        else              string = @attr_string end
                end

                to_s = value = href = nil
                if @attr_enabled == true then
                        # hyperlink, <form> or <a>
                        if    @attr_invoke_action   then href = application.url element_id
                        elsif _href = fetch('href') then href = _href end

                        # value
                        if    @attr_value       then value = @attr_value
                        elsif @attr_form_value  then value = @attr_form_value
                        elsif @attr_form_values then
                                value = @attr_form_values[@repetition_index]
                        end

                        # radiobutton
                        if (@attr_tag.downcase == 'input') and \
                                (fetch('type').downcase == 'radio') and (_name = fetch('name')) then
                                @attr_name.element = _name
                                if value == nil then value = 'on' end
                                value = "#{definition['oid']}.#{value}"
                        end

                        to_s =  "<#@attr_tag name=\"#@attr_name\""
                        to_s << " value=\"#{value}\"" if value
                        to_s << " href=\"#{href}\""   if href
                        to_s << " #@attr_option"      if @attr_option
                        to_s << other_attributes_string
                        to_s << '>'
                        to_s << string if string

                        unless NO_CLOSE_TAGS.include? @attr_tag then
                                to_s << "</#@attr_tag>"
                        end
                else
                        to_s = string
                end

                to_s
        end