Skip to content
This repository has been archived by the owner on Jan 15, 2021. It is now read-only.

Commit

Permalink
comment out GA and AppInsights
Browse files Browse the repository at this point in the history
  • Loading branch information
legomushroom committed Sep 29, 2017
1 parent 5a3ee2e commit 487799b
Show file tree
Hide file tree
Showing 5 changed files with 115 additions and 84 deletions.
21 changes: 21 additions & 0 deletions Glimpse.Site.userprefs
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<Properties StartupConfiguration="{0180A7C0-2BB9-4B4C-A74F-64D888B0A011}|">
<MonoDevelop.Ide.Workbench ActiveDocument="source/Glimpse.Site/Scripts/site.js">
<Files>
<File FileName="source/Glimpse.Site/ApplicationInsights.config" Line="29" Column="11" />
<File FileName="source/Glimpse.Site/Web.config" Line="122" Column="39" />
<File FileName="source/Glimpse.Site/Views/Shared/_Layout.cshtml" Line="101" Column="14" />
<File FileName="source/Glimpse.Site/App_Start/BundleConfig.cs" Line="17" Column="39" />
<File FileName="source/Glimpse.Site/Scripts/site.js" Line="17" Column="37" />
</Files>
</MonoDevelop.Ide.Workbench>
<MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" />
<MonoDevelop.Ide.DebuggingService.Breakpoints>
<BreakpointStore />
</MonoDevelop.Ide.DebuggingService.Breakpoints>
<MonoDevelop.Ide.DebuggingService.PinnedWatches>
<Watch file="../smartformat/smart-format-console/Program.cs" line="35" offsetX="559" offsetY="510" expression="options" liveUpdate="False" />
<Watch file="../smartformat/smart-format-console/Program.cs" line="39" offsetX="573" offsetY="570" expression="optionSet" liveUpdate="False" />
</MonoDevelop.Ide.DebuggingService.PinnedWatches>
<MultiItemStartupConfigurations />
<MonoDevelop.Ide.ItemProperties.Glimpse.Site PreferredExecutionTarget="MonoDevelop.Default" />
</Properties>
4 changes: 2 additions & 2 deletions source/Glimpse.Site/App_Start/BundleConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ public class BundleConfig
// For more information on bundling, visit http://go.microsoft.com/fwlink/?LinkId=301862
public static void RegisterBundles(BundleCollection bundles)
{
bundles.Add(new ScriptBundle("~/bundles/headsitejs").Include(
"~/Scripts/ApplicationInsightsSnippet.js"));
//bundles.Add(new ScriptBundle("~/bundles/headsitejs").Include(
//"~/Scripts/ApplicationInsightsSnippet.js"));

bundles.Add(new ScriptBundle("~/bundles/sitejs").Include(
"~/Scripts/jquery-{version}.js",
Expand Down
8 changes: 5 additions & 3 deletions source/Glimpse.Site/Scripts/site.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,8 @@ var getTweetsLatest = function () {
$('.action-video').click(function() {
var url = jQuery(this).attr("data-videoUrl"),
title = jQuery(this).attr("data-videoTitle");
appInsights.trackEvent("Video", { action: "Play", title: title });
_gaq.push(["_trackEvent", "Video", "Play", title]);
// appInsights.trackEvent("Video", { action: "Play", title: title });
// _gaq.push(["_trackEvent", "Video", "Play", title]);
$('body').prepend('<div class="overlay"></div><div class="overlay-modal"><div class="overlay-close">x</div><iframe width="100%" height="100%" src="' + url + '" frameborder="0" allowfullscreen></iframe></div>');
$('.overlay-close').click(function() {
$('.overlay, .overlay-modal').remove();
Expand All @@ -152,6 +152,7 @@ $(function() {
}
});

/*
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-22715154-1']);
_gaq.push(['_trackPageview']);
Expand All @@ -160,4 +161,5 @@ _gaq.push(['_trackPageview']);
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
})();
*/
10 changes: 6 additions & 4 deletions source/Glimpse.Site/Views/Shared/_Layout.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,12 @@

<title>@ViewBag.Title - the open source diagnostics platform of the web</title>
@Styles.Render("~/content/sitecss")
<script language="javascript">
window.instrumentationKey = "@Microsoft.ApplicationInsights.Extensibility.TelemetryConfiguration.Active.InstrumentationKey";
</script>
@Scripts.Render("~/bundles/headsitejs")
@*
<script language="javascript">
window.instrumentationKey = "@Microsoft.ApplicationInsights.Extensibility.TelemetryConfiguration.Active.InstrumentationKey";
</script>
*@
@*Scripts.Render("~/bundles/headsitejs")*@
</head>
<body class="@ViewBag.PageStyle">
<header class="header navbar navbar-inverse navbar-fixed-top" role="banner">
Expand Down
156 changes: 81 additions & 75 deletions source/Glimpse.Site/Web.config
Original file line number Diff line number Diff line change
Expand Up @@ -5,131 +5,137 @@
-->
<configuration>
<configSections>
<section name="glimpsePackage" type="Glimpse.Package.ConfigSectionGlimpse, Glimpse.Package"/>
<section name="glimpsePackage" type="Glimpse.Package.ConfigSectionGlimpse, Glimpse.Package" />
</configSections>
<appSettings file="secrets.config">
<add key="webpages:Version" value="3.0.0.0"/>
<add key="webpages:Enabled" value="false"/>
<add key="ClientValidationEnabled" value="true"/>
<add key="UnobtrusiveJavaScriptEnabled" value="true"/>
<add key="GlimpseConnection" value="glimpse"/>
<add key="TwitterKey" value="VALUE STORED IN WINDOWS AZURE"/>
<add key="TwitterSecret" value="VALUE STORED IN WINDOWS AZURE"/>
<add key="GitHubKey" value="VALUE STORED IN WINDOWS AZURE"/>
<add key="GitHubSecret" value="VALUE STORED IN WINDOWS AZURE"/>
<add key="webpages:Version" value="3.0.0.0" />
<add key="webpages:Enabled" value="false" />
<add key="ClientValidationEnabled" value="true" />
<add key="UnobtrusiveJavaScriptEnabled" value="true" />
<add key="GlimpseConnection" value="glimpse" />
<add key="TwitterKey" value="VALUE STORED IN WINDOWS AZURE" />
<add key="TwitterSecret" value="VALUE STORED IN WINDOWS AZURE" />
<add key="GitHubKey" value="VALUE STORED IN WINDOWS AZURE" />
<add key="GitHubSecret" value="VALUE STORED IN WINDOWS AZURE" />
</appSettings>
<system.web>
<compilation debug="true" targetFramework="4.5"/>
<httpRuntime targetFramework="4.5"/>
<customErrors mode="RemoteOnly"/>
<httpModules>
<add name="ApplicationInsightsWebTracking" type="Microsoft.ApplicationInsights.Web.ApplicationInsightsHttpModule, Microsoft.AI.Web"/>
<compilation debug="true" targetFramework="4.5">
<assemblies>
<add assembly="System.Runtime.Caching, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<add assembly="System.Net.Http.WebRequest, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
</assemblies>
</compilation>
<httpRuntime targetFramework="4.5" />
<customErrors mode="RemoteOnly" />
<!--
<httpModules>
<add name="ApplicationInsightsWebTracking" type="Microsoft.ApplicationInsights.Web.ApplicationInsightsHttpModule, Microsoft.AI.Web" />
</httpModules>
-->
</system.web>
<glimpsePackage>
<!-- useOfflineData="false" -->
<logging logEverything="true" enabled="false"/>
<services minTriggerInterval="300000"/>
<logging logEverything="true" enabled="false" />
<services minTriggerInterval="300000" />
</glimpsePackage>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/>
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="0.0.0.0-5.1.0.0" newVersion="5.1.0.0"/>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="0.0.0.0-5.1.0.0" newVersion="5.1.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Optimization" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0"/>
<assemblyIdentity name="System.Web.Optimization" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/>
<assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="0.0.0.0-1.6.5135.21930" newVersion="1.6.5135.21930"/>
<assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="0.0.0.0-1.6.5135.21930" newVersion="1.6.5135.21930" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral"/>
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0"/>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Http" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
<bindingRedirect oldVersion="0.0.0.0-5.1.0.0" newVersion="5.1.0.0"/>
<assemblyIdentity name="System.Web.Http" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-5.1.0.0" newVersion="5.1.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Net.Http.Formatting" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
<bindingRedirect oldVersion="0.0.0.0-5.1.0.0" newVersion="5.1.0.0"/>
<assemblyIdentity name="System.Net.Http.Formatting" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-5.1.0.0" newVersion="5.1.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Antlr3.Runtime" publicKeyToken="eb42632606e9261f" culture="neutral"/>
<bindingRedirect oldVersion="0.0.0.0-3.5.0.2" newVersion="3.5.0.2"/>
<assemblyIdentity name="Antlr3.Runtime" publicKeyToken="eb42632606e9261f" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-3.5.0.2" newVersion="3.5.0.2" />
</dependentAssembly>
</assemblyBinding>
</runtime>
<system.webServer>
<staticContent>
<remove fileExtension=".woff"/>
<mimeMap fileExtension=".woff" mimeType="application/x-font-woff"/>
<remove fileExtension=".woff" />
<mimeMap fileExtension=".woff" mimeType="application/x-font-woff" />
</staticContent>
<validation validateIntegratedModeConfiguration="false"/>
<validation validateIntegratedModeConfiguration="false" />
<httpRedirect enabled="true" exactDestination="true" httpResponseStatus="Found">
<add wildcard="/Help/Plugin/*" destination="/Docs/"/>
<add wildcard="/Help/Configuration/*" destination="/Docs/"/>
<add wildcard="/Help/CreatingPlugins*" destination="/Docs/"/>
<add wildcard="/Help/Setup*" destination="/Docs/"/>
<add wildcard="/Help/Getting-started*" destination="/Getting-started/"/>
<add wildcard="/About/Details*" destination="/Docs/"/>
<add wildcard="/About/Platforms*" destination="/Docs/"/>
<add wildcard="/About/QuickStart*" destination="/Docs/"/>
<add wildcard="/Questions*" destination="/Docs/"/>
<add wildcard="/About*" destination="/"/>
<add wildcard="/About/Credits*" destination="/Community"/>
<add wildcard="/Packages" destination="/Extensions"/>
<add wildcard="/Support" destination="/Community"/>
<add wildcard="/Help/Plugin/*" destination="/Docs/" />
<add wildcard="/Help/Configuration/*" destination="/Docs/" />
<add wildcard="/Help/CreatingPlugins*" destination="/Docs/" />
<add wildcard="/Help/Setup*" destination="/Docs/" />
<add wildcard="/Help/Getting-started*" destination="/Getting-started/" />
<add wildcard="/About/Details*" destination="/Docs/" />
<add wildcard="/About/Platforms*" destination="/Docs/" />
<add wildcard="/About/QuickStart*" destination="/Docs/" />
<add wildcard="/Questions*" destination="/Docs/" />
<add wildcard="/About*" destination="/" />
<add wildcard="/About/Credits*" destination="/Community" />
<add wildcard="/Packages" destination="/Extensions" />
<add wildcard="/Support" destination="/Community" />
</httpRedirect>
<rewrite>
<rules>
<rule name="RemoveWWW" stopProcessing="true">
<match url="^(.*)$"/>
<match url="^(.*)$" />
<conditions>
<add input="{HTTP_HOST}" pattern="^(www\.)(.*)$"/>
<add input="{HTTP_HOST}" pattern="^(www\.)(.*)$" />
</conditions>
<action type="Redirect" url="http://getglimpse.com{PATH_INFO}" redirectType="Permanent"/>
<action type="Redirect" url="http://getglimpse.com{PATH_INFO}" redirectType="Permanent" />
</rule>
<rule name="Redirect from Help to Doc">
<match url="^Help/([_0-9a-z-]+)"/>
<action type="Redirect" url="Docs/{R:1}" redirectType="Found"/>
<match url="^Help/([_0-9a-z-]+)" />
<action type="Redirect" url="Docs/{R:1}" redirectType="Found" />
</rule>
</rules>
</rewrite>
</rewrite>
<httpErrors errorMode="Custom" existingResponse="Replace">
<remove statusCode="500"/>
<remove statusCode="404"/>
<remove statusCode="401"/>
<error statusCode="401" responseMode="ExecuteURL" path="/Error/Unauthorized"/>
<error statusCode="404" responseMode="ExecuteURL" path="/Error/NotFound"/>
<error statusCode="500" responseMode="ExecuteURL" path="/Error/ServerError"/>
<remove statusCode="500" />
<remove statusCode="404" />
<remove statusCode="401" />
<error statusCode="401" responseMode="ExecuteURL" path="/Error/Unauthorized" />
<error statusCode="404" responseMode="ExecuteURL" path="/Error/NotFound" />
<error statusCode="500" responseMode="ExecuteURL" path="/Error/ServerError" />
</httpErrors>
<handlers>
<remove name="ExtensionlessUrlHandler-Integrated-4.0"/>
<remove name="OPTIONSVerbHandler"/>
<remove name="TRACEVerbHandler"/>
<add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="*" type="System.Web.Handlers.TransferRequestHandler"
preCondition="integratedMode,runtimeVersionv4.0"/>
<remove name="ExtensionlessUrlHandler-Integrated-4.0" />
<remove name="OPTIONSVerbHandler" />
<remove name="TRACEVerbHandler" />
<add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="*" type="System.Web.Handlers.TransferRequestHandler" preCondition="integratedMode,runtimeVersionv4.0" />
</handlers>
<modules>
<remove name="ApplicationInsightsWebTracking"/>
<add name="ApplicationInsightsWebTracking" type="Microsoft.ApplicationInsights.Web.ApplicationInsightsHttpModule, Microsoft.AI.Web"
preCondition="managedHandler"/>
<!--
<modules>
<remove name="ApplicationInsightsWebTracking" />
<add name="ApplicationInsightsWebTracking" type="Microsoft.ApplicationInsights.Web.ApplicationInsightsHttpModule, Microsoft.AI.Web" preCondition="managedHandler" />
</modules>
-->
</system.webServer>
<connectionStrings>
<add name="glimpse" connectionString="Server=(localdb)\v11.0;Integrated Security=true;AttachDbFileName=|DataDirectory|Glimpse.mdf;"
providerName="System.Data.SqlClient"/>
<add name="glimpse" connectionString="Server=(localdb)\v11.0;Integrated Security=true;AttachDbFileName=|DataDirectory|Glimpse.mdf;" providerName="System.Data.SqlClient" />
</connectionStrings>
</configuration>
</configuration>

0 comments on commit 487799b

Please sign in to comment.