Answers.Body: <p>The base URL is set in civicrm.settings.php.</p>
  
  <p>I can imagine you create a conditional statement in there.</p>
  
  <p>You should try if $_SERVER['SERVER_ADDR] or $_SERVER['SERVER_NAME'] is the right variable for you to differentiate between the 2 situations.</p>
  
  <p>More info:
  <a href="http://php.net/manual/en/reserved.variables.server.php" rel="nofollow">http://php.net/manual/en/reserved.variables.server.php</a></p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-01-22T07:12:59.620Z
Answers.LastActivityDate: 2016-01-22T07:12:59.620Z
Answers.UserDisplayName: Catorghans
Body: <p>I have </p>
  
  <pre><code>*CiviCRM 4.6.6 on 
  *Drupal 7.41 running through 
  *Apache2 on 
  *Linux Mint 17 in a VirtualBox on Linux Mint 17 
  </code></pre>
  
  <p>If I am on the LAN I can access CiviCRM and everything works:</p>
  
  <p>10.141.229.171/?q=civicrm/dashboard <em>everything works</em></p>
  
  <p>I also have a VPN that can connect to the drupal server and when I connect I get to log into CiviCRM but then CiviCRM stalls while it tries to connect to the LAN address so the system fails to work. </p>
  
  <p>If, at that point, I stop the browser from continuing to load I can use the CiviCRM dropdown menus and go to almost any other page, including the Drupal menu. As far as I can tell only the dashboard fails to load.</p>
  
  <p>_http://10.12.0.23/?q=civicrm/dashboard <em>-- stalls with the message: "Connecting to _http://10.141.229.171..."</em> </p>
  
  <p>Note: I inserted an underscore just to prevent creating a real link in this message.</p>
  
  <p>I know that the CiviCRM addresses are set to the 10.141.229.171 address but I would like my VPN clients to access the site as well.</p>
  
  <p>The best I can come up with is that I need to set my VPN computer so that:  Any link for 10.141.229.171/page_name gets rewritten to be sent as
  10.12.0.23/page_name   -- I tried a few FireFox addons to accomplish this but they failed to work, perhaps because of Java Script?</p>
  
  <p>Again, it seems to fail only with the dashboard.</p>
  
  <p>Unfortunately I am struggling to find out how to fix that. Is it even the right way? Can it be done in any way?</p>
  
  <p>Thank you in advance for any help you can provide. John in Oregon, US</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2016-01-22T09:36:37.277Z
Comments.Text: Can your LAN clients access 10.12.0.23?  If so, you could change the base URL to use that and LAN & VPN clients use the same address.
Comments.UserDisplayName: Aidan
Tags: <dashboard><webserver>
Title: VPN and LAN connections
ThreadText: # VPN and LAN connections
  
  (Asked by: username_0 on 2016-01-22)
  
  I have 
  *CiviCRM 4.6.6 on 
  *Drupal 7.41 running through 
  *Apache2 on 
  *Linux Mint 17 in a VirtualBox on Linux Mint 17 
  
  If I am on the LAN I can access CiviCRM and everything works:
  10.141.229.171/?q=civicrm/dashboard everything works
  I also have a VPN that can connect to the drupal server and when I connect I get to log into CiviCRM but then CiviCRM stalls while it tries to connect to the LAN address so the system fails to work. 
  If, at that point, I stop the browser from continuing to load I can use the CiviCRM dropdown menus and go to almost any other page, including the Drupal menu. As far as I can tell only the dashboard fails to load.
  _http://10.12.0.23/?q=civicrm/dashboard -- stalls with the message: "Connecting to _http://10.141.229.171..." 
  Note: I inserted an underscore just to prevent creating a real link in this message.
  I know that the CiviCRM addresses are set to the 10.141.229.171 address but I would like my VPN clients to access the site as well.
  The best I can come up with is that I need to set my VPN computer so that:  Any link for 10.141.229.171/page_name gets rewritten to be sent as
  10.12.0.23/page_name   -- I tried a few FireFox addons to accomplish this but they failed to work, perhaps because of Java Script?
  Again, it seems to fail only with the dashboard.
  Unfortunately I am struggling to find out how to fix that. Is it even the right way? Can it be done in any way?
  Thank you in advance for any help you can provide. John in Oregon, US
  
  **Tags:** dashboard, webserver
  
  > **Comments:**
  > **username_1**: Can your LAN clients access 10.12.0.23?  If so, you could change the base URL to use that and LAN & VPN clients use the same address.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_2 on 2016-01-22. Score: 1
  
  The base URL is set in civicrm.settings.php.
  
  I can imagine you create a conditional statement in there.
  
  You should try if $\_SERVER['SERVER\_ADDR] or $\_SERVER['SERVER\_NAME'] is the right variable for you to differentiate between the 2 situations.
  
  More info:
  <http://php.net/manual/en/reserved.variables.server.php>
  
  
  ---
  
  