DevHub Docs
  • Welcome
  • Analytics
    • What events are tracked automatically?
    • Custom events
    • Google Analytics
  • API documentation
  • Domains
    • Registering a new domain
    • Renewing a domain
    • Pointing an existing domain
    • Pointing a subdomain of an existing domain
    • Transfer a domain
      • Transfer a domain to another registrar
    • Validating your domain
      • Validate with Google Webmaster Tools
    • Domain expiration process
  • Email accounts
    • Hosted email (rackspace)
      • Configure email clients to use POP or IMAP
  • Forms
    • Form and field options
    • Using fieldsets
    • Spam filtering
    • Configure SMTP For outbound emails
    • Using Marketo forms
  • Google Sheets
  • Hosting options
    • Embed pages
    • Wordpress plugin for path override
    • Server path override
      • Apache configuration
      • IIS configuration
      • NGINX configuration
    • CDN (content delivery network) support
  • Maps
    • Location finder
    • Map options explained
    • Google Maps API keys
  • Privacy
    • OneTrust integration
    • Cookies
  • Reverse proxy
    • Privacy and security
    • Proxy Configuration
    • Proxy Gating
    • Form lead tracking
    • Blocking and Whitelisting
      • Whitelisting Options
      • Google Ads rejections or disapprovals
      • 3rd Party Services/Widgets
      • Common Security System Restrictions or Domain Errors
  • SEO
    • Schema.org support
    • Sitemap XML
    • Enable No Index
  • Site builder
    • Getting Started
    • Images and video
    • Pages and content
      • Using page drafts
      • Adding Text
      • Adding and Managing Pages
      • Adding Images
      • Page templates and Templated pages
      • Maps
    • Redirects
    • Site Settings
    • Style Options
    • Adding a Business and location
    • Adding a site
    • Adding a user
    • Adding Custom Forms
    • Adding HTML to Sites or Pages
    • Blogs
  • SSL and security
    • SSL Troubleshooting
    • SSL certificate install options
      • Use your own purchased SSL certificate
    • Enable HTTPS for Sites and Proxies
  • Support
    • Creating a Zendesk account
    • Ticketing submission workflow
    • Builder URL and Site ID
  • Themes and custom templates
    • Getting started
    • Using macros
    • Using custom fields
    • Using URL parameters
    • Hours of operation
    • Using date and time in templates
    • Template variables
    • Site Builder Markup
      • Avoiding Site Builder CSS and HTML duplication
    • Example themes
      • Location focused page with bootstrap
      • Store locator theme example
    • Advanced Examples
      • Theme module templates
      • Static Google maps
      • Content translations
      • Page navigation
      • Override page title and meta tags
      • Adding line breaks to content
      • Get objects
      • Handling boolean values
      • Right to left languages
      • Access current URL
      • Social sharing links
      • Standard filters
      • Serializing data to JSON
      • Form events
      • Schema.org FAQ utility
  • Trace technology
    • What is Trace?
    • Configuration options
  • Data Sources
    • External Contexts
Powered by GitBook
On this page
  • Installation steps
  • Example embedded javascript code

Was this helpful?

  1. Hosting options

Embed pages

PreviousHosting optionsNextWordpress plugin for path override

Last updated 8 months ago

Was this helpful?

Intended to be used to integrate DevHub pages or location finder into an existing website experience.

With this approach, you can setup a page within your existing Site and CMS and then use the embed code to display your DevHub landing page or microsite.

Installation steps

  1. Generate your embed javascript code - See notes

  2. Create a page on your existing site

  3. Add the embed javascript code to the content area of your blank page

Example embedded javascript code

<div data-url="DEVHUB_PAGE_URL" data-title="DEVHUB_PAGE_TITLE" id="sb-site-embed"></div>
<script type="text/javascript">
(function() {
  var _cachebuster = Math.round(new Date().getTime() /2000);
  var _sb = document.createElement('script'); _sb.type = 'text/javascript';
  _sb.src = 'DEVHUB_PAGE_HOSTNAME/stat/js/site-embed.js?' + _cachebuster;
  var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(_sb, s);
})();
</script>

Required configuration of the above code

  • DEVHUB_PAGE_URL - this is the full published URL of your landing page or microsite

    • Example: https://yourcampaign.yourdomain.com/landing-page/

  • DEVHUB_PAGE_TITLE - this is the title of your landing page or microsite

    • Example: Landing Page

    • This is especially important for ADA accessibility

  • DEVHUB_PAGE_HOSTNAME - this is just the hosted domain part of your landing page URL (if different)

    • Example: https://yourcampaign.yourdomain.com

below