Many affiliate programes specifically ban the posting of links other than on the affiliate's own website. And those that don't ban it strongly discourage it. And even if you do post affiliate links on other people's sites, the site operators will probably consider them to be spammy and will remove them.
And, in any case, what's the point? You won't make any real money by such tactics. If you're serious about affiliate marketing, you need to develop a high-quality site of your own, with compelling content that will attract a large number of visitors.