• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Adding DOM element to a CF variable

Guest
Mar 29, 2007 Mar 29, 2007

Copy link to clipboard

Copied

Hi,

I would like to know if it is possible to add a DOM element to a CF variable? Something like this:

<cfset test = opener.document.MyForm.AFormField.value>

Any help would be appreciated.

Shloime
TOPICS
Advanced techniques

Views

249

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Mar 29, 2007 Mar 29, 2007

Copy link to clipboard

Copied

It sounds like you are confusing client-side technology and server-side technology.

Coldfusion only deals with server-side technology - mainly information that has been submitted via a form or url request to the server. CF generates a page and then presents it to the browser. CF doesn't really have that much interaction with the data on the page until another request comes in (i.e. after form submission, a link is clicked, etc)

Client side technology such as JavaScript allows you to interact with the contents of your page before the information has been sent to the server. Your DOM example is obviously a JavaScript address for a field on your form. Once you submit the form, CF will have access to it in the FORM scope structure. Until then, however, the only technology that can read/write to that DOM element is client-side technologies such as JavaScript.

If you can explain a little more about what you are trying to do, we can probably start you down the right path to figuring out what you need to do.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Mar 29, 2007 Mar 29, 2007

Copy link to clipboard

Copied

LATEST
insuractive wrote:
> Coldfusion only deals with client-side technology - mainly information that

i do believe that is a typo and you meant server-side technology :)

--

Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation