Link Building -
An Important Element
When other websites link back to your website, this tells the search engines that those sites consider yours a good source for whatever it is you do. This is an important step toward building credibility.
The internet is full of "get rich quick" schemes when it comes to getting links for your website. You can find advice to do everything from placing your URL in comment sections of a blog or discussion board, to paying people for links. These strategies may seem like a good idea on the surface, but search engines are not fooled, and in the end it can even cost you ranking position, if Google gets wind of nefarious linking practices.
What does it mean to get a "quality link" to your website? Think of the internet as a big transit hub. Search engines are the very center of the hub, and other big sources of information like news agencies, Wikipedia, Amazon, etc., these are all major hubs, as well. The closer you are to a main hub, the more "authority" you are considered to have. When you get a website that links to yours, they pass along to your website something called "link equity," meaning they give a portion of their credibility to you. The more authority the linking website is considered to have, the more credibility they can pass along to you. This is not to say that you shouldn't seek links except from a high authority site. Several links from lower authority sites may add up to as much credibility as one higher authority link. And it's just a fact that everyone has to start somewhere. You may not be able to get a link from CNN right out of the gate, so you take what you can get, at first.
One way to think of linking is to imagine that you're trying to get hired at a company and your buddy goes to the boss and vouches for you. If your buddy is a good worker, ethical, honest and hard working, his recommendation will carry a lot of weight with the hiring manage. However, if your lazy, constantly in trouble, ne'er do well cousin goes to the manager and lets him know you're family and he can personally vouch for what a good worker you'd make, the boss will be far less inclined to call you in for an interview.
This is how linking from questionable websites can work. Many websites, or "directories," only exist to get links for websites that pay them. Search engines recognize these "link farms" for what they are, and not only don't give your website any link equity for being listed with them, but can actually end up penalizing your site in search rankings because they assume that if you hang out with questionable company, you might be a little questionable yourself.
Linking In Comments
Mostly this is just a waste of time and energy. Most webmasters have the "follow" turned off for any links posted in their comment sections. This means that when the search engines see your link in a comment, the website where they are listed tells them to disregard it, or "no-follow" it, and so they don't. Why would webmasters do this? Because placing your links in comment sections is ANNOYING!!! So even if you should come across someone who actually wanted your services, you'd likely alienate them by messing up the conversation flow in the comment section. Just don't be that guy. Cultivate quality links, with reputable websites, or hire someone to do it for you. Link building is important enough to do right the first time.