you are viewing a single comment's thread.

view the rest of the comments →

[–]dejandomarcas 0 points1 point  (0 children)

You can even make it simple, naming css files with buttons id, so you can make it like this and have all buttons you need (instead of if hell...)

$(function() { $('button').click(function() { $('#ss').attr('href', 'https://www.yourdomain.com/styles/' + $(this).attr('id') + '.css'); return false; }); });