A user on our site loads an 'events' page and decides to 'sign-up' for the event.
(I tried the 'signup' module, and whilst good, we need to go with webform for various reasons)
Luckily for the user, at the bottom of the event node I have placed a cck node reference.
This references a webform and displays the form in full.
We need to know WHICH event page the user is sending the form from.
So the first field in the webform is a text field with the default value: %server[REQUEST_URI]
When logged in with firefox or when logged out using chrome, it works; the form emails the url that
the person was viewing like: /events/k42-sahara-2010
However, WHEN LOGGED OUT, firefox (and I guess maybe some other browsers) is not passing the URI to the field.
I am guessing that chrome is not supposed to do this either, but is leaking the request?
I don't know anything about this stuff. I only came across %server[REQUEST_URI] by accident.
Unfortunately I only tested it in chrome when logged out - I had no idea there was an issue with it.
Does anyone know why it doesn't work for Guests? Is it a security thing in firefox?
Is there an alternative method of grabbing the URL or title of the node that will work on every browser?
This is urgent because we already have people signing up for these events.
The only problem is... I have to be out of town unexpectedly for two weeks and cannot work on it. DEADLINE today!
Thanks.
Comments
I've found out that $get[q]
I've found out that $get[q] returns 'node/[nid]' and displays it in the form field.
This seems to work on all the browsers I have, and whether logged in or not.
That at least gives us some reference to work from - I'll make a list of events versus node numbers
so that we can at least reply to clients without having to ask what event they were interested in.
HOWEVER, referencing the node id instead of the url or title is really not good enough.
It needs to be human friendly, so I need to keep looking for a better solution.
What is beyond me, really, is why %title isn't a token in webform?????
Thanks for any help.
this issue needs to be
this issue needs to be resoved first #630476: Allow hidden fields to handle unsafe tokens by making the "value" type fields
------
GiorgosK
Web Development
http://drupal.org/project/pre
http://drupal.org/project/prepopulate