Feature Requests
Share ideas, discuss and vote on requests from other users in community
This object is in archive! 

Cookies and/or session variables across subdomains

Tim Shackelford shared this idea 5 years ago
Under Consideration

I have a site at http://www.mainsite.com (fake domain) hosted at GoDaddy, and a WHMCS install on AWS at whmcs.mainsite.com.

I would like to be able to access cookies and/or PHP session variables from http://www.mainsite.com within whmcs.mainsite.com.

The example case is we provide services to people within certain geographic locations, so we have a tool which takes an address provided by a potential customer on the http://www.mainsite.com site and checks against a coverage area. The address they provide is stored as a PHP session variable. If they are within a coverage area, we allow them to select a product (using WHMCS direct product link) which then takes them to the checkout page on whmcs.mainsite.com. I would like to be able to access the address session variables set at http://www.mainsite.com while on the checkout form on whmcs.mainsite.com. I need to be able to insert these values into custom fields for WHCMS so they appear on the Client's profile screen after they submit their order. The address info here will in some cases differ from the billing info they provide, but should not be something they can modify at this stage of the checkout process, hence the hidden custom fields with the session address values.

It's my understanding this or similar functionality was part of a previous version of WHMCS, but was removed presumably for security reasons. If there's a secure way to handle this, it should would be convenient for those of us operating external sites that are using WHMCS for order processing, provisioning, billing, and CRM.