<select>
<option value="dsp">ДСП</option>
<option value="lmdf">ЛМДФ</option>
</select>
var type_price = {
dsp: 10,
lmdf: 20
};
var val = select.value; // например "dsp"
var current_price = type_price[val];
var trigger = function (el, type) {
var event;
if (document.createEvent) {
event=document.createEvent('HTMLEvents');
event.initEvent(type,true,true);
} else {
event=document.createEventObject();
event.eventType=type;
}
event.eventName=type;
if (document.createEvent) {
el.dispatchEvent(event);
} else {
el.fireEvent('on'+event.eventType,event);
}
};
var a = "Привет, чувак! 111111";
var b = a.replace(/[^А-Яа-я]/gi, '');
console.log(b); // -> Приветчувак