document.getElementById(txtid) has no properties error



I need to retrieve some notes from a database, allow users to modify
them and then return them to the database.I have done this
satisfactorily using php.However I would like to do it using AJAX.

To this end I have a <div> the innerhtml for which is sent from a php
file. The innerhtml constructs and fills a series of textareas and
provides each with an id.

When I want to return the modified note to the database and try to
copy the text displayed in a text area with the line

var txt=document.getElementById(txtid).value;
or
var txt=document.getElementById(txtid).text;

I get the error
document.getElementById(txtid) has no properties

When I try
var txt=document.getElementById(txtid);
txt gets the null value.

I would be grateful if someone could explain the basis of my error and
how I can get the text string back out of these text areas.

TIA

N
.



Relevant Pages

  • Re: problems with mysql_fetch_array($IsResult,MYSQL_NUM)
    ... I am trying to write a simple database class to encapsulate all the ... executes the loop. ... $IsResult is reeves no value. ... var $mResult; ...
    (comp.lang.php)
  • Re: Help with two page form
    ... database entry for this order with the Pickup Location, ... <HEAD> ... function load1() { ... var load1 = window.open('http://www.webdesignsbyjc.com/DBSample/ ...
    (comp.lang.php)
  • Re: Shared v. Exclusive Access
    ... Control Panel, Add/remove programs, find Adobe, click Modify -> create Adobe ... The folder wherein the frontend resides grants Full permissions to the ... When I open the database, however, I don't get the message boxes. ...
    (microsoft.public.access.security)
  • Re: PHP page get executed twice
    ... $RESULTcheck = mssql_query; ... let's write data to database ... var $name; # columnname ... # class sql ...
    (comp.lang.php)
  • Re: What is wrong or missing if I cant modefy an exisiting workgroup?
    ... 1)I wasn't able to remove admins group form User Admin. ... database and managed to modify the existing newsystem.dmw. ... Allthough I found an application that had security ...
    (microsoft.public.access.security)