Own Variables
-
Hi Folks
Thank you for this awesome plugin!
I was looking on how to get the Form Fields prefilled but did not succeed until I tried to use one of the pre-defined Variables like {CurUserLastName}. Great, this cannot only be use for the Mail but also to prefill the fields. Unfortunately the amount of pre-defined Variables is quite limited.
What I would like to achieve is to grab as may fields of the logged in user as possible. Since I have WP-Members (other Plugins provide similar functionality) installed I have many more of such fields ?? Luckily these additional fields are stored in the Users Meta Data.
I have figured out that I can add own CurrUser-Variables quite easily by adding more lines to the lib_aux.php, e.g.:
$m = str_replace( '{CurUserLogin}', $CurrUser->user_login, $m ); $m = str_replace( '{CurUserStreet1}', $CurrUser->addr1, $m ); $m = str_replace( '{CurUserZip}', $CurrUser->zip, $m ); $m = str_replace( '{CurUserCity}', $CurrUser->city, $m ); $m = str_replace( '{CurUserTelefon}', $CurrUser->telefon, $m ); $m = str_replace( '{CurUserMobile}', $CurrUser->mobile, $m );
Now I am a bit afraid that I will lose this with the next update. Is there any chance you guys provide the possibility to set up such Variables in e.g. Global- or Form-Settings or in a dedicated File that will be hooked into lib_aux.php?
Thanks a lot for your efforts.
Brgds
Ivo
- The topic ‘Own Variables’ is closed to new replies.