<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Dot Net Nuke Archives | DMC, Inc.</title>
	<atom:link href="https://static.dmcinfo.com/blog/tag/dot-net-nuke/feed/index.xml" rel="self" type="application/rss+xml" />
	<link></link>
	<description></description>
	<lastBuildDate>Fri, 24 Jul 2026 19:09:02 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.2</generator>

<image>
	<url>https://static.dmcinfo.com/wp-content/uploads/2025/04/site-icon-150x150.png</url>
	<title>Dot Net Nuke Archives | DMC, Inc.</title>
	<link></link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>6 Easy Steps to Get Started with MVC Module Development in DNN 8</title>
		<link>https://static.dmcinfo.com/blog/25071/6-easy-steps-to-get-started-with-mvc-module-development-in-dnn-8/</link>
		
		<dc:creator><![CDATA[DMC]]></dc:creator>
		<pubDate>Fri, 14 Oct 2016 12:37:43 +0000</pubDate>
				<category><![CDATA[Web Application Development]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C# .NET Application Development]]></category>
		<category><![CDATA[Dot Net Nuke]]></category>
		<category><![CDATA[HTML and CSS]]></category>
		<category><![CDATA[MS Visual Studio/.NET]]></category>
		<category><![CDATA[Software Development]]></category>
		<category><![CDATA[Web]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/25071/6-easy-steps-to-get-started-with-mvc-module-development-in-dnn-8/</guid>

					<description><![CDATA[<p>In the beginning of the year,&#160;DNN (formerly DotNetNuke) was updated to support MVC modules. MVC is the latest version of ASP.NET in which the Model-View-Controller paradigm is at the core.&#160;This article won&#8217;t be a look into what MVC is or a comparison with WebForms, but instead will give a quick guide into starting DNN MVC [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/25071/6-easy-steps-to-get-started-with-mvc-module-development-in-dnn-8/">6 Easy Steps to Get Started with MVC Module Development in DNN 8</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">In the beginning of the year,&nbsp;DNN (formerly DotNetNuke) was updated to support MVC modules. MVC is the latest version of ASP.NET in which the Model-View-Controller paradigm is at the core.&nbsp;This article won&#8217;t be a look into what MVC is or a comparison with WebForms, but instead will give a quick guide into starting DNN MVC module development.</p>



<p class="wp-block-paragraph">While there are some guides available that give you similar information, I found it a bit difficult to get started developing MVC modules in DNN. For reference, the articles I used are at the bottom of this blog.</p>



<p class="wp-block-paragraph">Here&#8217;s an overview of the steps we&#8217;ll take to get started.</p>



<ol class="wp-block-list">
<li><a href="#prerequisites">Prerequisites</a></li>



<li><a href="#templates">Templates</a></li>



<li><a href="#setup">Setup</a></li>



<li><a href="#build">Build</a></li>



<li><a href="#installation">Installation</a></li>



<li><a href="#next-steps">Next Steps</a></li>



<li><a href="#references">References</a></li>
</ol>



<h2 id="prerequisites" class="wp-block-heading">1. Prerequisites</h2>



<p class="wp-block-paragraph">For this quick start, you&#8217;ll need a few things before we can dive in.</p>



<p class="wp-block-paragraph">First, you&#8217;ll need to have Visual Studio 2015 installed. The express editions have been reported to be incompatible with the templates we&#8217;ll be using later, but this may not be true by the time you&#8217;re reading this.</p>



<p class="wp-block-paragraph">Next, you&#8217;ll need to have IIS (Internet Information Services) setup with a local installation of DNN (version 8 or higher). There are many tutorials on how to do this around the web. You&#8217;ll need to install IIS and&nbsp;Microsoft SQL Server, then you can install DNN by downloading the latest _install.zip from <a href="https://github.com/dnnsoftware/Dnn.Platform/releases" target="_blank">DNN&#8217;s GitHub releases</a>.</p>



<p class="wp-block-paragraph">Once those are all set up, you&#8217;re ready to go.</p>



<h2 id="templates" class="wp-block-heading">2. Templates</h2>



<p class="wp-block-paragraph">You <em>could&nbsp;</em>create a module from scratch. But why would you do that when a DNN expert created templates for you to use? <a href="https://marketplace.visualstudio.com/items?itemName=Chris-Hammond.DotNetNukeDNNDevelopmentProjectTemplates" target="_blank" rel="noreferrer noopener">Download the templates from the Visual Studio Gallery</a>&nbsp;and run through the installation procedure.</p>



<h2 id="setup" class="wp-block-heading">3. Setup</h2>



<p class="wp-block-paragraph">Now that everything is set up, we can actually dive into creating the module.&nbsp;</p>



<p class="wp-block-paragraph">In Visual Studio, select File -&gt; New -&gt; Project</p>



<p class="wp-block-paragraph">In the New Project window, select Templates -&gt; Visual C# -&gt; DotNetNuke and you&#8217;ll see a listing of the types of projects the templates have provided.</p>



<p class="wp-block-paragraph">To create an MVC module, we&#8217;ll select DotNetNuke 8 C# DAL2 MVC Module. There are three other fields we must configure: Name, Location, and Solution name.</p>



<p class="wp-block-paragraph"><strong>Name: </strong>Enter a name for your project (it&#8217;s best not to use any spaces or special characters for this)</p>



<p class="wp-block-paragraph"><strong>Location:&nbsp;</strong>This is important to point this to the correct folder in DNN: /DesktopModules/MVC/.&nbsp;Depending on your installation directory, the folder should be something like C:\Dev\Projects\DMC_Website\Alpha\DesktopModules\MVC\ where &#8220;Alpha&#8221; is the root of your DNN installation.</p>



<p class="wp-block-paragraph"><strong>Solution name:</strong>&nbsp;We&#8217;re not actually going to be using this field. Uncheck&nbsp;the box on the right that says &#8220;Create directory for solution&#8221; and the solution name textbox will be greyed out.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/2016-10-28-12_40_42-New-Project.png" alt="Configuration of the DotNetNuke 8 C# DAL2 MVC Module Visual Studio Project"/></figure>



<p class="wp-block-paragraph">Confirm your settings look similar to mine and then click OK.</p>



<p class="wp-block-paragraph">A Project Setup Wizard dialog box will appear asking for some project information. Many of these are self explanatory, so I will only address the two that are a bit tricky.</p>



<p class="wp-block-paragraph"><strong>Namespace: </strong>Whatever namespace you want your module to live in. The templates will automatically include your project name in the namespace, so no need to enter it here.&nbsp;Make sure you include the last period. E.g. DMC.</p>



<p class="wp-block-paragraph"><strong>Local Dev URL:&nbsp;</strong>By default this is set up to point to dnndev.me, which is actually set up to point back to 127.0.0.1 (your localhost). What you enter here depends on what settings you&#8217;ve set your DNN install up with. For my installation, I access my local DNN install through http://localhost./ Therefore, I am going to enter localhost as my Local Dev URL.</p>



<p class="wp-block-paragraph">Initial values</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/2016-10-14-12_49_25-Project-Setup-Wizard.png" alt="DNN Template Setup Wizard Initial Values"/></figure>



<p class="wp-block-paragraph">Updated values (note: the owner website field includes https:// but the textbox isn&#8217;t large enough to display it. Be sure to include it in your URL.)</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/2016-10-28-12_42_14-Project-Setup-Wizard.png" alt="DNN Template Setup Wizard Updated Values"/></figure>



<p class="wp-block-paragraph">Once all fields have been complete, click OK.</p>



<h2 id="build" class="wp-block-heading">4. Build</h2>



<p class="wp-block-paragraph">Now that the initial project setup is complete, you&#8217;ll be presented with a web page in Visual Studio that says * Important *. These are steps that you should&nbsp;<strong>read carefully</strong>&nbsp;and follow to ensure your project will work correctly. I&#8217;ll provide a quick overview of these steps in case the original wording is confusing for anyone.</p>



<p class="wp-block-paragraph">First, check IIS to see if any of your folders were converted to virtual directories or applications. To do this, open IIS, expand your site&#8217;s dropdown and check what icon is displayed next to your DesktopModules folder or the MVC folder inside of the DesktopModules folder. If it&#8217;s anything other than a yellow folder, right click it and click remove.</p>



<p class="wp-block-paragraph">Next, in Visual Studio, right click and delete the web.config files that are in the solution.</p>



<p class="wp-block-paragraph">You can now build the module! change the solution configuration dropdown from Debug to Release and then select Build -&gt; Build</p>



<p class="wp-block-paragraph">You&#8217;ll get an install .zip file in your module&#8217;s install/ directory.</p>



<h2 id="installation" class="wp-block-heading">5. Installation</h2>



<p class="wp-block-paragraph">Now, in DNN, go to Hosts -&gt; Extensions and click Install Extension, selecting your install .zip file that you previously built.</p>



<p class="wp-block-paragraph">If everything goes well, then the module is now installed and can be placed on any page.</p>



<h2 id="next-steps" class="wp-block-heading">6. Next Steps</h2>



<p class="wp-block-paragraph">Once you&#8217;ve dragged the module into a page, you&#8217;ll see a demo application that includes multiple views, database interaction, and more. Simply build the project in debug mode to automatically copy the new DLL to the /bin folder.</p>



<h2 id="references" class="wp-block-heading">7. References</h2>



<ul class="wp-block-list">
<li><a href="https://www.chrishammond.com/tag/dotnetnuke" type="link" id="https://www.chrishammond.com/tag/dotnetnuke" target="_blank" rel="noreferrer noopener">Chris Hammond&#8217;s DNN posts</a></li>



<li><a href="https://dnncommunity.org/blogs" type="link" id="https://dnncommunity.org/blogs" target="_blank" rel="noreferrer noopener">DNN Community Blogs</a></li>



<li><a href="https://www.dnnsoftware.com/docs/developers/mvc-modules/mvc-module-development.html" type="link" id="https://www.dnnsoftware.com/docs/developers/mvc-modules/mvc-module-development.html" target="_blank" rel="noreferrer noopener">DNN MVC Module Development</a></li>
</ul>



<p class="wp-block-paragraph">While you&#8217;re here, check out DMC&#8217;s <a href="/services/application-development/web-application-development">Web Application Development</a> and <a href="/services/application-development/web-application-development/aspnet-and-aspnet-mvc">ASP.NET &amp; ASP.NET MVC Development</a> services so we can get started on your next DNN MVC module!</p>



<p class="wp-block-paragraph"></p>
<p>The post <a href="https://static.dmcinfo.com/blog/25071/6-easy-steps-to-get-started-with-mvc-module-development-in-dnn-8/">6 Easy Steps to Get Started with MVC Module Development in DNN 8</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Automating Web Development &#8211; Tools</title>
		<link>https://static.dmcinfo.com/blog/26709/automating-web-development-tools/</link>
		
		<dc:creator><![CDATA[DMC]]></dc:creator>
		<pubDate>Tue, 07 Apr 2015 12:27:34 +0000</pubDate>
				<category><![CDATA[Web Application Development]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Dot Net Nuke]]></category>
		<category><![CDATA[HTML and CSS]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[Web]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/26709/automating-web-development-tools/</guid>

					<description><![CDATA[<p>I’ve been working on a new DNN skin for a while now and much progress is being made. Along the way, I’ve learned about tools that can help speed up website development drastically. In this blog post, I’ll give an overview of these tools and how to use them by themselves and together to harness [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/26709/automating-web-development-tools/">Automating Web Development &#8211; Tools</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">I’ve been working on a new DNN skin for a while now and much progress is being made. Along the way, I’ve learned about tools that can help speed up website development drastically. In this blog post, I’ll give an overview of these tools and how to use them by themselves and together to harness the power of automation and simplify development tasks.</p>



<h2 id="h-tools" class="wp-block-heading">Tools</h2>



<ul class="wp-block-list">
<li><a href="#ruby">Ruby</a></li>



<li><a href="#sass-or-less">Sass (or Less)</a></li>



<li><a href="#nodejs">Node.js</a></li>



<li><a href="#npm">npm</a></li>



<li><a href="#bower">Bower</a></li>



<li><a href="#grunt-or-gulp">Grunt or gulp</a></li>
</ul>



<h3 id="ruby" class="wp-block-heading">Ruby</h3>



<p class="wp-block-paragraph">We won’t be using Ruby as a programming language, but we will be needing it to install SASS.</p>



<p class="wp-block-paragraph">If you’re on Windows, download the <a href="https://rubyinstaller.org/" type="link" id="https://rubyinstaller.org/" target="_blank" rel="noreferrer noopener">latest version of Ruby</a></p>



<p class="wp-block-paragraph">If you’re on Linux or OS X, there are <a href="https://rvm.io/rvm/install" type="link" id="https://rvm.io/rvm/install" target="_blank" rel="noreferrer noopener">instructions you can follow</a></p>



<p class="wp-block-paragraph">Or, after installing cURL, run this in a terminal window:</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">Bash</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>\curl -sSL https://get.rvm.io/ | bash</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #DCDCAA">\curl</span><span style="color: #D4D4D4"> </span><span style="color: #569CD6">-sSL</span><span style="color: #D4D4D4"> </span><span style="color: #CE9178">https://get.rvm.io/</span><span style="color: #D4D4D4"> | </span><span style="color: #DCDCAA">bash</span></span></code></pre></div>



<p class="wp-block-paragraph">Once Ruby has finished installing, no matter what platform you’re on, open a terminal window and run</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">Bash</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>ruby -v</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #DCDCAA">ruby</span><span style="color: #D4D4D4"> </span><span style="color: #569CD6">-v</span></span></code></pre></div>



<p class="wp-block-paragraph">to ensure it has installed properly.</p>



<h3 id="sass-or-less" class="wp-block-heading">Sass (Syntactically Awesome Style Sheets) or Less</h3>



<p class="wp-block-paragraph">Sass is basically CSS with a ton of awesome features layered on top. Using Sass, which compiles to clean and efficient CSS, one can make use of extended abilities like variables, mixing, inline imports, and more.</p>



<p class="wp-block-paragraph">There is another CSS extension called Less, which is an alternative to Sass. I prefer Sass, but you could definitely adapt this tutorial to work with Less as well.</p>



<p class="wp-block-paragraph">Anyhow, now that Ruby is installed and ready to go, installing Sass is easy.</p>



<p class="wp-block-paragraph">In a terminal window, type</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">Bash</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>gem install sass</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #DCDCAA">gem</span><span style="color: #D4D4D4"> </span><span style="color: #CE9178">install</span><span style="color: #D4D4D4"> </span><span style="color: #CE9178">sass</span></span></code></pre></div>



<p class="wp-block-paragraph">Once that is finished, run</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">Bash</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>sass -v</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #DCDCAA">sass</span><span style="color: #D4D4D4"> </span><span style="color: #569CD6">-v</span></span></code></pre></div>



<p class="wp-block-paragraph">to ensure it has installed properly.</p>



<h3 id="nodejs" class="wp-block-heading">Node.js</h3>



<p class="wp-block-paragraph">Node.js is tool that allows one to write simple JavaScript programs that create powerful applications.</p>



<p class="wp-block-paragraph">We’ll be using Node.js to power npm (node package manager), Bower, and Grunt.</p>



<p class="wp-block-paragraph"><a href="https://nodejs.org/download/" type="link" id="https://nodejs.org/download/" target="_blank" rel="noreferrer noopener">Grab the proper download for your platform</a></p>



<p class="wp-block-paragraph">To install Node.js on Windows or OS X, simply run the installers.</p>



<p class="wp-block-paragraph">On Linux, you can build Node.js by using these steps:</p>



<p class="wp-block-paragraph">Extract the downloaded archive and open a terminal window</p>



<p class="wp-block-paragraph">1. Navigate to where you extracted the archive</p>



<p class="wp-block-paragraph">2. Run</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">JavaScript</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>./configure</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #D4D4D4">./</span><span style="color: #9CDCFE">configure</span></span></code></pre></div>



<p class="wp-block-paragraph">3. Run and wait patiently</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">JavaScript</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>make</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #9CDCFE">make</span></span></code></pre></div>



<p class="wp-block-paragraph">4. Run</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">JavaScript</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>sudo make install</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #9CDCFE">sudo</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">make</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">install</span></span></code></pre></div>



<p class="wp-block-paragraph">And you’ll be all set with Node.js.</p>



<h3 id="npm" class="wp-block-heading">npm</h3>



<p class="wp-block-paragraph">npm is the official package manager for Node.js. What this means is that using npm, one can install hundreds of different applications and tools that are built with Node.js.</p>



<p class="wp-block-paragraph">We’ll be using npm to install Bower and Grunt.</p>



<p class="wp-block-paragraph">npm comes installed with Node.js, so there are no additional steps required to install it.</p>



<h3 id="bower" class="wp-block-heading">Bower</h3>



<p class="wp-block-paragraph">Bower, much like npm, is a package manager. However, npm only deals with Node.js packages while Bower titles itself “a package manager for the web.” Using Bower, one can run a simple terminal command to download and install many different web libraries or frameworks, such as jQuery, Bootstrap, FontAwesome, and more.</p>



<p class="wp-block-paragraph">To install Bower, open a terminal window and type:</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">JavaScript</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>npm install -g bower</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #9CDCFE">npm</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">install</span><span style="color: #D4D4D4"> -</span><span style="color: #9CDCFE">g</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">bower</span></span></code></pre></div>



<p class="wp-block-paragraph">(The -g flag is to install bower globally, so we can call it from the command line anywhere)</p>



<h3 id="grunt-or-gulp" class="wp-block-heading">Grunt or gulp</h3>



<p class="wp-block-paragraph">Grunt is a task runner that performs the time-consuming, repetitive tasks that come along with website development like minification, SASS compilation, and more.&nbsp;</p>



<p class="wp-block-paragraph">Thanks to npm, Grunt is just as easy to install as Bower:</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">JavaScript</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>npm install -g grunt-cli</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #9CDCFE">npm</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">install</span><span style="color: #D4D4D4"> -</span><span style="color: #9CDCFE">g</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">grunt</span><span style="color: #D4D4D4">-</span><span style="color: #9CDCFE">cli</span></span></code></pre></div>



<p class="wp-block-paragraph">gulp (don’t you ever capitalize that g) is a similar tool that <em>should</em> provide better performance than Grunt because it uses Node.js’s streams.</p>



<p class="wp-block-paragraph">npm comes in handy once again. Install gulp with:</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">JavaScript</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>npm install -g gulp</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #9CDCFE">npm</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">install</span><span style="color: #D4D4D4"> -</span><span style="color: #9CDCFE">g</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">gulp</span></span></code></pre></div>



<h2 id="h-beginning-automation" class="wp-block-heading">Beginning Automation</h2>



<p class="wp-block-paragraph">Now that we have all of the tools we need to begin, we can finally start creating an automated build system.</p>



<p class="wp-block-paragraph">There are tasks associated with web development that quickly become repetitive and mundane. Thankfully, we will no longer have to do these manually!</p>



<p class="wp-block-paragraph">The tasks that we can now automate are (in no particular order):</p>



<ul class="wp-block-list">
<li>Sass (or Less) compilation (converting our Sass or Less to standard CSS)</li>



<li>Concatenation (combining multiple files into one)</li>



<li>Minification (smushing text together to reduce the size, making it load faster)</li>



<li>Linting (automatically checking code for errors)</li>



<li>Copying of files (like fonts)</li>



<li>Adding vendor-specific prefixes to our CSS (ensuring compatibility across browsers)</li>



<li>Detecting features that we require a user’s browser to have</li>



<li>More that I can’t think of!</li>
</ul>



<p class="wp-block-paragraph">And best of all, the build system will be smart enough to understand when a particular file changes to prevent rebuilding the entire thing.</p>



<p class="wp-block-paragraph">Stay tuned for the next article! For now, you can always take a look at DMC&#8217;s <a href="/services/application-development/web-application-development">Web Application Development</a> services, where we can harness the technologies outlined above for your needs.</p>



<p class="wp-block-paragraph"></p>
<p>The post <a href="https://static.dmcinfo.com/blog/26709/automating-web-development-tools/">Automating Web Development &#8211; Tools</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>DMC&#8217;s Blog Now Features a Nifty Code Syntax Highlighter</title>
		<link>https://static.dmcinfo.com/blog/30194/dmcs-blog-now-features-a-nifty-code-syntax-highlighter/</link>
		
		<dc:creator><![CDATA[Tim Jager]]></dc:creator>
		<pubDate>Sun, 06 Sep 2009 00:22:36 +0000</pubDate>
				<category><![CDATA[Web Application Development]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Dot Net Nuke]]></category>
		<category><![CDATA[HTML and CSS]]></category>
		<category><![CDATA[Web]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/30194/dmcs-blog-now-features-a-nifty-code-syntax-highlighter/</guid>

					<description><![CDATA[<p>Check out the nifty new code syntax highlighter we&#8217;ve added to the blog.&#160; This will make it much easier for us to post code snippets. Here&#8217;s a sample c# function that is automatically formatted. Also note the handy tools on the upper right corner of the code box. Just hover your mouse over the upper [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/30194/dmcs-blog-now-features-a-nifty-code-syntax-highlighter/">DMC&#8217;s Blog Now Features a Nifty Code Syntax Highlighter</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">Check out the nifty new <a href="http://alexgorbatchev.com/wiki/SyntaxHighlighter" target="_blank">code syntax highlighter</a> we&#8217;ve added to the blog.&nbsp; This will make it much easier for us to post code snippets. Here&#8217;s a sample c# function that is automatically formatted. Also note the handy tools on the upper right corner of the code box. Just hover your mouse over the upper right corner and you can view, copy, or print the code.&nbsp;</p>



<p class="wp-block-paragraph">&nbsp;</p>



<p class="wp-block-paragraph">&nbsp;</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">C#</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>using System;

namespace MyNameSpace
{
    class HelloWorld
    {
        static void Main(string[] args)
        {
            Console.WriteLine ("Hello World");
        }
    }
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #C586C0">using</span><span style="color: #D4D4D4"> </span><span style="color: #4EC9B0">System</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #569CD6">namespace</span><span style="color: #D4D4D4"> </span><span style="color: #4EC9B0">MyNameSpace</span></span>
<span class="line"><span style="color: #D4D4D4">{</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #569CD6">class</span><span style="color: #D4D4D4"> </span><span style="color: #4EC9B0">HelloWorld</span></span>
<span class="line"><span style="color: #D4D4D4">    {</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #569CD6">static</span><span style="color: #D4D4D4"> </span><span style="color: #569CD6">void</span><span style="color: #D4D4D4"> </span><span style="color: #DCDCAA">Main</span><span style="color: #D4D4D4">(</span><span style="color: #569CD6">string</span><span style="color: #D4D4D4">[] </span><span style="color: #9CDCFE">args</span><span style="color: #D4D4D4">)</span></span>
<span class="line"><span style="color: #D4D4D4">        {</span></span>
<span class="line"><span style="color: #D4D4D4">            </span><span style="color: #9CDCFE">Console</span><span style="color: #D4D4D4">.</span><span style="color: #DCDCAA">WriteLine</span><span style="color: #D4D4D4"> (</span><span style="color: #CE9178">&quot;Hello World&quot;</span><span style="color: #D4D4D4">);</span></span>
<span class="line"><span style="color: #D4D4D4">        }</span></span>
<span class="line"><span style="color: #D4D4D4">    }</span></span>
<span class="line"><span style="color: #D4D4D4">}</span></span></code></pre></div>



<p class="wp-block-paragraph">&nbsp;</p>



<p class="wp-block-paragraph">&nbsp;</p>



<p class="wp-block-paragraph">Special thanks to <a href="http://alexgorbatchev.com/" target="_blank">Alex Gorbatchev</a> for creating such a handy open source code highlighter module.</p>
<p>The post <a href="https://static.dmcinfo.com/blog/30194/dmcs-blog-now-features-a-nifty-code-syntax-highlighter/">DMC&#8217;s Blog Now Features a Nifty Code Syntax Highlighter</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>CSS and How to Center Images of Unknown Size</title>
		<link>https://static.dmcinfo.com/blog/30222/css-and-how-to-center-images-of-unknown-size/</link>
		
		<dc:creator><![CDATA[DMC]]></dc:creator>
		<pubDate>Mon, 24 Aug 2009 12:18:50 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Dot Net Nuke]]></category>
		<category><![CDATA[HTML and CSS]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/30222/css-and-how-to-center-images-of-unknown-size/</guid>

					<description><![CDATA[<p>When DMC launched our new website a few months ago, we were quite happy with some of the new skills and tricks we learned. One area where I learned quite a bit more, in particular, was CSS, or Cascading Style Sheets, and HTML style tags. One issue we had to overcome involved centering images of [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/30222/css-and-how-to-center-images-of-unknown-size/">CSS and How to Center Images of Unknown Size</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">When DMC <a href="https://static.dmcinfo.com/blog/30400/dmc-launches-new-website/">launched our new website</a> a few months ago, we were quite happy with some of the new skills and tricks we learned. One area where I learned quite a bit more, in particular, was CSS, or Cascading Style Sheets, and HTML style tags.</p>



<p class="wp-block-paragraph">One issue we had to overcome involved centering images of varying or unknown size. We use a content rotator module on our website. There are numerous content rotator modules available for Dot Net Nuke. The content rotator we used comes from a company called MexMax.</p>



<p class="wp-block-paragraph">You will notice on our home page that we use this content rotator to scroll through our list of clients. To make the layout pleasing to the eye, we had to center all of the images. If you search for a tutorial on how to do this, you will find that they all involve hard coding in height values and assume that you know the size of your image and the size of the space you are trying to fit it in. We could have used this and gone the route of always forcing the client logos to be the same size, but I wanted something more modular.</p>



<p class="wp-block-paragraph">Here is what we came up with:</p>


<div class="RotatorImgCenterWrap1">
<div class="RotatorImgCenterWrap2">
<div class="RotatorImgCenterWrap3">
<div class="RotatorImgCenterWrap4"><img decoding="async" alt="Old DMC Logo" height="41" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/DMC_logo.jpg" width="125" /></div>
</div>
</div>
</div>


<p class="wp-block-paragraph">We wrapped the image in four separate divs and gave each div a class name:</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">HTML</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>&lt;div class="RotatorImgCenterWrap1">
    &lt;div class="RotatorImgCenterWrap2">
        &lt;div class="RotatorImgCenterWrap3">
            &lt;div class="RotatorImgCenterWrap4">
                &lt;aink.aspx
                    &lt;img
                        src="/Image.jpg"
                        width="175"
                        height</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #808080">&lt;</span><span style="color: #569CD6">div</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">class</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;RotatorImgCenterWrap1&quot;</span><span style="color: #808080">&gt;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #808080">&lt;</span><span style="color: #569CD6">div</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">class</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;RotatorImgCenterWrap2&quot;</span><span style="color: #808080">&gt;</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #808080">&lt;</span><span style="color: #569CD6">div</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">class</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;RotatorImgCenterWrap3&quot;</span><span style="color: #808080">&gt;</span></span>
<span class="line"><span style="color: #D4D4D4">            </span><span style="color: #808080">&lt;</span><span style="color: #569CD6">div</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">class</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;RotatorImgCenterWrap4&quot;</span><span style="color: #808080">&gt;</span></span>
<span class="line"><span style="color: #D4D4D4">                </span><span style="color: #808080">&lt;</span><span style="color: #F44747">aink.aspx</span></span>
<span class="line"><span style="color: #D4D4D4">                    </span><span style="color: #F44747">&lt;img</span></span>
<span class="line"><span style="color: #D4D4D4">                        </span><span style="color: #9CDCFE">src</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;/Image.jpg&quot;</span></span>
<span class="line"><span style="color: #D4D4D4">                        </span><span style="color: #9CDCFE">width</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;175&quot;</span></span>
<span class="line"><span style="color: #D4D4D4">                        </span><span style="color: #9CDCFE">height</span></span></code></pre></div>



<p class="wp-block-paragraph">Next we set the CSS for each class as follows:</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">CSS</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>div.RotatorImgCenterWrap1 {
}

div.RotatorImgCenterWrap2 {
    display: table;
    height: 100%;
    width: 100%;

    /* Old IE hacks */
    #position: relative;

    overflow: hidden;
}

div.RotatorImgCenterWrap3 {
    /* Old IE hacks */
    #position: absolute;
    #top: 50%;

    width: 100%;
    display: table-cell;
    vertical-align: middle;
}

div.RotatorImgCenterWrap4 {
    /* Old IE hacks */
    #position: relative;
    #top: -50%;

    width: 100%;
    text-align: center;
}

.RotatorImgCenterWrap4 img {
    vertical-align: middle;
}</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #D7BA7D">div.RotatorImgCenterWrap1</span><span style="color: #D4D4D4"> {</span></span>
<span class="line"><span style="color: #D4D4D4">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D7BA7D">div.RotatorImgCenterWrap2</span><span style="color: #D4D4D4"> {</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">display</span><span style="color: #D4D4D4">: </span><span style="color: #CE9178">table</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">height</span><span style="color: #D4D4D4">: </span><span style="color: #B5CEA8">100%</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">width</span><span style="color: #D4D4D4">: </span><span style="color: #B5CEA8">100%</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #6A9955">/* Old IE hacks */</span></span>
<span class="line"><span style="color: #D4D4D4">    #</span><span style="color: #9CDCFE">position</span><span style="color: #D4D4D4">: </span><span style="color: #CE9178">relative</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">overflow</span><span style="color: #D4D4D4">: </span><span style="color: #CE9178">hidden</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D7BA7D">div.RotatorImgCenterWrap3</span><span style="color: #D4D4D4"> {</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #6A9955">/* Old IE hacks */</span></span>
<span class="line"><span style="color: #D4D4D4">    #</span><span style="color: #9CDCFE">position</span><span style="color: #D4D4D4">: </span><span style="color: #CE9178">absolute</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    #</span><span style="color: #9CDCFE">top</span><span style="color: #D4D4D4">: </span><span style="color: #B5CEA8">50%</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">width</span><span style="color: #D4D4D4">: </span><span style="color: #B5CEA8">100%</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">display</span><span style="color: #D4D4D4">: </span><span style="color: #CE9178">table-cell</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">vertical-align</span><span style="color: #D4D4D4">: </span><span style="color: #CE9178">middle</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D7BA7D">div.RotatorImgCenterWrap4</span><span style="color: #D4D4D4"> {</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #6A9955">/* Old IE hacks */</span></span>
<span class="line"><span style="color: #D4D4D4">    #</span><span style="color: #9CDCFE">position</span><span style="color: #D4D4D4">: </span><span style="color: #CE9178">relative</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    #</span><span style="color: #9CDCFE">top</span><span style="color: #D4D4D4">: </span><span style="color: #B5CEA8">-50%</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">width</span><span style="color: #D4D4D4">: </span><span style="color: #B5CEA8">100%</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">text-align</span><span style="color: #D4D4D4">: </span><span style="color: #CE9178">center</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D7BA7D">.RotatorImgCenterWrap4</span><span style="color: #D4D4D4"> </span><span style="color: #D7BA7D">img</span><span style="color: #D4D4D4"> {</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #9CDCFE">vertical-align</span><span style="color: #D4D4D4">: </span><span style="color: #CE9178">middle</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">}</span></span></code></pre></div>



<p class="wp-block-paragraph">I&#8217;ll give a brief explanation as to how this works. First, the outer most div, RotatorImgCenterWrap1, is a &#8216;throw away&#8217; div. This is necessary because the content rotator we used overwrites the style of this outermost div; this is just how the module works. It forces the following styles, which, as you can see, causes us some issues with what we are trying to do:</p>



<p class="wp-block-paragraph">position: absolute; top: 0pt; left: 0pt; display: block;</p>



<p class="wp-block-paragraph">Next we have TotatorImgCenterWrap2, which we set to table display (we are going back to the old school methods for this). Note that the # is in front of styles that we only want applied to IE. (IE and Firefox cross compatibility always seems to come into play when you are doing something tricky in CSS). The purpose of this div is largely to create a non-relative div that we can center objects in.</p>



<p class="wp-block-paragraph">RotatorImgCenterWrap3 is positioned to be a table-cell beginning at 50% of the way down from the top of RotatorImgCenterWrap2. This is done with the position: absolute and top: 50% styles in IE. The vertical-align: middle in other browsers positions this in a slightly different place: the exact middle, which is where we want it..</p>



<p class="wp-block-paragraph">Finally, we have RotatorImgCenterWrap4. This is really only necessary to finish off the IE fix; we have the divs centered on other browsers at this point. This is done by moving the top position 50% above (top: -50%) and outside of the previous div.</p>



<p class="wp-block-paragraph">The only style needed for centering horizontally is text-align: center;.</p>



<p class="wp-block-paragraph">We just threw this together so I am curious if others have improvements (do I have unnecessary steps that could be removed?) or are aware of simpler ways to do this.</p>
<p>The post <a href="https://static.dmcinfo.com/blog/30222/css-and-how-to-center-images-of-unknown-size/">CSS and How to Center Images of Unknown Size</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Capture the Browser Back Button &#8211; JavaScript Snippets</title>
		<link>https://static.dmcinfo.com/blog/30232/capture-the-browser-back-button-javascript-snippets/</link>
		
		<dc:creator><![CDATA[DMC]]></dc:creator>
		<pubDate>Tue, 11 Aug 2009 17:20:49 +0000</pubDate>
				<category><![CDATA[Web Application Development]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Dot Net Nuke]]></category>
		<category><![CDATA[HTML and CSS]]></category>
		<category><![CDATA[MS Visual Studio/.NET]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[Web]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/30232/capture-the-browser-back-button-javascript-snippets/</guid>

					<description><![CDATA[<p>It’s a common problem: “I have an ASP .Net data entry form and all of my users are mad at me because they closed their browser and they lost their unsaved data!” If I had a dollar for every time I had to re-enter my shipping address because I used my back button when the [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/30232/capture-the-browser-back-button-javascript-snippets/">Capture the Browser Back Button &#8211; JavaScript Snippets</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">It’s a common problem: “I have an ASP .Net data entry form and all of my users are mad at me because they closed their browser and they lost their unsaved data!”</p>



<p class="wp-block-paragraph">If I had a dollar for every time I had to re-enter my shipping address because I used my back button when the site creator didn’t want me to… well I’d have enough dollars to make the mistake a few more times, probably buying robot parts on <a href="http://www.sparkfun.com/" target="_blank">SparkFun</a> .</p>



<p class="wp-block-paragraph">Amazingly though, adding <a href="http://en.wikipedia.org/wiki/Javascript" target="_blank">JavaScript</a> code to your ASPX page to prevent this is almost trivial once you know what you’re doing (the previous link is for reference only… if you haven’t heard of JavaScript, you’ve been in a coma since the late 90’s). JavaScript lets you fire the special “onbeforeunload” event before the data is lost on the page, something that you can’t really do using code behind.</p>



<p class="wp-block-paragraph">This event lets you warn the user before they navigate away from the page via clicking the explorer back button, following a link on the page, or even by closing the browser window! For more details of the &#8216;onbeforeunload&#8217; event, see my <a href="https://static.dmcinfo.com/blog/30236/using-the-javascript-window-onbeforeunload-event/" type="link" id="https://static.dmcinfo.com/blog/30236/using-the-javascript-window-onbeforeunload-event/" target="_blank" rel="noreferrer noopener">previous blog</a>.</p>



<p class="wp-block-paragraph">Assign the appropriate JavaScripts to your page controls (guidelines are shown in the tables below):</p>


<table align="center" border="1" cellpadding="3" cellspacing="0" style="margin: 16px 0; width: 100%;">
<caption><b>Which JavaScript Functions to Use</b></caption>
<tbody>
<tr>
<td>Data Entry Controls</td>
<td>javascript:DataEdit()</td>
</tr>
<tr>
<td>Data Entry Controls that Post back</td>
<td>javascript:DataEditWithPostback()</td>
</tr>
<tr>
<td>Non Data Entry Controls that Post back (i.e. action buttons on the form)</td>
<td>javascript:Postback()</td>
</tr>
<tr>
<td>Controls that save the data</td>
<td>javascript:DataSave()</td>
</tr>
</tbody>
</table>
<table align="center" border="1" cellpadding="3" cellspacing="0" style="margin: 16px 0; width: 100%;">
<caption><b>Properties to Assign Scripts To</b></caption>
<tbody>
<tr>
<td>Textbox</td>
<td>onkeyup and/or onchange</td>
</tr>
<tr>
<td>DropDownList</td>
<td>onchange</td>
</tr>
<tr>
<td>Checkbox</td>
<td>onclick</td>
</tr>
<tr>
<td>Button</td>
<td>onclientclick</td>
</tr>
</tbody>
</table>
<table align="center" border="1" cellpadding="3" cellspacing="0" style="margin: 16px 0; width: 100%;">
<tbody>
<tr>
<td><b>Description</b></td>
<td><b>Example </b></td>
<td><b>Code Snippet </b></td>
</tr>
<tr>
<td>Textbox that does not post back</td>
<td>A username field</td>
<td>&lt;asp&gt;:TextBoxID=&quot;txtUsername&quot; runat=&quot;server&quot; onkeyup=&quot;javascript:DataEdit()&quot; onchange=&quot;javascript:DataEdit()&quot;/&gt;</td>
</tr>
<tr>
<td>Textbox that does post back</td>
<td>An amount field that is used in a running total</td>
<td>&lt;asp&gt;:TextBoxID=&quot;txtAmount&quot; runat=&quot;server&quot; AutoPostBack=&quot;True&quot; onkeyup=&quot;javascript:DataEdit()&quot; onchange=&quot;javascript:DataEditWithPostBack()&quot;/&gt;</td>
</tr>
<tr>
<td>DropDownList that does not post back</td>
<td>A selection from a list, such as a group</td>
<td>&lt;asp&gt;:DropDownListID=&quot;ddlGroup&quot; runat=&quot;server&quot; onchange=&quot;javascript:DataEdit()&quot;/&gt;</td>
</tr>
<tr>
<td>DropDownList that does post back</td>
<td>A selection such as a type that changes the context of the form</td>
<td>&lt;asp&gt;:DropDownListID=&quot;ddlType&quot; runat=&quot;server&quot; AutoPostBack=&quot;True&quot; onchange=&quot;javascript:DataEditWithPostBack()&quot;/&gt;</td>
</tr>
<tr>
<td>A checkbox</td>
<td>A &ldquo;Yes / No&rdquo; field</td>
<td>&lt;asp&gt;:CheckBoxID=&quot;cxbNotify&quot; runat=&quot;server&quot; onclick=&quot;javascript:DataEdit()&quot;/&gt;</td>
</tr>
<tr>
<td>A button that posts back</td>
<td>A &ldquo;Next Page&rdquo; button</td>
<td>&lt;asp&gt;:ButtonID=&quot;btnNextPage&quot; runat=&quot;server&quot; Text=&quot;Next&quot; onclientclick=&quot;javascript: PostBack()&quot;/&gt;</td>
</tr>
<tr>
<td>A button that posts back and changes data</td>
<td>An &ldquo;Add New Row&rdquo; button</td>
<td>&lt;asp&gt;:ButtonID=&quot;btnAddRow&quot; runat=&quot;server&quot; Text=&quot;Add Row&quot; onclientclick=&quot;javascript: DataEditPostBack()&quot;/&gt;</td>
</tr>
<tr>
<td>Button that runs code to save data</td>
<td>Button that runs the page save function</td>
<td>&lt;asp&gt;:ButtonID=&quot;btnSave&quot; runat=&quot;server&quot; Text=&quot;Save&quot; onclientclick=&quot;javascript:DataSave()&quot; OnClick=&quot;fnSave&quot;/&gt;</td>
</tr>
</tbody>
</table>


<p class="wp-block-paragraph">Finally, copy this code onto the bottom of you ASCX page:</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">JavaScript</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>&lt;div style="display: none;">
    &lt;asp:CheckBox ID="chkShowWarning" runat="server" />
&lt;/div>

&lt;script type="text/javascript">

    var bShowWarning = false;
    var bPostBack = false;

    function DataEdit() {
        bShowWarning = true;

        document.getElementById(
            '&lt;%= chkShowWarning.ClientID %>'
        ).checked = bShowWarning;
    }

    function PostBack() {
        bPostBack = true;
    }

    function DataEditWithPostBack() {
        bShowWarning = true;
        bPostBack = true;

        document.getElementById(
            '&lt;%= chkShowWarning.ClientID %>'
        ).checked = bShowWarning;
    }

    function DataSave() {
        bShowWarning = false;
        bPostBack = true;

        document.getElementById(
            '&lt;%= chkShowWarning.ClientID %>'
        ).checked = bShowWarning;
    }

    function LoadWindow() {
        bShowWarning = document.getElementById(
            '&lt;%= chkShowWarning.ClientID %>'
        ).checked;

        bPostBack = false;
    }

    function UnLoadWindow() {

        if (!bShowWarning || bPostBack) {
            return;
        }

        return "If you leave the page your data will be lost.";
    }

    window.onbeforeunload = UnLoadWindow;
    window.onload = LoadWindow;

&lt;/script></textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #808080">&lt;</span><span style="color: #569CD6">div</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">style</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;display: none;&quot;</span><span style="color: #808080">&gt;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #808080">&lt;</span><span style="color: #569CD6">asp</span><span style="color: #D4D4D4">:</span><span style="color: #4EC9B0">CheckBox</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">ID</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;chkShowWarning&quot;</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">runat</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;server&quot;</span><span style="color: #D4D4D4"> </span><span style="color: #808080">/&gt;</span></span>
<span class="line"><span style="color: #808080">&lt;/</span><span style="color: #569CD6">div</span><span style="color: #808080">&gt;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #808080">&lt;</span><span style="color: #569CD6">script</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">type</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;text/javascript&quot;</span><span style="color: #808080">&gt;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    var bShowWarning = false;</span></span>
<span class="line"><span style="color: #D4D4D4">    var bPostBack = false;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    function DataEdit() </span><span style="color: #569CD6">{</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">bShowWarning</span><span style="color: #D4D4D4"> = </span><span style="color: #569CD6">true</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">document</span><span style="color: #D4D4D4">.</span><span style="color: #DCDCAA">getElementById</span><span style="color: #D4D4D4">(</span></span>
<span class="line"><span style="color: #D4D4D4">            </span><span style="color: #CE9178">&apos;&lt;%= chkShowWarning.ClientID %&gt;&apos;</span></span>
<span class="line"><span style="color: #D4D4D4">        ).</span><span style="color: #9CDCFE">checked</span><span style="color: #D4D4D4"> = </span><span style="color: #9CDCFE">bShowWarning</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #569CD6">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    function PostBack() </span><span style="color: #569CD6">{</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">bPostBack</span><span style="color: #D4D4D4"> = </span><span style="color: #569CD6">true</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #569CD6">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    function DataEditWithPostBack() </span><span style="color: #569CD6">{</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">bShowWarning</span><span style="color: #D4D4D4"> = </span><span style="color: #569CD6">true</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">bPostBack</span><span style="color: #D4D4D4"> = </span><span style="color: #569CD6">true</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">document</span><span style="color: #D4D4D4">.</span><span style="color: #DCDCAA">getElementById</span><span style="color: #D4D4D4">(</span></span>
<span class="line"><span style="color: #D4D4D4">            </span><span style="color: #CE9178">&apos;&lt;%= chkShowWarning.ClientID %&gt;&apos;</span></span>
<span class="line"><span style="color: #D4D4D4">        ).</span><span style="color: #9CDCFE">checked</span><span style="color: #D4D4D4"> = </span><span style="color: #9CDCFE">bShowWarning</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #569CD6">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    function DataSave() </span><span style="color: #569CD6">{</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">bShowWarning</span><span style="color: #D4D4D4"> = </span><span style="color: #569CD6">false</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">bPostBack</span><span style="color: #D4D4D4"> = </span><span style="color: #569CD6">true</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">document</span><span style="color: #D4D4D4">.</span><span style="color: #DCDCAA">getElementById</span><span style="color: #D4D4D4">(</span></span>
<span class="line"><span style="color: #D4D4D4">            </span><span style="color: #CE9178">&apos;&lt;%= chkShowWarning.ClientID %&gt;&apos;</span></span>
<span class="line"><span style="color: #D4D4D4">        ).</span><span style="color: #9CDCFE">checked</span><span style="color: #D4D4D4"> = </span><span style="color: #9CDCFE">bShowWarning</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #569CD6">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    function LoadWindow() </span><span style="color: #569CD6">{</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">bShowWarning</span><span style="color: #D4D4D4"> = </span><span style="color: #9CDCFE">document</span><span style="color: #D4D4D4">.</span><span style="color: #DCDCAA">getElementById</span><span style="color: #D4D4D4">(</span></span>
<span class="line"><span style="color: #D4D4D4">            </span><span style="color: #CE9178">&apos;&lt;%= chkShowWarning.ClientID %&gt;&apos;</span></span>
<span class="line"><span style="color: #D4D4D4">        ).</span><span style="color: #9CDCFE">checked</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">bPostBack</span><span style="color: #D4D4D4"> = </span><span style="color: #569CD6">false</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #569CD6">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    function UnLoadWindow() </span><span style="color: #569CD6">{</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #DCDCAA">if</span><span style="color: #D4D4D4"> (!</span><span style="color: #9CDCFE">bShowWarning</span><span style="color: #D4D4D4"> || </span><span style="color: #9CDCFE">bPostBack</span><span style="color: #D4D4D4">) {</span></span>
<span class="line"><span style="color: #D4D4D4">            return;</span></span>
<span class="line"><span style="color: #D4D4D4">        }</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #9CDCFE">return</span><span style="color: #D4D4D4"> </span><span style="color: #CE9178">&quot;If you leave the page your data will be lost.&quot;</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #569CD6">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    window.onbeforeunload = UnLoadWindow;</span></span>
<span class="line"><span style="color: #D4D4D4">    window.onload = LoadWindow;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #808080">&lt;/</span><span style="color: #569CD6">script</span><span style="color: #808080">&gt;</span></span></code></pre></div>



<p class="wp-block-paragraph">If you’ve done everything right, your application should now show a pop-up warning if and only if you try to navigate away from the page after editing a control and before saving.</p>



<figure class="wp-block-image"><img fetchpriority="high" decoding="async" alt="" height="163" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/OnBeforeUnloadPopUp.jpg" width="372" /></figure>



<p class="wp-block-paragraph"><a href="/services/application-development/web-application-development">Learn more about DMC&#8217;s software and web development services.</a></p>
<p>The post <a href="https://static.dmcinfo.com/blog/30232/capture-the-browser-back-button-javascript-snippets/">Capture the Browser Back Button &#8211; JavaScript Snippets</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Using the JavaScript &#8216;window.onbeforeunload&#8217; Event</title>
		<link>https://static.dmcinfo.com/blog/30236/using-the-javascript-window-onbeforeunload-event/</link>
		
		<dc:creator><![CDATA[DMC]]></dc:creator>
		<pubDate>Tue, 11 Aug 2009 17:06:47 +0000</pubDate>
				<category><![CDATA[Web Application Development]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Dot Net Nuke]]></category>
		<category><![CDATA[HTML and CSS]]></category>
		<category><![CDATA[MS Visual Studio/.NET]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[Web]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/30236/using-the-javascript-window-onbeforeunload-event/</guid>

					<description><![CDATA[<p>When creating data entry forms in ASP .NET, the JavaScript onbeforeunload event can add a huge improvement to the end user experience. This nifty little event is fired before a page is unloaded (duh) and will keep users from navigating off of a page (and even from closing their browser) when they have unsaved changes [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/30236/using-the-javascript-window-onbeforeunload-event/">Using the JavaScript &#8216;window.onbeforeunload&#8217; Event</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">When creating data entry forms in ASP .NET, the JavaScript onbeforeunload event can add a huge improvement to the end user experience. This nifty little event is fired before a page is unloaded (duh) and will keep users from navigating off of a page (and even from closing their browser) when they have unsaved changes on a data entry form.</p>



<p class="wp-block-paragraph">The onbeforeunload event behaves a bit oddly for an event. Basically in your event handler function, if you return anything, the event will pop up a message box with whatever you returned sandwiched between “Are you sure you want to navigate away from this page?” and “Press OK to continue, or Cancel to stay on the current page.” Here is an example:</p>



<figure class="wp-block-image size-full"><img decoding="async" width="372" height="163" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/OnBeforeUnloadPopUp-1.jpg" alt="OnBeforeUnloadPopUp" class="wp-image-30235" srcset="https://static.dmcinfo.com/wp-content/uploads/2025/05/OnBeforeUnloadPopUp-1.jpg 372w, https://static.dmcinfo.com/wp-content/uploads/2025/05/OnBeforeUnloadPopUp-1-300x131.jpg 300w" sizes="(max-width: 372px) 100vw, 372px" /></figure>



<p class="wp-block-paragraph">If, however, your function doesn’t return anything, no warning will show up (but the page is removed from cached memory so you can’t navigate back to it.) This provides a very nice tool for alerting users. All your function needs to do is to check if data has been edited and if so, return an appropriate string. The window prompt and warning will then be handled for you by the onbeforeunload event.</p>



<p class="wp-block-paragraph">The function is extremely easy to use. In the “&lt;script type=&#8221;text/javascript&#8221;>“ section at the end of an ASPX page you just need to assign a function to the “window.onbeforeunload” event. Below is a complete snippet (the JavaScript variable bEdited is set outside of this snippet to true if data on the form has been edited.)</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">JavaScript</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>var bEdited = false;

function UnLoadWindow()
{
    if (!bEdited)
    {
        return;
    }

    return "DMC strongly recommends NOT closing this window yet.";
}

window.onbeforeunload = UnLoadWindow;</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #569CD6">var</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">bEdited</span><span style="color: #D4D4D4"> = </span><span style="color: #569CD6">false</span><span style="color: #D4D4D4">;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #569CD6">function</span><span style="color: #D4D4D4"> </span><span style="color: #DCDCAA">UnLoadWindow</span><span style="color: #D4D4D4">()</span></span>
<span class="line"><span style="color: #D4D4D4">{</span></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #C586C0">if</span><span style="color: #D4D4D4"> (!</span><span style="color: #9CDCFE">bEdited</span><span style="color: #D4D4D4">)</span></span>
<span class="line"><span style="color: #D4D4D4">    {</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #C586C0">return</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">    }</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    </span><span style="color: #C586C0">return</span><span style="color: #D4D4D4"> </span><span style="color: #CE9178">&quot;DMC strongly recommends NOT closing this window yet.&quot;</span><span style="color: #D4D4D4">;</span></span>
<span class="line"><span style="color: #D4D4D4">}</span></span>
<span class="line"></span>
<span class="line"><span style="color: #9CDCFE">window</span><span style="color: #D4D4D4">.</span><span style="color: #9CDCFE">onbeforeunload</span><span style="color: #D4D4D4"> = </span><span style="color: #9CDCFE">UnLoadWindow</span><span style="color: #D4D4D4">;</span></span></code></pre></div>



<p class="wp-block-paragraph"><a href="/services/application-development/web-application-development">Learn more about DMC&#8217;s software and web development services.</a></p>
<p>The post <a href="https://static.dmcinfo.com/blog/30236/using-the-javascript-window-onbeforeunload-event/">Using the JavaScript &#8216;window.onbeforeunload&#8217; Event</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Forcing IE8 Compatibility Mode in Dot Net Nuke</title>
		<link>https://static.dmcinfo.com/blog/30323/forcing-ie8-compatibility-mode-in-dot-net-nuke/</link>
		
		<dc:creator><![CDATA[DMC]]></dc:creator>
		<pubDate>Sat, 20 Jun 2009 14:23:40 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Dot Net Nuke]]></category>
		<category><![CDATA[HTML and CSS]]></category>
		<category><![CDATA[Web]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/30323/forcing-ie8-compatibility-mode-in-dot-net-nuke/</guid>

					<description><![CDATA[<p>Microsoft has just released Internet Explorer 8. Unfortunately, some of the pages on our website have some issues when viewed with IE8&#8217;s default settings. In particular, the styling that we&#8217;ve done on our main page&#8217;s tab control is causing issues. Users can fix these issues on the client side by selecting compatibility mode (the button [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/30323/forcing-ie8-compatibility-mode-in-dot-net-nuke/">Forcing IE8 Compatibility Mode in Dot Net Nuke</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">Microsoft has just released <a href="http://www.microsoft.com/windows/internet-explorer/default.aspx">Internet Explorer 8</a>. Unfortunately, some of the pages on our website have some issues when viewed with IE8&#8217;s default settings. In particular, the styling that we&#8217;ve done on our main page&#8217;s tab control is causing issues. Users can fix these issues on the client side by selecting compatibility mode (the button to the right of the URL field shown below).</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Compatibility-Mode.jpg" alt="IE8 Compatibility Mode"/></figure>



<p class="wp-block-paragraph">Of course, a client side fix is never a user-friendly fix. Thankfully there is a meta tag that can be added to your site to force IE8 to automatically go into compatibility mode.</p>



<p class="wp-block-paragraph">Our page is built in <a href="https://www.dnnsoftware.com/">Dot Net Nuke</a>. The appropriate way to apply this fix for DNN is to add the tag to the default.aspx file that is found in the root directory of your Dot Net Nuke website. Any meta tag that is placed in here should be applied to all pages to your website. Add the tag below at the top of the head section of the default.aspx file.</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">Text</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>&lt;meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /></textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #808080">&lt;</span><span style="color: #569CD6">meta</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">http-equiv</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;X-UA-Compatible&quot;</span><span style="color: #D4D4D4"> </span><span style="color: #9CDCFE">content</span><span style="color: #D4D4D4">=</span><span style="color: #CE9178">&quot;IE=EmulateIE7&quot;</span><span style="color: #D4D4D4"> </span><span style="color: #808080">/&gt;</span></span></code></pre></div>



<p class="wp-block-paragraph">Note that the tag must be placed at the top of the head section. Also, be aware that updates of your DNN framework will overwrite this change.</p>



<p class="wp-block-paragraph">This is more of a short-term fix. In the long run, we will want to determine exactly what is causing these issues and get the pages to display appropriately in the new IE8 engine.</p>



<p class="wp-block-paragraph">Thanks to Ty Seddon of CogniVista and <a href="http://www.dotnetnuke.com/Community/Forums/tabid/795/ctl/UserProfile/mid/2108/userid/49419/Default.aspx">Sebastian Leupold</a> who contributed to this fix and Tim Warr, for posting about the meta tag for IE8.</p>



<p class="wp-block-paragraph"><a href="/services/application-development/web-application-development">Learn more about DMC&#8217;s software and web development services.</a></p>
<p>The post <a href="https://static.dmcinfo.com/blog/30323/forcing-ie8-compatibility-mode-in-dot-net-nuke/">Forcing IE8 Compatibility Mode in Dot Net Nuke</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>DMC Launches New Website</title>
		<link>https://static.dmcinfo.com/blog/30400/dmc-launches-new-website/</link>
		
		<dc:creator><![CDATA[DMC]]></dc:creator>
		<pubDate>Fri, 01 May 2009 16:32:23 +0000</pubDate>
				<category><![CDATA[Announcements]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Dot Net Nuke]]></category>
		<category><![CDATA[HTML and CSS]]></category>
		<category><![CDATA[MS Visual Studio/.NET]]></category>
		<category><![CDATA[Web]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/30400/dmc-launches-new-website/</guid>

					<description><![CDATA[<p>We&apos;ve launched our new and improved website. We implemented our website in-house, so we have full control, allowing us to edit and add new content going forward. We decided to go with a CMS to make this easier. ASP.NET based Dot Net Nuke (DNN) was an obvious choice for us. Implementing the new website required [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/30400/dmc-launches-new-website/">DMC Launches New Website</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p class="wp-block-paragraph">We&apos;ve launched our new and improved website. We implemented our website in-house, so we have full control, allowing us to edit and add new content going forward. We decided to go with a CMS to make this easier. ASP.NET based Dot Net Nuke (DNN) was an obvious choice for us.</p>

<p class="wp-block-paragraph">Implementing the new website required efforts in many disciplines: graphic design and image editing, ASP.NET, CSS, html, marketing and writing. Needless to say, we&apos;ve picked up a few new tricks along the way. Over the next few weeks I plan to blog about a few of these interesting tips and tricks.</p>

<p class="wp-block-paragraph">We still have plans for several changes and improvements to our new site.</p>

<p class="wp-block-paragraph">Thanks to all of the DMC team that assisted in this effort. I also would like to thank Ty Seddon of <a href="http://cognivista.com/" target="_blank">CogniVista</a>. He is a consultant that assisted us on a few bits of the technical implementation of the new website.</p>
<p>The post <a href="https://static.dmcinfo.com/blog/30400/dmc-launches-new-website/">DMC Launches New Website</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
