0

I am trying to create a webform to appear at the end of all my site pages that asks if there is anything about the page that should be improved. This is dumped straight into the page. In order for this to make sense I need to be able to record the url the form was shown on.

I tried to dump these tokens into the default value for a field

%nid %title

but they output the nid of the webform not the page it is dispayed as a block on.

If the user is logged in I can use

%server[SCRIPTNAME]

which works but almost all my users won't be logged in.

Is there a way I can get this information into a field on my form? Otherwise my feedback for is useless.

1 Answer 1

-1

you can use form alter .get the values from url put the values using form alter to default fields .

2
  • 1
    Could you explain how he could do this?
    – Mołot
    Commented Aug 12, 2014 at 9:25
  • he just need to add another textfield or an integer field say node id in hidden format or so then alter the form get the node values from the url(i.e node id) . prefilled that field node id by the the value from url. Commented Aug 12, 2014 at 9:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.