New bloggers have a lot of errors in their site. One of them is error ?m=1. This error appears when searching for a site created in Blogger on mobile. I wrote this post for bloggers who want to create a site in Blogger.
Due to this error, there are many problems in ranking the post in Google. If we search a website or link, it is followed by /?m=1 word which is an error. This error can be removed from coding within Blogger.
Steps –
1 Login Blogger
2 Click Theme Option
3 Click Edit HTML
4 Click inside Coding
5 Find </body> Tag or CTRL + F and find </body>
6 Copy the Below Code
7 Paste over the </body> tag
Code –
<script type=’text/javascript’>
//<![CDATA[
var uri = window.location.toString();
if (uri.indexOf(“%3D”,”%3D”) > 0) {
var clean_uri = uri.substring(0, uri.indexOf(“%3D”));
window.history.replaceState({}, document.title, clean_uri);
}
var uri = window.location.toString();
if (uri.indexOf(“%3D%3D”,”%3D%3D”) > 0) {
var clean_uri = uri.substring(0, uri.indexOf(“%3D%3D”));
window.history.replaceState({}, document.title, clean_uri);
}
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);
}
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>
</body>
Download This File Click Here…...
Knowledge of HTML coding can work well in Blogger. Editing the theme is important in Blogger. WordPress has a feature of plugins so that any error can be easily removed. Blogger does not have any plugins so coding is a must.
Thanks