Embedding 3B Components on Client Site: Difference between revisions

Jump to navigation Jump to search
no edit summary
(Created page with "This page provides some examples on how to embed 3B client facing components on a customer's website. == Prerequisites == # Ensure that you have access to the Salesforce guest site URL, which in this example is: <code>https://your-company<nowiki/>.my.salesforce-sites.com/onboarding</code>. # Ensure that your client's website supports the embedding of third-party components. == Job Board == <syntaxhighlight lang="html"> <!DOCTYPE html> <html lang="en"> <head> <met...")
 
No edit summary
Line 48: Line 48:


== Job Post ==
== Job Post ==
<syntaxhighlight lang="html">
This example demonstrates the ability to embed a Job Post in conjunction with the Portal Login Component which would login/register a candidate<syntaxhighlight lang="html">
<!DOCTYPE html>
<!DOCTYPE html>
<html lang="en">
<html lang="en">
Line 67: Line 67:
     <script src="https://my-company.my.salesforce-sites.com/onboarding/resource/b3o__GeneralUtils/index.js" defer="true" type="module" crossorigin="anonymous"></script>
     <script src="https://my-company.my.salesforce-sites.com/onboarding/resource/b3o__GeneralUtils/index.js" defer="true" type="module" crossorigin="anonymous"></script>
     <!-- Load Login Component -->
     <!-- Load Login Component -->
     <script src="https://my-company.my.salesforce-sites.com/onboarding/resource/PortalLoginComponent/index.js" type="module"></script>
     <script src="https://my-company.my.salesforce-sites.com/onboarding/resource/b3o__PortalLoginComponent/index.js" type="module"></script>
     <!-- Load Job Post Component -->
     <!-- Load Job Post Component -->
     <script src="https://my-company.my.salesforce-sites.com/onboarding/resource/b3o__JobPostResources/index.js" defer="true" type="module" crossorigin="anonymous"></script>
     <script src="https://my-company.my.salesforce-sites.com/onboarding/resource/b3o__JobPostResources/index.js" defer="true" type="module" crossorigin="anonymous"></script>
Line 98: Line 98:
             //Get the job ID from the URL param "id"
             //Get the job ID from the URL param "id"
             jobPost.setAttribute('job-id', searchParams.get('id'));
             jobPost.setAttribute('job-id', searchParams.get('id'));
             jobPost.setAttribute('app-documents-link', 'https://localhost:5501/OnboardingLatest/MyDocuments.html');
             jobPost.setAttribute('app-documents-link', 'https://my-company.my.salesforce-sites.com/MyDocuments.html');
             //Append the job component to the page
             //Append the job component to the page
             document.querySelector('body').appendChild(jobPost);
             document.querySelector('body').appendChild(jobPost);

Navigation menu