File tree Expand file tree Collapse file tree 3 files changed +21
-16
lines changed
DigitalLearningSolutions.Web/Views
LearningPortal/SelfAssessments Expand file tree Collapse file tree 3 files changed +21
-16
lines changed Original file line number Diff line number Diff line change 66@inject Microsoft .Extensions .Configuration .IConfiguration Configuration
77@{
88 var userResearchUrl = Configuration [" UserResearchUrl" ];
9+ Context .Request .Cookies .TryGetValue (" Dls-cookie-consent" , out string cookieConsent );
910}
1011<!DOCTYPE html>
1112<html lang =" en" >
1213<head >
14+ @if (cookieConsent == " true" )
15+ {
16+ @await Html .PartialAsync (" ~/Views/Shared/_GoogleTagManager.cshtml" )
17+ }
1318 <meta charset =" utf-8" >
1419 <meta http-equiv =" X-UA-Compatible" content =" IE=edge" >
1520 <meta name =" viewport" content =" width=device-width, initial-scale=1, shrink-to-fit=no" >
3944 <meta name =" twitter:card" content =" summary" >
4045 <meta name =" twitter:title" content =" @(ViewData[" twitter:title " ] ?? ViewData[" Title " ] ?? " Digital Learning Solutions " )" >
4146 <meta name =" twitter:description" content =" @(ViewData[" twitter:description " ] ?? " " )" >
42- @{
43- Context .Request .Cookies .TryGetValue (" Dls-cookie-consent" , out string cookieConsent );
44- }
45- @if (cookieConsent == " true" )
46- {
47- @await Html .PartialAsync (" ~/Views/Shared/_GoogleTagManager.cshtml" )
48- }
4947</head >
5048
5149<body >
50+ @if (cookieConsent == " true" )
51+ {
52+ @await Html .PartialAsync (" ~/Views/Shared/_GoogleTagManagerBodyTagJs.cshtml" )
53+ }
5254 <div id =" pagewrapper" >
5355 <script >document .body .className = ((document .body .className ) ? document .body .className + ' js-enabled' : ' js-enabled' ); </script >
5456
Original file line number Diff line number Diff line change 1+ <noscript >
2+ <iframe src =" https://www.googletagmanager.com/ns.html?id=GTM-KJPJHGW" height =" 0" width =" 0" style =" display :none ;visibility :hidden " ></iframe >
3+ </noscript >
Original file line number Diff line number Diff line change 2222 var headerExtension = (string )ViewData [LayoutViewDataKeys .Application ];
2323 var shouldDisplayHelpMenuItem = dlsSubApplication ? .DisplayHelpMenuItem ?? headerExtension != DlsSubApplication .TrackingSystem .HeaderExtension ;
2424 var userResearchUrl = Configuration [" UserResearchUrl" ];
25+ Context .Request .Cookies .TryGetValue (" Dls-cookie-consent" , out string cookieConsent );
2526}
2627<!DOCTYPE html>
2728<html lang =" en" >
2829<head >
29-
30+ @if (cookieConsent == " true" )
31+ {
32+ @await Html .PartialAsync (" ~/Views/Shared/_GoogleTagManager.cshtml" )
33+ }
3034 <meta charset =" utf-8" >
3135 <meta http-equiv =" X-UA-Compatible" content =" IE=edge" >
3236 <meta name =" viewport" content =" width=device-width, initial-scale=1, shrink-to-fit=no" >
5458 <meta name =" twitter:card" content =" summary" >
5559 <meta name =" twitter:title" content =" @(ViewData[" twitter:title " ] ?? ViewData[LayoutViewDataKeys.Title] ?? " Digital Learning Solutions " )" >
5660 <meta name =" twitter:description" content =" @(ViewData[" twitter:description " ] ?? " " )" >
57- @{
58- Context .Request .Cookies .TryGetValue (" Dls-cookie-consent" , out string cookieConsent );
59- }
60- @if (cookieConsent == " true" )
61- {
62- @await Html .PartialAsync (" ~/Views/Shared/_GoogleTagManager.cshtml" )
63- }
6461</head >
6562
6663<body >
67-
64+ @if (cookieConsent == " true" )
65+ {
66+ @await Html .PartialAsync (" ~/Views/Shared/_GoogleTagManagerBodyTagJs.cshtml" )
67+ }
6868 <div id =" pagewrapper" >
6969 <header >
7070 <script >document .body .className = ((document .body .className ) ? document .body .className + ' js-enabled' : ' js-enabled' ); </script >
You can’t perform that action at this time.
0 commit comments