Skip Navigation

[Resolved] Post-form with field from post

This support ticket is created 6 years, 2 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 -
- 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 -

Supporter timezone: Europe/London (GMT+00:00)

Tagged: 

This topic contains 2 replies, has 2 voices.

Last updated by dmitryK-2 6 years, 2 months ago.

Assisted by: Nigel.

Author
Posts
#1102520
tssupport-ticket-screen_4.png
tssupport-ticket-screen_5.png

Tell us what you are trying to do?

Hello, can you please help me with simple copying task:

tssupport-ticket-screen_4 - I have standart WP post (ID=373) with custom field [sht-cf-type] value = ’Text for 9’ in it . I have also toolset content content template with contact form in footer of wordpress post or page.

tssupport-ticket-screen_5 - I have to copy TEXT VALUE custom field [sht-cf-type] to post form field [tscf-topic-mirror]

Is there a similar example that we can see? -- Yep - hidden link

#1102547

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

I'm not quite sure I understand.

In your screenshots it looks like your contact form is already displaying "TEXT FOR ID 9".

You want to prefill a form field with the same?

Where does the form get the text TEXT FOR ID 9 from?

How is the form inserted?

#1103259

Hi Nigel, after 4 days trying found suitable solution with Minesh - today I was lucky to find an info about generic fields; that's your threat helped a lot - https://toolset.com/forums/topic/set-a-prefilled-cred-date-field-readonly/

the solution is:

<div class="col-sm-12"><div class="form-group">
      [cred_generic_field field='tscf-topic-mirror' type='textfield' class='' urlparam='']
      {
      "required":0,
      "validate_format":0,
      "default":"[types field='sht-cf-type' id='POSTID' format=''][/types]",
      "persist":1,
      "readonly":1
      }
      [/cred_generic_field]</div></div>