Can I embed snippets on my webpage?

How to do it?

Publish the snippet to public then manually iframe the link?

Publish the snippet:
    If it's code: You can use code hosting platforms like GitHub, GitLab, or Bitbucket to create a repository and publish your code snippet.
    If it's plain text: You can use text-sharing platforms like Pastebin, GitHub Gists, or Google Docs to publish the text snippet.

Obtain the public link:
    For code hosting platforms: Once you publish the code, you'll get a unique URL that you can use to access the code snippet.
    For text-sharing platforms: After publishing, you'll receive a publicly accessible link that can be used to view the text snippet.

Manually iframe the link:
    To embed the code or text snippet on a webpage using an iframe, you need access to the HTML code of the page.
    Locate the section in the HTML where you want to embed the snippet.
    Insert an iframe tag with the src attribute pointing to the URL of the published snippet.
    Customize the iframe dimensions, styles, and any additional attributes as per your requirements.

Here's an example iframe code snippet:

Replace "https://example.com/path/to/snippet" with the actual URL of your published snippet, and adjust the width and height values according to your desired dimensions.

Please note that if you're embedding content from external sources using iframes, ensure that you have the necessary permissions to do so, and be cautious about potential security risks associated with embedding content from untrusted sources.

1 Like

Thank you Carl :handshake:

Hi @bukit , can you give us an example of the snippet you'd like to embed on your webpage, and why? Do you want to embed snippets like the same way we embed snippets in this community, or are you looking for something different?

Do you want to embed snippets like the same way we embed snippets in this community, or are you looking for something different?

Yes..

Let's say I'm blogging to show how to do "something", then I embed the snippet for the reader to copy the snippet.

I'm an affiliate also so I want to promote TB by showing pro/business only feature like text field etc (in a password protected page, for example)

1 Like

Got it, thanks. I'll keep you posted when this is possible in the future.

1 Like

I feel you can use the link of the snippet on your blog which can be quickly be copied to textblaze account. I have done that in one of the case here.

3 Likes