How to Remove Blogger URL Parameter (m=1)

Removing blogger m=1

Blogger URL parameter (m=1) is the URL parameter that Blogger uses automatically to activate blogger conditional tags on mobile mode.
$ads={1}
This trick is commonly referred to as "Clean URL" (neutralizes sitelinks that bloggers change automatically, and returns them to normal).

{tocify} $title={Table of Contents}

This tutorial will be needed when we want the appearance of the Blog URL (Blogger / blogspot) to be like most websites in general. No frills or parameter attributes after the domain name when it is accessed by a visitor .. both on desktop and mobile mode!

Ok, just get on with it ..

The following is How to Remove Blogger URL Parameters (m=1), when accessed via mobile I mean:

Steps to remove the Blogspot URL parameter (m=1) when accessed by mobile

  1. Login to Blogger.com
  2. Go to Themes > (⋮)> Edit HTML
  3. Then, look for the <head> tag and save the following JavaScript code right after / below it:
<script>var uri=window.location.toString();if(uri.indexOf("?m=1","?m=1")>0){var clean_uri=uri.substring(0,uri.indexOf("?m=1"));window.history.replaceState({},document.title,clean_uri)}</script>

4. Save changes

Now try to access our blog URL via a smartphone / mobile browser .. 
$ads={2}
Good luck

0 Comments

Post a Comment

Post a Comment (0)