Here's a quick example i whipped up (and works) http://paste.pocoo.org/show/106586/
To note about your code, "setAttr" isn't a jQuery call, it's ".attr" On Mar 5, 10:04 am, Sir Rawlins <robert.rawl...@thinkbluemedia.co.uk> wrote: > Hey Ryan! > > Thanks for your advice, I appreciate it. > > I've got this now: > > <input type="checkbox" name="CMStudent_IDs" value="s...@email.com" /></ > td> > <a class="blue_button" id="mail"><span>Email Selected Students</ > span></a> > > $("input[name='CMStudent_IDs']").click(function(){ > var mylink = []; > > > $("input[name='CMStudent_IDs':checked]").each(function(i){ > mylink.push($(this).val()); > }); > > $("a#mail").setAttr("href", "mailto:" + > mylink.join > (",")); > }); > > However it doesn't seem to work for me, I check a couple of the > checkboxes but the link is never given an href so clicking it does > nothing. Can you spot anything out of sorts with the code? > > Many thanks mate, > > Rob > > On Mar 5, 1:34 pm, "ryan.j" <ryan.joyce...@googlemail.com> wrote: > > > and you'd probably want to add :checked onto the end of the selector > > too. ;)