Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#37 2007-10-21 11:42:46

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

I’d do it like this:

<txp:php>
  echo zem_contact_select(array(
    'label'    => 'Department',
    'list'     => ',Doug,Sarah',
    'selected' => ucfirst(gps('to'))
  ));
</txp:php>

Offline

#38 2007-10-21 18:54:17

Logoleptic
Plugin Author
From: Kansas, USA
Registered: 2004-02-29
Posts: 482

Re: zem_contact_reborn 4.0.3.20

ruud wrote:

I’d do it like this:

Ooh, I wasn’t aware of the built-in gps() function. Its buddy gpsa() also looks interesting. I’ve been considering “adopting” chs_if_urlvar and doing rewrites, and these would come in handy.

What’s the etiquette for plugin adoption, by the way? I hope that’s not too off-topic for this thread, but considering ZCR’s origins and history it seems like a good place to ask.

Offline

#39 2007-10-21 19:30:46

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

Ask the original author (or current maintainer) of the plugin first, I suppose.

Offline

#40 2007-10-21 23:08:19

Logoleptic
Plugin Author
From: Kansas, USA
Registered: 2004-02-29
Posts: 482

Re: zem_contact_reborn 4.0.3.20

ruud wrote:

Ask the original author (or current maintainer) of the plugin first, I suppose.

Tried it, but I’ll try again. Thanks for the tip. :-)

Offline

#41 2007-10-22 14:24:37

novatron6
Member
Registered: 2006-10-15
Posts: 11

Re: zem_contact_reborn 4.0.3.20

ruud wrote:

I’d do it like this:

<txp:php>
  echo zem_contact_select(array(
    'label'    => 'Department',
    'list'     => ',Doug,Sarah',
    'selected' => ucfirst(gps('to'))
  ));
</txp:php>

Thanks alot, this works awesome!

doug

Last edited by novatron6 (2007-10-22 14:25:00)

Offline

#42 2007-10-31 21:49:17

sazan1978
New Member
Registered: 2007-10-31
Posts: 2

Re: zem_contact_reborn 4.0.3.20

Is there any way to set a type=“hidden” for a field? It doesn’t seem to be an attribute of zem_contact_text or other tags…

I tried adding html code inside the <txp:zem_contact>:

<input type=“hidden” name=“code” value=“some_code” />

it shows up in page source, but it not included in the results that are emailed.

Offline

#43 2007-11-01 01:08:04

Logoleptic
Plugin Author
From: Kansas, USA
Registered: 2004-02-29
Posts: 482

Re: zem_contact_reborn 4.0.3.20

sazan1978 wrote:

Is there any way to set a type=“hidden” for a field?

It would help to know what you’re trying to accomplish by including a hidden field. Even if the option doesn’t exist in this version of ZCR (I haven’t yet checked), someone might be able to suggest an alternate approach.

Offline

#44 2007-11-01 07:10:01

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: zem_contact_reborn 4.0.3.20

I think the txp:zem_contact_secret tag in ZCR performs the function you are looking for. Read the plugin help, or do a search of this thread and you should find more information.

Offline

#45 2007-11-01 09:53:34

Logoleptic
Plugin Author
From: Kansas, USA
Registered: 2004-02-29
Posts: 482

Re: zem_contact_reborn 4.0.3.20

The zem_contact_secret tag won’t work for sazan, because the contents of the tag show up in the e-mail message.

I just checked the documentation and can’t find any mention of a way to create hidden fields (at least, nothing turns up when I search the help page for ‘hid’).

Offline

#46 2007-11-01 10:23:50

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

Isn’t that what he wants, having the hidden field show up in email?

Offline

#47 2007-11-01 10:34:50

Logoleptic
Plugin Author
From: Kansas, USA
Registered: 2004-02-29
Posts: 482

Re: zem_contact_reborn 4.0.3.20

sazan1978 wrote:

it shows up in page source, but it not included in the results that are emailed.

My understanding of that is that the hidden fields should be hidden in the e-mail as well. Sazan, can you confirm?

Offline

#48 2007-11-01 11:08:30

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

Then what’s the purpose of using ZCR if the fields should not appear in the email if neither submitter nor recipient sees them?

Offline

Board footer

Powered by FluxBB