HI i need to split some part of variable value
in my html file i got a dynamic value of variable some thing like this
product/roe_anythin_anything-1.jpg 
product/soe_anything_anything-2.jpg
i need to remove the before
/slashpart
and after
_ part
which should return the roe or soe part
i have use a function
  <script>
function splitSize(){
$('#splitSize').each(function(index) {
    var mystr = $(this).html();
    var mystr1 = /product\/(.*)-.*/.exec(mystr);
    $(this).html(mystr1[1]);
    //$(this).html(mystr1[0]);  
});
}
splitSize();
</script>
with which i got roe_anythin_anything successfully i just need to remove now after `
_ part
`
please suggest how can i do this
 
     
     
    