Custom HTML

The Custom HTML block enables you to seamlessly incorporate any web content directly into your documentation pages. This flexibility allows you to enhance your documentation with diverse elements, making it more engaging and informative for your audience.

To create a Custom HTML block:-

  • Type /

Never inject code that you did not inspect yourself.

What's Included?

We already have Bootstrap 4.1 and FontAwesome 5 Free loaded which you can use.

How to use Custom HTML?

With Custom HTML, there are two modes available:

  • When the HTML content is straightforward, it is rendered directly within the page's body, eliminating the need for an iFrame. Below is an example of simple HTML code:
HTML
Copy

For this mode, you can utilize inline styling effectively. Please refrain from adding any <body> or <html> tags, as the content is already rendered within a <body> tag. If you would like to style the elements, you can use Custom CSS to create new classes that can be applied to the elements in this section.

iFrame in Custom HTML

For enhanced security, any HTML that contains scripts, styles, head tags, or additional iFrames will be rendered within an iFrame embedded in the page. This ensures that potentially harmful content is isolated and does not interfere with the main page. For instance, the following code would be rendered within an iFrame:

HTML
Copy

When using an iFrame, it is important to note that no pre-existing CSS will load. This includes styles from Custom CSS or any third-party libraries. Therefore, you'll need to apply your own CSS rules to ensure your iFrame content appears as desired.

Resizing Dynamic iFrames

If your Custom HTML is being embedded within an iFrame, and the iFrame dynamically adds elements to the body, this can lead to limitations in height and the appearance of scrollbars. To resolve this issue, you can instruct the iFrame to resize by using:

Javascript
Copy

Use this function whenever you add elements to body dynamically.

Custom HTML Examples

Here are our top examples:

Fancy Button

Generate this button by:

Markup
Copy

Postman Collection Button

Generate a postman collection button by:

HTML
Copy

Column Layout

Welcome to our Supercharged documentation which has been written using DeveloperHub.io. This is a column layout.

Generate this column layout by:

HTML
Copy

Grid Layout

Generated this grid layout by:

HTML
Copy

GitHub Gist

Generated this Gist by:

Markup
Copy

PDF Reader

Generate this PDF Reader by:

Markup
Copy

Flowcharts and Diagrams

Generate this Flowchart by exporting from draw.io in HTML format.

Google Maps

Generated this map by using embedgooglemap.net.

Type to search, ESC to discard
Type to search, ESC to discard
Type to search, ESC to discard
  Last updated