Dear Concern,

I am a fan of Prototype. Recently when I was going to use Ajax.Updater
to update the value of a input (text) value it did not work. Please
consider my following code and please provide me a good solution.

<input name="txtItem" type="text" id="txtItem" />
<input name="txtCostingUnit" type="text" id="txtCostingUnit" value="<?
php if ($rn>0){echo $row[4];}?>" />
<input name="sumbit" type="submit" value="ok" onClick="getItemInfo()">

<script>
        function getItemInfo(){

           var vItem = document.getElementById("txtItem").value;
            var oOptions = {
                method: "get",
                parameters: "pcode=" + vItem
            };

                var ajax = new
Ajax.Updater('txtCostingUnit','getcosting.php',oOptions);

        }
</script>

If I mention any DIV ID instead of Text type Input then the script
work fine. But my goal is to update text field value.

Regards,

ALO

-- 
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptacul...@googlegroups.com.
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en.

Reply via email to