• 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

    Interface IHtmlTagsService

    The service to generate HTML Tags.

    Tip

    This is the new, recommended way of generating tags, as it's better and functional

    Warning

    This looks almost the same as the static ToSic.Razor.Blade.Tag but there is a crucial difference The APIs return functional IHtmlTag objects. This is safer and more future proof, but you may run into surprises.

    Example:

    // Old Tag API - these two objects will be the same
    var tagOld = ToSic.Razor.Blade.Tag.Div();
    var tagOldWithId = tagOld.Id(...).Style(...).Class(...);
    // now tagOld and tagOldWithId are both the same objects with all changes applied
    
    // New API - assumes tagSvc is IHtmlTagsService
    // these two objects will NOT be the same
    var tag = tagSvc.Div();
    var tagWithId = tag.Id(...).Style(...).Class(...);
    // now tag is still an empty div-tag
    // while tagWithId is the tag wth everything set on 
    
    Namespace: ToSic.Razor.Blade
    Assembly: ToSic.Razor.dll
    Syntax
    public interface IHtmlTagsService
    Remarks
    • Introduced in v4.0
    • It intentionally uses the term "Service" in the end (different from IScrub to prevent confusion with IHtmlTag.

    Methods

    | Improve this Doc View Source

    A(Object[])

    Generate a standard HTML5 <a> tag with optional contents

    Declaration
    A A(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    A

    A A object with all the attributes available in that tag

    | Improve this Doc View Source

    Abbr(Object[])

    Generate a standard HTML5 <abbr> tag with optional contents

    Declaration
    Abbr Abbr(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Abbr

    A Abbr object with all the attributes available in that tag

    | Improve this Doc View Source

    Address(Object[])

    Generate a standard HTML5 <address> tag with optional contents

    Declaration
    Address Address(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Address

    A Address object with all the attributes available in that tag

    | Improve this Doc View Source

    Area(Object[])

    Generate a standard HTML5 <area> tag with optional contents

    Declaration
    Area Area(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Area

    A Area object with all the attributes available in that tag

    | Improve this Doc View Source

    Article(Object[])

    Generate a standard HTML5 <article> tag with optional contents

    Declaration
    Article Article(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Article

    A Article object with all the attributes available in that tag

    | Improve this Doc View Source

    Aside(Object[])

    Generate a standard HTML5 <aside> tag with optional contents

    Declaration
    Aside Aside(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Aside

    A Aside object with all the attributes available in that tag

    | Improve this Doc View Source

    Attr(String, Object, AttributeOptions)

    Generate an attribute for use in a tag

    Declaration
    Attribute Attr(string name, object value = null, AttributeOptions options = null)
    Parameters
    Type Name Description
    System.String name

    attribute name

    System.Object value

    attribute value object - will be serialized to json

    AttributeOptions options

    optional configuration regarding quotes and encoding

    Returns
    Type Description
    Attribute

    HtmlString so you can use <div @Tag.Attr(&quot;myid&quot;, 5930)> in your code

    | Improve this Doc View Source

    Attr(String, String, AttributeOptions)

    Generate an attribute for use in a tag

    Declaration
    Attribute Attr(string name, string value, AttributeOptions options = null)
    Parameters
    Type Name Description
    System.String name

    attribute name

    System.String value

    attribute value

    AttributeOptions options

    optional configuration regarding quotes and encoding

    Returns
    Type Description
    Attribute

    HtmlString so you can use <div @Tag.Attr(&quot;myid&quot;, "5930")> in your code

    | Improve this Doc View Source

    Audio(Object[])

    Generate a standard HTML5 <audio> tag with optional contents

    Declaration
    Audio Audio(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Audio

    A Audio object with all the attributes available in that tag

    | Improve this Doc View Source

    B(Object[])

    Generate a standard HTML5 <b> tag with optional contents

    Declaration
    B B(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    B

    A B object with all the attributes available in that tag

    | Improve this Doc View Source

    Base(Object[])

    Generate a standard HTML5 <base> tag with optional contents

    Declaration
    Base Base(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Base

    A Base object with all the attributes available in that tag

    | Improve this Doc View Source

    Bdi(Object[])

    Generate a standard HTML5 <bdi> tag with optional contents

    Declaration
    Bdi Bdi(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Bdi

    A Bdi object with all the attributes available in that tag

    | Improve this Doc View Source

    Bdo(Object[])

    Generate a standard HTML5 <bdo> tag with optional contents

    Declaration
    Bdo Bdo(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Bdo

    A Bdo object with all the attributes available in that tag

    | Improve this Doc View Source

    Blockquote(Object[])

    Generate a standard HTML5 <blockquote> tag with optional contents

    Declaration
    Blockquote Blockquote(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Blockquote

    A Blockquote object with all the attributes available in that tag

    | Improve this Doc View Source

    Br(Object[])

    Generate a standard HTML5 <br> tag with optional contents

    Declaration
    Br Br(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Br

    A Br object with all the attributes available in that tag

    | Improve this Doc View Source

    Button(Object[])

    Generate a standard HTML5 <button> tag with optional contents

    Declaration
    Button Button(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Button

    A Button object with all the attributes available in that tag

    | Improve this Doc View Source

    Canvas(Object[])

    Generate a standard HTML5 <canvas> tag with optional contents

    Declaration
    Canvas Canvas(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Canvas

    A Canvas object with all the attributes available in that tag

    | Improve this Doc View Source

    Caption(Object[])

    Generate a standard HTML5 <caption> tag with optional contents

    Declaration
    Caption Caption(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Caption

    A Caption object with all the attributes available in that tag

    | Improve this Doc View Source

    Cite(Object[])

    Generate a standard HTML5 <cite> tag with optional contents

    Declaration
    Cite Cite(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Cite

    A Cite object with all the attributes available in that tag

    | Improve this Doc View Source

    Code(Object[])

    Generate a standard HTML5 <code> tag with optional contents

    Declaration
    Code Code(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Code

    A Code object with all the attributes available in that tag

    | Improve this Doc View Source

    Col(Object[])

    Generate a standard HTML5 <col> tag with optional contents

    Declaration
    Col Col(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Col

    A Col object with all the attributes available in that tag

    | Improve this Doc View Source

    Colgroup(Object[])

    Generate a standard HTML5 <colgroup> tag with optional contents

    Declaration
    Colgroup Colgroup(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Colgroup

    A Colgroup object with all the attributes available in that tag

    | Improve this Doc View Source

    Comment(String)

    Create a HTML comment with something inside.

    Declaration
    Comment Comment(string content = null)
    Parameters
    Type Name Description
    System.String content

    optional content to place within the tag - usually a string

    Returns
    Type Description
    Comment

    HtmlString of the tag, so you can use it directly with @HtmlTag.Comment(...) in your razor

    | Improve this Doc View Source

    Custom(String, Object[])

    Create a generic html tag for a specific name. We recommend to use the normal tag overloads instead. So Tag.Img(...) is better than Tag.Custom("Img") because it's preconfigured to self-close, encode the src etc. RawHtml(Object[])

    Declaration
    TagCustom Custom(string name, params object[] content)
    Parameters
    Type Name Description
    System.String name

    tag name

    System.Object[] content

    optional content to place within the tag - can be a string or other tags

    Returns
    Type Description
    TagCustom
    | Improve this Doc View Source

    Data(Object[])

    Generate a standard HTML5 <data> tag with optional contents

    Declaration
    Data Data(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Data

    A Data object with all the attributes available in that tag

    | Improve this Doc View Source

    Datalist(Object[])

    Generate a standard HTML5 <datalist> tag with optional contents

    Declaration
    Datalist Datalist(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Datalist

    A Datalist object with all the attributes available in that tag

    | Improve this Doc View Source

    Dd(Object[])

    Generate a standard HTML5 <dd> tag with optional contents

    Declaration
    Dd Dd(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Dd

    A Dd object with all the attributes available in that tag

    | Improve this Doc View Source

    Del(Object[])

    Generate a standard HTML5 <del> tag with optional contents

    Declaration
    Del Del(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Del

    A Del object with all the attributes available in that tag

    | Improve this Doc View Source

    Details(Object[])

    Generate a standard HTML5 <details> tag with optional contents

    Declaration
    Details Details(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Details

    A Details object with all the attributes available in that tag

    | Improve this Doc View Source

    Dfn(Object[])

    Generate a standard HTML5 <dfn> tag with optional contents

    Declaration
    Dfn Dfn(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Dfn

    A Dfn object with all the attributes available in that tag

    | Improve this Doc View Source

    Dialog(Object[])

    Generate a standard HTML5 <dialog> tag with optional contents

    Declaration
    Dialog Dialog(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Dialog

    A Dialog object with all the attributes available in that tag

    | Improve this Doc View Source

    Div(Object[])

    Generate a standard HTML5 <div> tag with optional contents

    Declaration
    Div Div(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Div

    A Div object with all the attributes available in that tag

    | Improve this Doc View Source

    Dl(Object[])

    Generate a standard HTML5 <dl> tag with optional contents

    Declaration
    Dl Dl(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Dl

    A Dl object with all the attributes available in that tag

    | Improve this Doc View Source

    Dt(Object[])

    Generate a standard HTML5 <dt> tag with optional contents

    Declaration
    Dt Dt(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Dt

    A Dt object with all the attributes available in that tag

    | Improve this Doc View Source

    Em(Object[])

    Generate a standard HTML5 <em> tag with optional contents

    Declaration
    Em Em(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Em

    A Em object with all the attributes available in that tag

    | Improve this Doc View Source

    Embed(Object[])

    Generate a standard HTML5 <embed> tag with optional contents

    Declaration
    Embed Embed(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Embed

    A Embed object with all the attributes available in that tag

    | Improve this Doc View Source

    Fieldset(Object[])

    Generate a standard HTML5 <fieldset> tag with optional contents

    Declaration
    Fieldset Fieldset(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Fieldset

    A Fieldset object with all the attributes available in that tag

    | Improve this Doc View Source

    Figcaption(Object[])

    Generate a standard HTML5 <figcaption> tag with optional contents

    Declaration
    Figcaption Figcaption(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Figcaption

    A Figcaption object with all the attributes available in that tag

    | Improve this Doc View Source

    Figure(Object[])

    Generate a standard HTML5 <figure> tag with optional contents

    Declaration
    Figure Figure(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Figure

    A Figure object with all the attributes available in that tag

    | Improve this Doc View Source

    Footer(Object[])

    Generate a standard HTML5 <footer> tag with optional contents

    Declaration
    Footer Footer(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Footer

    A Footer object with all the attributes available in that tag

    | Improve this Doc View Source

    Form(Object[])

    Generate a standard HTML5 <form> tag with optional contents

    Declaration
    Form Form(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Form

    A Form object with all the attributes available in that tag

    | Improve this Doc View Source

    H1(Object[])

    Generate a standard HTML5 <h1> tag with optional contents

    Declaration
    H1 H1(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    H1

    A H1 object with all the attributes available in that tag

    | Improve this Doc View Source

    H2(Object[])

    Generate a standard HTML5 <h2> tag with optional contents

    Declaration
    H2 H2(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    H2

    A H2 object with all the attributes available in that tag

    | Improve this Doc View Source

    H3(Object[])

    Generate a standard HTML5 <h3> tag with optional contents

    Declaration
    H3 H3(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    H3

    A H3 object with all the attributes available in that tag

    | Improve this Doc View Source

    H4(Object[])

    Generate a standard HTML5 <h4> tag with optional contents

    Declaration
    H4 H4(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    H4

    A H4 object with all the attributes available in that tag

    | Improve this Doc View Source

    H5(Object[])

    Generate a standard HTML5 <h5> tag with optional contents

    Declaration
    H5 H5(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    H5

    A H5 object with all the attributes available in that tag

    | Improve this Doc View Source

    H6(Object[])

    Generate a standard HTML5 <h6> tag with optional contents

    Declaration
    H6 H6(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    H6

    A H6 object with all the attributes available in that tag

    | Improve this Doc View Source

    Head(Object[])

    Generate a standard HTML5 <head> tag with optional contents

    Declaration
    Head Head(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Head

    A Head object with all the attributes available in that tag

    | Improve this Doc View Source

    Header(Object[])

    Generate a standard HTML5 <header> tag with optional contents

    Declaration
    Header Header(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Header

    A Header object with all the attributes available in that tag

    | Improve this Doc View Source

    Hr(Object[])

    Generate a standard HTML5 <hr> tag with optional contents

    Declaration
    Hr Hr(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Hr

    A Hr object with all the attributes available in that tag

    | Improve this Doc View Source

    I(Object[])

    Generate a standard HTML5 <i> tag with optional contents

    Declaration
    I I(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    I

    A I object with all the attributes available in that tag

    | Improve this Doc View Source

    Icon(String, String, Int32, String)

    Declaration
    Icon Icon(string path, string rel = null, int size = 0, string type = null)
    Parameters
    Type Name Description
    System.String path
    System.String rel
    System.Int32 size
    System.String type
    Returns
    Type Description
    Icon
    | Improve this Doc View Source

    Iframe(Object[])

    Generate a standard HTML5 <iframe> tag with optional contents

    Declaration
    Iframe Iframe(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Iframe

    A Iframe object with all the attributes available in that tag

    | Improve this Doc View Source

    Img(Object[])

    Generate a standard HTML5 <img> tag with optional contents

    Declaration
    Img Img(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Img

    A Img object with all the attributes available in that tag

    | Improve this Doc View Source

    Input(Object[])

    Generate a standard HTML5 <input> tag with optional contents

    Declaration
    Input Input(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Input

    A Input object with all the attributes available in that tag

    | Improve this Doc View Source

    Ins(Object[])

    Generate a standard HTML5 <ins> tag with optional contents

    Declaration
    Ins Ins(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Ins

    A Ins object with all the attributes available in that tag

    | Improve this Doc View Source

    Kbd(Object[])

    Generate a standard HTML5 <kbd> tag with optional contents

    Declaration
    Kbd Kbd(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Kbd

    A Kbd object with all the attributes available in that tag

    | Improve this Doc View Source

    Label(Object[])

    Generate a standard HTML5 <label> tag with optional contents

    Declaration
    Label Label(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Label

    A Label object with all the attributes available in that tag

    | Improve this Doc View Source

    Legend(Object[])

    Generate a standard HTML5 <legend> tag with optional contents

    Declaration
    Legend Legend(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Legend

    A Legend object with all the attributes available in that tag

    | Improve this Doc View Source

    Li(Object[])

    Generate a standard HTML5 <li> tag with optional contents

    Declaration
    Li Li(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Li

    A Li object with all the attributes available in that tag

    | Improve this Doc View Source

    Link(Object[])

    Generate a standard HTML5 <link> tag with optional contents

    Declaration
    Link Link(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Link

    A Link object with all the attributes available in that tag

    | Improve this Doc View Source

    Main(Object[])

    Generate a standard HTML5 <main> tag with optional contents

    Declaration
    Main Main(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Main

    A Main object with all the attributes available in that tag

    | Improve this Doc View Source

    Map(Object[])

    Generate a standard HTML5 <map> tag with optional contents

    Declaration
    Map Map(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Map

    A Map object with all the attributes available in that tag

    | Improve this Doc View Source

    Mark(Object[])

    Generate a standard HTML5 <mark> tag with optional contents

    Declaration
    Mark Mark(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Mark

    A Mark object with all the attributes available in that tag

    | Improve this Doc View Source

    Meta(Object[])

    Generate a standard HTML5 <meta> tag with optional contents

    Declaration
    Meta Meta(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Meta

    A Meta object with all the attributes available in that tag

    | Improve this Doc View Source

    MetaOg(String, String)

    Generate a open-graph Meta tag.

    Declaration
    MetaOg MetaOg(string property = null, string content = null)
    Parameters
    Type Name Description
    System.String property
    System.String content
    Returns
    Type Description
    MetaOg
    Remarks

    Important: This is a specialized meta tag. The API to create it is different from most tags, as it has name/content parameters.

    | Improve this Doc View Source

    Meter(Object[])

    Generate a standard HTML5 <meter> tag with optional contents

    Declaration
    Meter Meter(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Meter

    A Meter object with all the attributes available in that tag

    | Improve this Doc View Source

    Nav(Object[])

    Generate a standard HTML5 <nav> tag with optional contents

    Declaration
    Nav Nav(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Nav

    A Nav object with all the attributes available in that tag

    | Improve this Doc View Source

    Noscript(Object[])

    Generate a standard HTML5 <noscript> tag with optional contents

    Declaration
    Noscript Noscript(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Noscript

    A Noscript object with all the attributes available in that tag

    | Improve this Doc View Source

    Object(Object[])

    Generate a standard HTML5 <object> tag with optional contents

    Declaration
    Object Object(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Object

    A Object object with all the attributes available in that tag

    | Improve this Doc View Source

    Ol(Object[])

    Generate a standard HTML5 <ol> tag with optional contents

    Declaration
    Ol Ol(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Ol

    A Ol object with all the attributes available in that tag

    | Improve this Doc View Source

    Optgroup(Object[])

    Generate a standard HTML5 <optgroup> tag with optional contents

    Declaration
    Optgroup Optgroup(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Optgroup

    A Optgroup object with all the attributes available in that tag

    | Improve this Doc View Source

    Option(Object[])

    Generate a standard HTML5 <option> tag with optional contents

    Declaration
    Option Option(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Option

    A Option object with all the attributes available in that tag

    | Improve this Doc View Source

    Output(Object[])

    Generate a standard HTML5 <output> tag with optional contents

    Declaration
    Output Output(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Output

    A Output object with all the attributes available in that tag

    | Improve this Doc View Source

    P(Object[])

    Generate a standard HTML5 <p> tag with optional contents

    Declaration
    P P(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    P

    A P object with all the attributes available in that tag

    | Improve this Doc View Source

    Param(Object[])

    Generate a standard HTML5 <param> tag with optional contents

    Declaration
    Param Param(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Param

    A Param object with all the attributes available in that tag

    | Improve this Doc View Source

    Picture(Object[])

    Generate a standard HTML5 <picture> tag with optional contents

    Declaration
    Picture Picture(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Picture

    A Picture object with all the attributes available in that tag

    | Improve this Doc View Source

    Pre(Object[])

    Generate a standard HTML5 <pre> tag with optional contents

    Declaration
    Pre Pre(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Pre

    A Pre object with all the attributes available in that tag

    | Improve this Doc View Source

    Progress(Object[])

    Generate a standard HTML5 <progress> tag with optional contents

    Declaration
    Progress Progress(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Progress

    A Progress object with all the attributes available in that tag

    | Improve this Doc View Source

    Q(Object[])

    Generate a standard HTML5 <q> tag with optional contents

    Declaration
    Q Q(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Q

    A Q object with all the attributes available in that tag

    | Improve this Doc View Source

    RawHtml(Object[])

    Simple tag creator for raw source code which doesn't have another tag around it.

    Mainly used in function which want to return content which should then be put into html directly

    Declaration
    TagCustom RawHtml(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content
    Returns
    Type Description
    TagCustom
    | Improve this Doc View Source

    Rp(Object[])

    Generate a standard HTML5 <rp> tag with optional contents

    Declaration
    Rp Rp(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Rp

    A Rp object with all the attributes available in that tag

    | Improve this Doc View Source

    Rt(Object[])

    Generate a standard HTML5 <rt> tag with optional contents

    Declaration
    Rt Rt(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Rt

    A Rt object with all the attributes available in that tag

    | Improve this Doc View Source

    Ruby(Object[])

    Generate a standard HTML5 <ruby> tag with optional contents

    Declaration
    Ruby Ruby(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Ruby

    A Ruby object with all the attributes available in that tag

    | Improve this Doc View Source

    S(Object[])

    Generate a standard HTML5 <s> tag with optional contents

    Declaration
    S S(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    S

    A S object with all the attributes available in that tag

    | Improve this Doc View Source

    Samp(Object[])

    Generate a standard HTML5 <samp> tag with optional contents

    Declaration
    Samp Samp(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Samp

    A Samp object with all the attributes available in that tag

    | Improve this Doc View Source

    Script(Object[])

    Generate a standard HTML5 <script> tag with optional contents

    Declaration
    Script Script(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Script

    A Script object with all the attributes available in that tag

    | Improve this Doc View Source

    ScriptJsonLd(Object)

    Create a JsonLd Script tag and automatically json-serialize the object inside it

    Declaration
    ScriptJsonLd ScriptJsonLd(object obj)
    Parameters
    Type Name Description
    System.Object obj

    an object which will be json serialized

    Returns
    Type Description
    ScriptJsonLd
    | Improve this Doc View Source

    ScriptJsonLd(String)

    Create a JsonLd Script

    Declaration
    ScriptJsonLd ScriptJsonLd(string json)
    Parameters
    Type Name Description
    System.String json

    the contents in the tag, usually JSON

    Returns
    Type Description
    ScriptJsonLd
    | Improve this Doc View Source

    Section(Object[])

    Generate a standard HTML5 <section> tag with optional contents

    Declaration
    Section Section(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Section

    A Section object with all the attributes available in that tag

    | Improve this Doc View Source

    Select(Object[])

    Generate a standard HTML5 <select> tag with optional contents

    Declaration
    Select Select(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Select

    A Select object with all the attributes available in that tag

    | Improve this Doc View Source

    Small(Object[])

    Generate a standard HTML5 <small> tag with optional contents

    Declaration
    Small Small(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Small

    A Small object with all the attributes available in that tag

    | Improve this Doc View Source

    Source(Object[])

    Generate a standard HTML5 <source> tag with optional contents

    Declaration
    Source Source(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Source

    A Source object with all the attributes available in that tag

    | Improve this Doc View Source

    Span(Object[])

    Generate a standard HTML5 <span> tag with optional contents

    Declaration
    Span Span(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Span

    A Span object with all the attributes available in that tag

    | Improve this Doc View Source

    Strong(Object[])

    Generate a standard HTML5 <strong> tag with optional contents

    Declaration
    Strong Strong(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Strong

    A Strong object with all the attributes available in that tag

    | Improve this Doc View Source

    Style(Object[])

    Generate a standard HTML5 <style> tag with optional contents

    Declaration
    Style Style(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Style

    A Style object with all the attributes available in that tag

    | Improve this Doc View Source

    Sub(Object[])

    Generate a standard HTML5 <sub> tag with optional contents

    Declaration
    Sub Sub(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Sub

    A Sub object with all the attributes available in that tag

    | Improve this Doc View Source

    Summary(Object[])

    Generate a standard HTML5 <summary> tag with optional contents

    Declaration
    Summary Summary(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Summary

    A Summary object with all the attributes available in that tag

    | Improve this Doc View Source

    Sup(Object[])

    Generate a standard HTML5 <sup> tag with optional contents

    Declaration
    Sup Sup(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Sup

    A Sup object with all the attributes available in that tag

    | Improve this Doc View Source

    Svg(Object[])

    Generate a standard HTML5 <svg> tag with optional contents

    Declaration
    Svg Svg(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Svg

    A Svg object with all the attributes available in that tag

    | Improve this Doc View Source

    Table(Object[])

    Generate a standard HTML5 <table> tag with optional contents

    Declaration
    Table Table(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Table

    A Table object with all the attributes available in that tag

    | Improve this Doc View Source

    TagList(Object[])

    Simple tag creator for tags inside it - the wrapper doesn't exist. Mainly used in function which want to return content which should then be put into html directly

    Declaration
    TagList TagList(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content
    Returns
    Type Description
    TagList
    | Improve this Doc View Source

    Tbody(Object[])

    Generate a standard HTML5 <tbody> tag with optional contents

    Declaration
    Tbody Tbody(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Tbody

    A Tbody object with all the attributes available in that tag

    | Improve this Doc View Source

    Td(Object[])

    Generate a standard HTML5 <td> tag with optional contents

    Declaration
    Td Td(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Td

    A Td object with all the attributes available in that tag

    | Improve this Doc View Source

    Template(Object[])

    Generate a standard HTML5 <template> tag with optional contents

    Declaration
    Template Template(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Template

    A Template object with all the attributes available in that tag

    | Improve this Doc View Source

    Textarea(Object[])

    Generate a standard HTML5 <textarea> tag with optional contents

    Declaration
    Textarea Textarea(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Textarea

    A Textarea object with all the attributes available in that tag

    | Improve this Doc View Source

    Tfoot(Object[])

    Generate a standard HTML5 <tfoot> tag with optional contents

    Declaration
    Tfoot Tfoot(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Tfoot

    A Tfoot object with all the attributes available in that tag

    | Improve this Doc View Source

    Th(Object[])

    Generate a standard HTML5 <th> tag with optional contents

    Declaration
    Th Th(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Th

    A Th object with all the attributes available in that tag

    | Improve this Doc View Source

    Thead(Object[])

    Generate a standard HTML5 <thead> tag with optional contents

    Declaration
    Thead Thead(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Thead

    A Thead object with all the attributes available in that tag

    | Improve this Doc View Source

    Time(Object[])

    Generate a standard HTML5 <time> tag with optional contents

    Declaration
    Time Time(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Time

    A Time object with all the attributes available in that tag

    | Improve this Doc View Source

    Tr(Object[])

    Generate a standard HTML5 <tr> tag with optional contents

    Declaration
    Tr Tr(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Tr

    A Tr object with all the attributes available in that tag

    | Improve this Doc View Source

    Track(Object[])

    Generate a standard HTML5 <track> tag with optional contents

    Declaration
    Track Track(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Track

    A Track object with all the attributes available in that tag

    | Improve this Doc View Source

    U(Object[])

    Generate a standard HTML5 <u> tag with optional contents

    Declaration
    U U(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    U

    A U object with all the attributes available in that tag

    | Improve this Doc View Source

    Ul(Object[])

    Generate a standard HTML5 <ul> tag with optional contents

    Declaration
    Ul Ul(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Ul

    A Ul object with all the attributes available in that tag

    | Improve this Doc View Source

    Var(Object[])

    Generate a standard HTML5 <var> tag with optional contents

    Declaration
    Var Var(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Var

    A Var object with all the attributes available in that tag

    | Improve this Doc View Source

    Video(Object[])

    Generate a standard HTML5 <video> tag with optional contents

    Declaration
    Video Video(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Video

    A Video object with all the attributes available in that tag

    | Improve this Doc View Source

    Wbr(Object[])

    Generate a standard HTML5 <wbr> tag with optional contents

    Declaration
    Wbr Wbr(params object[] content)
    Parameters
    Type Name Description
    System.Object[] content

    one or more objects (strings or tags) which will be inside the tag

    Returns
    Type Description
    Wbr

    A Wbr object with all the attributes available in that tag

    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX