This is working in case anyone else wants to do the same thing. If anyone knows an easier way to get to the same result please chime in.
This takes the text from 2 dropdown lists, contacts and products(custom module), and puts them together as the quote name(from custom quote module).
It takes the last name of the contact and the entire product name.
Contact:Quimby Fred
Product: Pacific Cruise
Quote Name: Quimby - Pacific Cruise
function update_name() {'.
'var c = document.getElementById(\'contact\'); '.
'var cText = c.options[c.selectedIndex].innerHTML;'.
'var cText = cText.split(" ",1);'.
'var p = document.getElementById(\'product\'); '.
'var pText = p.options[p.selectedIndex].innerHTML;'.
'var p = document.getElementById(\'product\'); '.
'document.forms[\''.$form->getAttribute('name').'\'].quote_name.value = cText+" - "+pText;'.
'}'
Jon