diff --git a/netlify.toml b/netlify.toml index b71958890..ef94b071c 100644 --- a/netlify.toml +++ b/netlify.toml @@ -148,6 +148,11 @@ status = 200 FR_SITE = "https://mon-entreprise.fr${path}" MASTER = 'true' -[context."demo"] +[context."demo".environment] EN_SITE = "https://demo.mon-entreprise.fr${path}?s=m" FR_SITE = "https://demo.mon-entreprise.fr${path}" + +# TEMP Just for testing the iframe when migrating from embauche to mon-entreprise +[context."migration-embauche".environment] + EN_SITE = "https://deploy-preview-520--syso.netlify.com${path}?s=m" + FR_SITE = "https://deploy-preview-520--syso.netlify.com${path}" \ No newline at end of file diff --git a/source/sites/mon-entreprise.fr/iframe-integration-script.js b/source/sites/mon-entreprise.fr/iframe-integration-script.js index 75e477665..c47d69511 100644 --- a/source/sites/mon-entreprise.fr/iframe-integration-script.js +++ b/source/sites/mon-entreprise.fr/iframe-integration-script.js @@ -10,8 +10,8 @@ let script = document.getElementById('script-simulateur-embauche'), ), integratorUrl = encodeURIComponent(window.location.href.toString()), src = - baseUrl + - `?s=e&couleur=${couleur}&iframe&integratorUrl=${integratorUrl}&lang=${lang}` + baseUrl + (baseUrl.indexOf('?') !== -1 ? '&' : '?') + + `couleur=${couleur}&iframe&integratorUrl=${integratorUrl}&lang=${lang}` const iframe = document.createElement('iframe') const iframeAttributes = {