user-signup and dynamic values

3 posts by 2 authors in: Forums > CMS Builder: Plugins & Add-ons
Last Post: July 19, 2017   (RSS)

By Twocans - July 14, 2017

Hi yea,
I would be grateful for any input. 

in the email templates i have templates like USER-SIGNUP1, USER-SIGNUP2 etc etc and they all work when I assign the value directly in the websitemembership page. 

How can I best assign a dynamic value to USER-SIGNUP, 

'template_id' => 'USER-SIGNUP2',    <<< this works this is in the websitemembership page 

= emailTemplate_loadFromDB(array(
//'template_id' => 'USER-SIGNUP2',
'template_id' => USER-SIGNUP . $_REQUEST['countrylang'],        <<<< this does not work

I have added a hiddenfield to the signup form area in itself with a dynamic value in it. when the form is submitted I had thought that USER-SIGNUP . $_REQUEST['countrylang'], would have given me the desired effect

thanks for any help

kenny

By Dave - July 18, 2017

Hi Kenny, 

You can simplify it by just defining a variable to start.

$template_id = "USER-SIGNUP". $_REQUEST['countrylang'];
print "\$template_id = $template_id\n"; // debug

See if you can get that printing the expected value first, then add it to your function call: ed

'template_id' => $template_id, 

Let me know if that works for you.

Dave Edis - Senior Developer
interactivetools.com