Posts marked with "JavaScript" in categories

Automatically Redirect A Blogger Blog To Another URL

You can redirect your blog to another URL. This redirection can be done using JavaScript or by adding a special meta tag. This redirection is useful when you want to redirect your old blog users to your new blog. The function we use in JavaScript is window.location and the meta tag has http-equiv attribute. DEMO So Let’s begin. Go to Blogger -> Blog to be redirected -> Template -> Edit HTML. You will get a box with a lot of text.... [READ MORE]

Split Name in PHP and Javascript

If you have a user with a long name and want to short it because it won’t fit into the element that contains the name, you can either do it on the server or the client. In this post I am going to tell you how to accomplish this with PHP and JavaScript. Suppose We have a user named Paul Steve Panakkal (my cousin). To separate the first name, middle name and last name you can do the following in PHP :... [READ MORE]

Cross Origin Communication – window.postMessage

The Window.postMessage helps to make scripts talk over different domain connections. When you call a function on an external iframe from the parent window, Javascript won’t allow it. That’s because of the Cross Domain Policy that makes this not possible. But it’s possible since Javascript introduced postMessage function. Suppose you want to call a function on an cross domain iframe with id monu. Let the function be subins(). Here’s how to do it using postMessage technic.... [READ MORE]

Loading Bar until page loads completely using Javascript

This tutorial was requested by Sumit. In this tutorial I’m going to tell how to put up a loading screen until the page has loaded completely. DEMO Here is the screenshot of loading screen : The loading bar will fade out when loading is completed. This code will work for all sites including Blogger Blogs, WordPress Blogs except Dynamic Views Template of **Blogger **(because it uses ajax loading). You can change the image if you want.... [READ MORE]

Setting Iframe height to its content height using Javascript

While loading an iframe on page the most difficult thing is to set it’s height to the height of the content of the iframe. I looked around the web and got the code. This is pure Javascript, doesn’t contain jQuery or any other libraries. Set these functions : function getDocHeight(doc) {     doc = doc || document;     var body = doc.body, html = doc.documentElement;     var height = Math.... [READ MORE]

Javascript code Compressor Tool

If long long Javascript codes are compressed, it will make the page load faster. In this post I’m going to suggest a perfect tool for compressing Javascript code. The tool is JsCompress. Go to to see the compressor in action. You have three options: Paste Code and Compress Compress code in files Compress Multiple files into one. It’s a great tool and it will help you reduce the file size up to 100 KB.... [READ MORE]

Fix: Dynamic Views failed to load properly

Well, this problem is pretty annoying to everyone who is using Dynamic Views, even to me. It’s a Blogger fault as always and there has not been a solution to the problem since it started on the Dynamic Views launch. Päivi & Santeri of Global Nomads founded a solution to this problem. Oh! I didn’t said the problem was. The problem is that the whole Blog will fail to load completely/properly. Some of the problems happen when the blog won’t properly load are listed below:... [READ MORE]

How to redirect users to a page in PHP

If you want to redirect users to a specific page or url like when user is not logged in or something in PHP then you can accomplish this with header function or by Javascript printed by echo function. The following example will redirect user to Or you can use the normal Javascript : What’s the difference ? header function is called in server itself not when the page reaches the browser.... [READ MORE]

How To Integrate Disqus Into Blogger Dynamic Views

Disqus works in normal Blogger template but won’t work in Dynamic Views because it don’t support HTML/Javascript widget. But you can edit the contents in head tag of Template and I found a way to integrate the Disqus commenting system in to Blogger. I’m gonna show you how to do that. DEMO Works On Sidebar Classic Flipcard Magazine Mosaic Snapshot Timeslide Disadvantages On Classic Templates Disqus will only be available for the first post, because they won’t allow you to put more than 1 Disqus Comment box on a page... [READ MORE]

Check whether a site is XSS vulnerable or not.

XSS is a method to hack sites which most of the newbie programmers don’t know. Here is a quick way to identify if a site is vulnerable to it. Go to a site which offers searching or other GET parameters which are outputted in the site’s page. Instead of the value in one of the GET parameter use the following value : XSS Vulnerability checker by Subin Siby For example a site with the GET parameter query with value subins and the url will be : http://subins.... [READ MORE]



Mastodon  Twitter

GitHub GitLab


Demos  Lab


This blog was once on WordPress. Now a static site. See source code on