• Home
  • Articles
  • API Documentation
Search Results for

    Show / Hide Table of Contents
    • ToSic.Razor.Blade
      • IHtmlTag
      • IHtmlTagsService
      • IScrub
      • Tag
      • Tags
      • Text
    • ToSic.Razor.Html5
      • A
      • Abbr
      • Address
      • Area
      • Article
      • Aside
      • Audio
      • B
      • Base
      • Bdi
      • Bdo
      • Blockquote
      • Br
      • Button
      • Canvas
      • Caption
      • Cite
      • Code
      • Col
      • Colgroup
      • Comment
      • Data
      • Datalist
      • Dd
      • Del
      • Details
      • Dfn
      • Dialog
      • Div
      • Dl
      • Dt
      • Em
      • Embed
      • Fieldset
      • Figcaption
      • Figure
      • Footer
      • Form
      • H1
      • H2
      • H3
      • H4
      • H5
      • H6
      • Head
      • Header
      • Hr
      • I
      • Icon
      • Iframe
      • Img
      • Input
      • Ins
      • Kbd
      • Label
      • Legend
      • Li
      • Link
      • Main
      • Map
      • Mark
      • Meta
      • MetaOg
      • Meter
      • Nav
      • Noscript
      • Object
      • Ol
      • Optgroup
      • Option
      • Output
      • P
      • Param
      • Picture
      • Pre
      • Progress
      • Q
      • Rp
      • Rt
      • Ruby
      • S
      • Samp
      • Script
      • ScriptJsonLd
      • Section
      • Select
      • Small
      • Source
      • Span
      • Strong
      • Style
      • Sub
      • Summary
      • Sup
      • Svg
      • Table
      • Tbody
      • Td
      • Template
      • Textarea
      • Tfoot
      • Th
      • Thead
      • Time
      • Tr
      • Track
      • U
      • Ul
      • Var
      • Video
      • Wbr
    • ToSic.Razor.Markup
      • Attribute
      • AttributeOptions
      • Attributes
      • ITag
      • Tag<T>
      • TagBase
      • TagChildren
      • TagCustom
      • TagList
      • TagOptions
      • TagText
    • ToSic.Razor.StartUp
      • StartUp

    Class Option

    Generate a standard HTML5 <option> tag

    Inheritance
    System.Object
    ToSic.Razor.Markup.RawHtmlString
    TagBase
    Tag<Option>
    Option
    Implements
    System.Web.IHtmlString
    IHtmlTag
    ITag
    System.Collections.Generic.IEnumerable<ITag>
    System.Collections.IEnumerable
    Inherited Members
    Tag<Option>.Attr(String, Object, String)
    Tag<Option>.Attr(Object)
    Tag<Option>.Id(String)
    Tag<Option>.Class(String)
    Tag<Option>.Style(String)
    Tag<Option>.Title(String)
    Tag<Option>.Data(String, Object)
    Tag<Option>.On(String, Object)
    Tag<Option>.Add(Object[])
    Tag<Option>.Wrap(Object[])
    Tag<Option>.AsHtmlTag()
    TagBase.IsImmutable
    TagBase.PreProcessNewChild(Object)
    TagBase.ApplyChanges(CloneChanges)
    TagBase.TagName
    TagBase.TagOptions
    TagBase.ToString()
    TagBase.TagAttributes
    TagBase.TagChildren
    TagBase.TagStart
    TagBase.TagEnd
    Namespace: ToSic.Razor.Html5
    Assembly: ToSic.Razor.dll
    Syntax
    public class Option : Tag<Option>, IRawHtmlString, IHtmlString, IHtmlTag, ITag, IEnumerable<ITag>, IEnumerable

    Methods

    | Improve this Doc View Source

    Disabled()

    Activate the disabled attribute on the <option> tag

    Declaration
    public Option Disabled()
    Returns
    Type Description
    Option

    a Option object to enable fluid command chaining

    | Improve this Doc View Source

    Disabled(String)

    Set the disabled attribute on the <option> tag

    Declaration
    public Option Disabled(string value)
    Parameters
    Type Name Description
    System.String value

    what should be in disabled='...'. If called multiple times, later values replace the previous value.

    Returns
    Type Description
    Option

    a Option object to enable fluid command chaining

    | Improve this Doc View Source

    Label(String)

    Set the label attribute on the <option> tag

    Declaration
    public Option Label(string value)
    Parameters
    Type Name Description
    System.String value

    what should be in label='...'. If called multiple times, later values replace the previous value.

    Returns
    Type Description
    Option

    a Option object to enable fluid command chaining

    | Improve this Doc View Source

    Selected()

    Activate the selected attribute on the <option> tag

    Declaration
    public Option Selected()
    Returns
    Type Description
    Option

    a Option object to enable fluid command chaining

    | Improve this Doc View Source

    Selected(String)

    Set the selected attribute on the <option> tag

    Declaration
    public Option Selected(string value)
    Parameters
    Type Name Description
    System.String value

    what should be in selected='...'. If called multiple times, later values replace the previous value.

    Returns
    Type Description
    Option

    a Option object to enable fluid command chaining

    | Improve this Doc View Source

    Value(String)

    Set the value attribute on the <option> tag

    Declaration
    public Option Value(string value)
    Parameters
    Type Name Description
    System.String value

    what should be in value='...'. If called multiple times, later values replace the previous value.

    Returns
    Type Description
    Option

    a Option object to enable fluid command chaining

    Implements

    System.Web.IHtmlString
    IHtmlTag
    ITag
    System.Collections.Generic.IEnumerable<T>
    System.Collections.IEnumerable
    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX