Skip to content

HTML element tools #5

@asg017

Description

@asg017
  • html_element(tag, attributes, child1, child2, ....)
  • html_attributes(attr1, attr2, ...) (or html_attrs)
    • html_attribute(name, value, namespace) (or html_attr()
-- https://developer.mozilla.org/en-US/docs/Learn/Getting_started_with_the_web/HTML_basics
select 
html_element('html', null, 
  html_element('head', null, 
    html_element('meta', html_attributes('charset', 'utf-8')), 
    html_element('title', null, 'My test page'),
  ),
  html_element('body', null,
    html_element('img', html_attributes('src', 'images/firefox-icon.png', 'alt', 'My test image')),
  )
);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions