Data transfer between"main" site and secured virtual subsite
- by Emma Burrows
I am currently working on a C# ASP.Net 3.5 website I wrote some years ago which consists of a "main" public site, and a sub-site which is our customer management application, using forms-based authentication. The sub-site is set up as a virtual folder in IIS and though it's a subfolder of "main", it functions as a separate web app which handles CRUD access to our customer database and is only accessible by our staff.
The main site currently includes a form for new leads to fill in, which generates an email to our sales staff so they can contact them and convince them to become customers. If that process is successful, the staff manually enter the information from the email into the database.
Not surprisingly, I now have a new requirement to feed the data from the new lead form directly into the database so staff can just check a box for instance to turn the lead into a customer.
My question therefore is how to go about doing this? Possible options I've thought of:
Move the new lead form into the customer database subsite (with authentication turned off).
Add database handling code to the main site. (No, not seriously considering this duplication of effort! :)
Design some mechanism (via REST?) so a webpage outside the customer database subsite can feed data into the customer database
I'd welcome some suggestions on how to organise the code for this situation, preferably with extensibility in mind, and particularly if there are any options I haven't thought of. Thanks in advance.