I have a widget that will be very useful for many website so how about I create a javascript file that checks for a link and replaces it with an iframe so the link is in the source code but not visible. The widget code would look something like this <a href="http://website.com/" id="required_link">Black Hat SEO?</a> <script type="text/javascript" src="http://website.com/widget.js"></script> Code (markup): SEO Friendly?
I'm not so familiar with such code like that. Im curious on this part: id="required_link" <--- why you need to insert this?
Link baiting is considered to be the most vital part of search engine optimization and if done properly can bring effective changes and build profitable online ties.If it is done in fair terms it is not a black hat technique.
Link bait has come to be the preferred way to natural link building. But it has been always considered as a black hat SEO. It is the reason ,most of the SEO people are avoiding this technique.
I wouldnt really call this link bait. You're not baiting anyone to link to you, you are offering them a service / tool and as part of that offering you are requiring a link back. A lot of free / open source scripts do this by default, such as PHP Link Directory, osCommerce, etc. With regards to whether it is black hat or not, I would say it's borderline so perhaps grey hat. The reason is, that I read an article in which Matt Cutts said that offering people something and forcing a link back is something that Google frowns upon. I can't find the damn source where I read that though. It was back when Google were hitting directories with penalties and offering the reciprocal link method was something they didn't like, or words to that effect.
The script would look for the url and id and replace the link, so if url or id is modified the iframe won't be displayed. I've seen other sites do this but I know Google doesn't like "hidden links". Guess I'll try it see what happens.
If the link is going to be hidden to users, but not to search engine crawlers, then it's black hat. Though some webmasters do use javascripts for blog comment links (on their blog), and those links aren't capable of passing link juice. They'll be crawled by search bots, but will not really pass any value to the destination page.
Link baiting (or linkbaiting) is the latest buzz word in the SEO world and has come to be the preferred way to natural link building. It means to create something that naturally attract backlinks for your web page by getting people to talk about it, discussing it on forums, blogging about i, posting it on del.icio.us/Furl/Digg/Shoutwire and linking to it from their sites. It also attracts a lot of visitors.