We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 1920
    • 8 Posts
    Hi all,

    I’m still a noob when it comes to MODx (and PHP as a matter of fact) and I’m working on a site that’s running v0.9.6.2. What I’m looking to do is take a registered user’s full name and email address and populate it into a simple eForm. The eForm is in place and works fine, but when I try to use the [+user.fullname+] and [+user.email+] calls in the form as value="" (to put in their full name and email), I get nothing. Do I need to have some additional PHP code in my form in order to pull up this info?

    For a little more background, when the user logs in (using WebLoginPE), they are automatically taken to this form. The form basically posts the user’s name, email and invoice number to a DB table (using eForm2DB) that then get’s read by a service on our server to post an invoice via email (which I’d like to be able to do on the fly w/ a PDFlib form).

    As a side note, for now I’m running my login section in a column of my template and everything flows fine b/w the main content area and the sidebar, but when a user goes to register, fills out the form and clicks on the Register button, the registration form pops up in my sidebar. Also, the registration page doesn’t go to my "success" page to let the user know that they can go ahead and log in to the site.

    I can provide just about any info that you may need in order to give me some help. For starters, I’m running this site (www.routemanagement.com) on a Windows 2003 Server (yes, I know it sucks) running PHP5 and MySQL5. Please let me know what I need to do/where I need to look.

    Thanks,
    A
      • 27442
      • 103 Posts
      For your placeholders, you can use [+view.fullname+] and [+view.email+]

      To have the sidebar register button take the user to a new, full page use the &regHomeId parameter. Something like: [[WebLoginPE? &regHomeId=`xx` &profileHomeId=`xx` &loginFormTpl=`LoginChunk` &liHomeId=`xx,xx` &loHomeId=`xx`]] Note: this seperate registration page should use a duplicate of your normal template with the only difference being that this duplicate template does not have the WebloginPE call in the sidebar (2 WebloginPE calls on the same page do strange things)
        • 1920
        • 8 Posts
        I’ve tried the [+view.fullname+] and [+view.email+], but it didn’t work. I wonder if I need to embed some PHP into the form’s snippet that does a GET to pull the info.

        Thanks for the help w/ the double calls of WebLoginPE - I’ve redone my template to make it work and it doesn’t "freak" out any more