Facebook Took Action to Block Developer Tools - Know Why

If you recently tried accessing the developer tools in your browser on Facebook you might have noticed a large notification in the console highlighted in red. Well, that's for a reason, if you haven seen that scam/spam yet let's tell you more about it.

Developer Tools are great for debugging websites and running scripts manually on a web page, it could be done on any website including Facebook. By writing a script, the author can make anything do with the site on Facebook they can use it for sending friend requests, making comments etc. anything that is possible. Because all that functions are controlled by JavaScript onsite.



Taking advantage of these awesome feature of a browser, some notorious spammers have wrote a script which auto-tags people and like pages associated with them on their statuses where they post instruction to use their code they wrote by claiming that the user will get a new theme for their Facebook, which would seem to work but what it does in the background will terrify you.

The code would send unwanted likes to the pages the spammers wants, it will auto-tag your friends in 100s of status automated by the script and much more as they might even get access to your account. The spam have got amazingly viral as people do really think it's going to work and try it without giving it a thought.

How does it actually look ?

This is an example of well planned viral spam by some script kiddies originating probably from Indonesia.


The link they tell you to open contains the code which they ask you to run in the browser's console which then do what it is supposed to - screw you.

If you see any such things in the future don't let it make you look like a fool! Just block that person and you are good and safe.

Facebook Took An Action to Control it

By disabling developer tools temporarily. Developer Tools is a great tool for developers so they didn't disabled it permanently on their site, but it let's you choose what you want to do. And will also show you what could be the consequences of running scripts from Unknown sources.

Not all scripts are dangerous, for example see my "How to Select All Friends at Once on FB" script, it just automatically selects your friends for inviting them in events etc. But you can clearly understand from this that code can do things that you don't expect to be automated.

Beware before you run scripts from third-party sources especially from these so-called lucrative offers. And even though the script seems fine to you make sure to see what others say about it, what's their opinion to get an idea about it.

It's all, be safe online :) 

Making Images Fit in Post Body on Blogger

If you are working on a responsive design for your Blogger blog, or you are just tired of resizing your images in post editor to fit in the post container then this tutorial will show you an easy way to make images fit with it's surrounding.

This problem occurs often when you try to post images of the dimension larger than your content area or you are just using a responsive layout and when it down-sizes, the images overflows the content area.



Before you continue with the tutorial, check the demo:
Demo: Without the CSS Demo: With the CSS

In the first demo, the image in the container overflows because the width of the image is larger than that of the image, but in the second demo, if the image width is greater than the container's, it will fit itself to the container.

The Code!

All this can be achieved with a small block of CSS code. Before I start giving you lectures on how this works, here's the code for you to use (can be used in most Blogger Templates, but you might need to change the selectors if you are using a custom designed template):

.post-body img {
max-width:100%;
max-height:auto;
}

Now you just need to apply this code to your blog, check this tutorial to learn how add CSS in Blogger.

How does it work?

If you are not a web designer or coder, then this might all seem like a magical charm to you, but it's just code, code that's made to make your life easier. Well, so if you are ready to get bored then I am starting my chapter on CSS.

What actually does the magic is the max-width CSS property which gives any element a maximum width limit. So if you specify an element the the maximum width of 200px, it wouldn't exceed it. The 100% value tells the browser that the element(s) must not exceed the full content width of the container.

The max-height property helps in keeping the original proportion of the image intact. To know more about what would happen if you specify a value in percentage then try and check the results ;)