When clicking on the any link in gmail or Facebook,it redirect to that link by some other ways. What are the security advantage of new redirecting method used by gmail and Facebook?
This has nothing to do with security, really. It's about statistics and advertising.
When you put in a link like this:
You get this:
So, when you click the link,
The script then logs that you clicked the link. This allows Facebook to get information about how you interact with their service, e.g. Alice shared a link, which Bob and Eve clicked. It also allows them to identify topics you're talking about, even when sending links to each other, for improved ad relevance.
As Hans mentioned, the other part of this is to preserve privacy. When clicking a link, the target server is told, by the browser, which page you were linked from. If you clicked the link whilst viewing Facebook, this might leak your identity or the identity of one of your friends to the target site.
There are two reasons for the intermediate page: