Select to view content in your preferred language

Any way to embed a hub onto another website?

1504
1
11-03-2020 02:52 PM
HeidiRagsdale
Emerging Contributor

I am specifically wanting to find embed code for the hub I have built.  I am trying to embed the hub onto my existing Wordpress site. Thanks in advance for any ideas!   #embed #arcgishub

0 Kudos
1 Reply
KlaraSchmitt
Esri Regular Contributor

Hello,

Yes, it's possible to embed Hub into WordPress. You will not be able to do it with the WordPress Embed Widget as Hub does not presently support the oEmbed Protocol. But you can insert it through a traditional iframe added in the code editor. The iframe dimensions will be dependent on the size of your WordPress site though. If you have blocks contained in a fixed-width container, the iframe will not extend beyond the edge of that container and if it's too narrow, it may trigger our tablet layout. You can see an example of what I've described in the following screenshot.

Hub site in tablet view embedded in WordPresshub-site-iframed-into-wordpress-post.png
If you still wish to try this on your own site, you can use the Code Block (in the new WP editor) or the Code tab (in the old WP editor) to add:

 

<iframe src="site-url-here" width="100%" height="600" frameborder="0" scrolling="yes"></iframe>

 

In the new WP editor, you may also need to select the code bracket dropdown menu at the top of the blockcode-block-selection-menu.png
and in the "Transform To" menu, select "Preformatted," save your post/page, and select Preview.

Tags (1)
0 Kudos