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

usage of cftextarea and get value

Contributor ,
Sep 13, 2011 Sep 13, 2011

Copy link to clipboard

Copied

I used the cftextarea to get the FCK editor, like :

<cftextarea name="txt_h_1" message="Insérer le texte d'Accueil !" height="400" width="700" disabled="No" required="Yes" toolbaronfocus="No" bindonload="No" html="No" enabled="Yes" visible="Yes" richtext="Yes" toolbar="Basic" skin="silver">#get_param.txt_home_1#</cftextarea>

So the name of the element is : TXT_H_1

Ans when I want to save the content via an update query, it says that :

Element TXT_H_1 is undefined in FORM

All other FORM elements are well returned.

then how to get the value of the cftextarea ?

(I used a CFFORM with <input> inside instead of <cfinput>)

thanks for answer.

Pierre.

TOPICS
Advanced techniques

Views

3.1K

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 ,
Sep 13, 2011 Sep 13, 2011

Copy link to clipboard

Copied

What are you looking at to determine that you got every form element except the textarea?

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
Contributor ,
Sep 14, 2011 Sep 14, 2011

Copy link to clipboard

Copied

After the form submit,

I expect to get all form.xxx elements

i have all except the one from the cftextarea

which should be : #form.txt_h_1#

The cftextarea name is : txt_h_1

This is the way I get all other fields values entered in the form.

Thanks for your participation.

Pierre.

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
Community Expert ,
Sep 19, 2011 Sep 19, 2011

Copy link to clipboard

Copied

Here's the cause of the trouble: disabled="No" enabled="Yes".

The browser probably disables the textarea the moment it encounters the word 'disabled'.  In any case, it is repetition to use the attribute 'disabled' as well as 'enabled'. In fact you could omit both!

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
Contributor ,
Sep 20, 2011 Sep 20, 2011

Copy link to clipboard

Copied

Strange behaviour,

I removed : disabled="No" enabled="Yes"

did not help.

I removed : toolbaronfocus="No"

And it worked. (under CF8)

I put again these 3 parameters to ensure.

And it works again now. (very strange)

I will see at next usage, what is the behaviour.

The same file under CF9 does not work, just display the textearea ?

(no FCK editor toolbar). I am lost.

There is a Javascript error : "Coldfusion undefined"

But my sites are on disk D: and Coldfusion is on disk C:

It seems this is the preoblem, i do not know how to solve this.

Thanks for your participation and comments and help.

Pierre.

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
Community Expert ,
Sep 20, 2011 Sep 20, 2011

Copy link to clipboard

Copied

Here is the test code that worked for me:

<cfif isdefined("form.txt_h_1")>

<cfdump var="#form#">

</cfif>

<cfset get_param.txt_home_1 = "blah blah blah">

<cfform>

<cftextarea name="txt_h_1" message="Insérer le texte d'Accueil !" height="400" width="700"  required="Yes" toolbaronfocus="No" bindonload="No" html="No" visible="Yes" richtext="Yes" toolbar="Basic" skin="silver"><cfoutput>#get_param.txt_home_1#</cfoutput></cftextarea>

<cfinput name="sbmt" type="submit" value="send">

</cfform>

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
Contributor ,
Sep 20, 2011 Sep 20, 2011

Copy link to clipboard

Copied

Thanks, seems to work now.

My problem now is under CF9  :

my sites are on disk D:  and Coldfusion is on disk C:

And the FCK toolbar does not appear.

there is something to do somewhere about FCKeditor location,

I presume in CF admin.

Any Idea ?

Thanks again.

Pierre.

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
Community Expert ,
Sep 20, 2011 Sep 20, 2011

Copy link to clipboard

Copied

plarts wrote:

My problem now is under CF9  :

my sites are on disk D:  and Coldfusion is on disk C:

And the FCK toolbar does not appear.

there is something to do somewhere about FCKeditor location,

I presume in CF admin.

The system files for the FCKEditor are in \CFIDE\scripts\ajax\FCKeditor\. What happens when you copy that directory to your site? If it works, then you should find a way to make the CFIDE directory accessible to your site. It could be that, unbeknownst to you, other functionalities besides FCK are not available to your site.

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
Contributor ,
Sep 20, 2011 Sep 20, 2011

Copy link to clipboard

Copied

I copied the CFIDE on the disk D:/wwwroot

(where are all sites)

but no change.

If I copied the CFIDE (all files) in a website root, it does work.

rep_serveur.jpg

But I cannot make a copy of CFIDE for each site,  (all  CXXXX / www)

then I need a way to tell somewhere how to reach the CFIDE location.

I can eventually make a single copy of it in the D:/wwwroot

Do you think this can be managed in the CF admin ?

I will think more about it.

Thanks for any idea.

Pierre.

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
Community Expert ,
Sep 21, 2011 Sep 21, 2011

Copy link to clipboard

Copied

If I copied the CFIDE (all files) in a website root, it does work

Yes, you should copy CFIDE to the web root.

But I cannot make a copy of CFIDE for each site,  (all  CXXXX / www)

then I need a way to tell somewhere how to reach the CFIDE location.

I can eventually make a single copy of it in the D:/wwwroot

Do you think this can be managed in the CF admin ?

Yes. In fact, doing it in the ColdFusion Administrator is probably the best way. Just create a mapping for CFIDE.

During installation, ColdFusion usually creates a CFIDE mapping by default. If the mapping already exists, edit it to what you want.

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
Contributor ,
Sep 21, 2011 Sep 21, 2011

Copy link to clipboard

Copied

Ok, I have not a good knowledge about "virtual directory".

But I did it under IIS, in a site root, I have created a virtual directory

pointing on the real CFIDE, and it works.

So, this means, I have to do this for each created site root ?

No way to have only one created for all sites ?

Thanks a lot.

Pierre.

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
Contributor ,
Jan 15, 2014 Jan 15, 2014

Copy link to clipboard

Copied

LATEST

A bit more than 2 years after, I come along with the same problem.

CFIDE scripts adress is specified in the CF admin,

BUT relative to the Web site root (impossible outside) !!!!!!

I think this is a big architecture error ? Also mixing scripts with CF admin ?

Any way, the solution I took, is to build a CFIDE minimal directory (only necessary files for scripts),

and put a copy of it at each new site created at site root level.

Coldfusion is installed on disk C: and sites are on disk D:

Any comments are welcome.

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
Explorer ,
Sep 21, 2011 Sep 21, 2011

Copy link to clipboard

Copied

As you say "If I copied the CFIDE (all files) in a website root, it does work."

You have no no need to copy it again and again. You can do it from IIS also. You need to add CFIDE under your virtual directory.

Like if have site named "anysite", you need to right click on and choose add. After clicking add named the virtual directory as "CFIDE" and point it to actual CFIDE directory of coldfusion.

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