QuickEmbed
Use the Quick Embed of content to provide a direct, simple approach to injecting the content item into the target container which includes all the steps for connecting to the host instance of Pyramid and authenticating the user.
quickEmbed(options: QuickEmbedOptions): void
- The quickEmbed method is static.
- The content selection and settings for the embed are specified in the QuickEmbedOptions object
QuickEmbed is only for content embedding. It is not available for embedding a Hub or Search.
Example
The following snippet creates the quick embed options object and then loads the content through the quick embed function into "myContainer". Notice quick embed includes the details for logging into the host with the end user credentials as well.
var options = {contentId:"c20d42b4-be24-47cf-b711-d5782f048590",
host: "https://analytics.pyramid.com",username: "john",password: "ab123!"}
client.quickEmbed($("myContainer"), options);
Alternatively, this can be executed in one statement:
client.quickEmbed ({
contentId:"c20d42b4-be24-47cf-b711-d5782f048590",
container: $("myContainer"),
host: "https://analytics.pyramid.com",
username: "john",
password: "ab123!"
});