Calling data into my form

I hope that I can explain this well enough.

I’ve built a private customer area for a client. I have small forms on different pages for customers to automate reordering common items… If you look at my form worksheet, you will see how simple the form is. The email address of the person ordering, the quantity of the order, and comments.

What I would like to do is, instead of forcing the user to self-identify their email address for the form results, I’d like to take that information from the database which is used to log the user into their private area. For example, I can call that data from the database into the html like so–

<?php echo $slemail; ?>

This will return the logged-in user’s email. So what I want to do is call that data into the form, like a hidden field so all the user has to complete is the order quantity and comments.

If you can help me to bridge that gap in my understanding of how this might work, I would be grateful.

http://myproof.thebigerns.com/form-worksheet/


offtopic mailing list
email@hidden
Update your subscriptions at:
https://freewaytalk.softpress.com/person/options

Okay, solved. Turns out to be simpler than I imagined.

I made a type="hidden" form field like so:

<input type="hidden" id="order-email" name="email" value="<?php echo $slemail; ?>"/>

Then pasted the string into a “value” attribute. The server processes the string on page load and sends the result to the form handler when the user submits the form.

Easy, peasy.


offtopic mailing list
email@hidden
Update your subscriptions at:
https://freewaytalk.softpress.com/person/options