I built a site in Dreamweaver a while ago and have revamped it to ‘version 2’
I managed to get user log-in to authenticate with Active Directory and have added $_SESSION[‘MM_adUser’] for their full AD name.
This seems to work fine as adding:
<?php $_SESSION['MM_adUser']; ?>
to the page, shows the users full name in the browser .. ie: John Smith
However, i now want to insert this into MySQL, so i added to the bottom of the page (with some other misc variables):
<input name="SavedBy" type="hidden" value=<?php $_SESSION['MM_adUser']; ?> />
but it only inserts the users first name! Removing type=”hidden” does indeed show it on the page as only their first name.
Question is, why the change? Why is it losing the last name?
I’m guessing it has something to do with whitespace as this came up in an error when trying various fixes, but, alas, i can’t fix it 🙁
Any ideas, please?
Note the
echo