title: Displaying values related to a lookup field
body: <p>I'm very new to working with Visualforce and Salesforce, so please bear with me on this...I'm teaching myself how to build visualforce pages by replicating a form that our sales rep use to document orders received. I'm having a really hard time figuring out how to do some (probably) very basic things, and I'm hoping someone can help point me in the right direction. I've found a lot of instructions on how to do things that are either part of what I want or similar but not what I'm looking for, and it's made me very very confused about what needs to be done to make this particular goal work.</p>
  
  <p>Here's what I've done so far...</p>
  
  <p>I've set up a Lookup field on my page that allows the user to populate who the sales rep is (using the User object). I'm kind of confused as to why I'm presented with a textbox and a search button, and not just presented with a drop-down box of Reps to select from, but I guess that's neither here nor there...</p>
  
  <pre><code>&lt;apex:page standardController="Order__c" extensions="OrderNewExtension"&gt;
  &lt;apex:actionRegion &gt;
      &lt;apex:inputField value="{!Order__c.User__c}" required="true" id="userID"&gt;
          &lt;apex:actionSupport event="onchange" reRender="salesRepDetails" /&gt;
      &lt;/apex:inputField&gt;
  &lt;/apex:actionRegion&gt;
  
  &lt;apex:outputPanel id="salesRepDetails" rendered="true"&gt;
      &lt;table border="0" cellspacing="0" cellpadding="5" width="75%" style="border: 1px solid magenta;"&gt;
          &lt;tr&gt;
              &lt;td colspan="2" width="50%"&gt;&amp;nbsp;&lt;/td&gt;
              &lt;td&gt;&lt;apex:outputLabel value="Phone: " for="repPhone" /&gt;&lt;/td&gt;
              &lt;td class="data"&gt;***Something needs to go here***&lt;/td&gt;
          &lt;/tr&gt;
          ...
      &lt;/table&gt;
  &lt;/apex:outputPanel&gt;
  </code></pre>
  
  <p>I'd like to do two things with this - </p>
  
  <p>1) After the user chooses the sales rep is, I want the chosen rep's email and phone number to display.
  2) (sorta optional) I'd like this field to be pre-populated with the current user's name and data, that way the only time the rep would have to be looked up is when one of our support staff is entering something in for someone else. Does this make sense?</p>
  
  <p>I'm not sure what else is needed for anyone to help me, but if it's within my power to get that info on here, I will do so.</p>