Can anyone halpe me with this error:

```
Uncaught TypeError: Cannot read
property 'length' of undefined

```

[website](http://www.westportugal.com/product_info.php/c/8_14/i/26/formacao/subcategoria-1/artigo-1)

When you change the values from combo it should change the price below, but it is not working

```
function update_price_select2(o, element_name)
{   

    var sel_obj = null;
    var element = null;
    //price_original = <?php //echo substr($products_price,0,-1); ?>;
    //alert("Preço Original:" + price_original);
    if (document.getElementById)  // DOM3 = IE5, NS6
    {  
        sel_obj = document.getElementById(o);
         //alert("sel_obj "+ sel_obj);
        element = document.getElementById(element_name);
         //alert("element "+ element);
    }
    //alert(o);
    //alert(element_name);
    var index = sel_obj.selectedIndex;
    //alert(o+" index");
    var price_array = option_price[sel_obj.id];
    var price = price_array[index];
    var price_for_operation = price.substr(0,price.length -1); //the price from the option choosen

    if (price_for_operation == '')
    {
        price_for_operation = 0;
    }

    //Ao preço original, vamos retirar o preço da variável que este tinha anteriormente.
    current_product_price = current_product_price - option_price[sel_obj.id + '_current'];
    //Vamos colocar o valor actual da variável seleccionada 
    option_price[sel_obj.id + '_current'] = price_for_operation;

    if (price_for_operation != 0)
    {
        var final_price = roundNumber(parseFloat(current_product_price) + parseFloat(price_for_operation),2); 
        final_price = final_price.toFixed(2);
    }
    else
    {
        var final_price = current_product_price.toFixed(2);
    }
    //Nos save the decimal value, without the € or $, so we can use it in the next options call
    current_product_price = final_price;
    final_price = final_price + money_simbol;  

    if (final_price != "")
    {    
        display_updated_price(final_price, element);
        update_allowbuy(final_price);
    }

}

```