I want to require my free users to add a linkback to my website. But, I want to check it programmatically that indeed they added the linkback html element I provided and was not hidden by some sort of CSS and Javascript.
Any good suggestions?
I want to require my free users to add a linkback to my website. But, I want to check it programmatically that indeed they added the linkback html element I provided and was not hidden by some sort of CSS and Javascript.
Any good suggestions?
Not an expert on this matter but I'd say the easiest and most reliable method involves actually rendering their page in a browser to ensure that all CSS and JavaScript is applied in the same way a user would see.
Obviously you don't want to do this yourself, but I assume your site has a page where users tell you that they've added the link to it, or where they request free usage based on that link. At this point you could load their page into a hidden IFrame then use JavaScript (JQuery would undoubtedly be easiest) to find your link and query its visibility.
This may be complicated by cross-domain security issues (accessing the IFrame's content) but a proxy on your server could easily work around this.
Without using a browser and JavaScript I can imagine it would be a huge job to parse their HTML, CSS and JavaScript server-side and look for any hint that your link isn't visible - as there are plenty of ways it could be hidden (even by accident).