A little something about everything

internet marketing and website development made simple..

How to make a USB bootable from an ISO image.

Microsoft provides a tool to do this,

 Windows7-USB-DVD-tool.exe (946.78 kb)

Simply run this program and follow the four step instructions to create your bootable USB drive.

 

or you can do the following;

open command prompt and type diskpart, list disk, select disk #, clean, create partition primary, active, format fs=fat32 quick and your done.

Now you only need to copy the contents of your bootable dvd over or use winrar to extract the files from the iso image to your usb drive.

How to get your business listed on the front page of Google for free

New Telemarketing scam for Google Bing Yahoo prompted me to write this quick blurb.

Prerecorded voice stating something like this:

We have an opening for first page placement in Google, this is a rare opportunity available today only so if you would like to take advantage if this press 1 now

 

You can easily get listed on Google by using adwords for a fee or by using the Google local listing service to add your business, which is free.

How to globally redirect all requests from http to https using asp.net

The most effective method will be to use the global.asax file, here is a basic example:

<script language="C#" runat="server">
protected void Application_BeginRequest(Object sender, EventArgs e)	{
if (HttpContext.Current.Request.Url.ToString().ToLower().Contains("http://"))
{
    HttpContext.Current.Response.Status = "301 Moved Permanently"; 
    HttpContext.Current.Response.AddHeader("Location", Request.Url.ToString().ToLower().Replace("http://","https://")); 
}
}
</script>

In some cases you may already have an application using the global.asax file, you can in many cases add the _BeginRequest function or adapt it if it already exists. For example add this after the <script runat="server"> tag but before any other code.

protected void Application_BeginRequest(object sender, EventArgs e)	{
	if (HttpContext.Current.Request.Url.ToString().ToLower().Contains("http://"))	{
	HttpContext.Current.Response.Status = "301 Moved Permanently"; 
	HttpContext.Current.Response.AddHeader("Location", Request.Url.ToString().ToLower().Replace("http://","https://")); 
	}

In some cases this will throw and error, before sure to check the rest of the global.asax file for any other begin requests that may be conflicting. In some cases you may need to adapt the code to work in parallel with exiting code.