I found this (JQuery removeClass wildcard) neat solution to remove class based on prefix... however I want to use it in with a function where I can change the prefix with a variable. How do I write in the variable between the... whatever you call them ^_^
function remClass($prefix) {
$("#hello").removeClass (function (index, css) {
retu (css.match (/(^|s)$prefix-S+/g) || []).join(' ');
});
}
