Welcome Guest, Not a member yet? Register   Sign In
calling an application function from another application
#1

[eluser]bkarat[/eluser]
Hi !

We have two intranet applications that was built using CodeIgniter. Following is the directory structure used for this:

...Root
- Apache
- CodeIgniter_1.7.1
- PHP
- Application1
- application
- config
- controllers
- errors
- models
- views
.
.
- index.php
- Application2
- application
- config
- controllers
- errors
- models
- views
.
.
- index.php

We have login function for both the applications. When a customer buys both the applications, they want only single login. We don't want to combine the applications to one, as most of the customers buy only one application. How best this can be realized without duplicating unnecessary folders?

We tried to make a common application with login function and one controller and view functions. On start up, login function is called and on successsful login the view function is called where user can select the application required. The two applications were kept under the common application. But we find that folders like 'Config' are to be kept under each application. Is there any other way?

Basically, though we have two applications, can we do such a way that CodeIgniter see it as single application (we want the convenience of maintaining the two applications separately)?

Thanks in advance.

Best regards,
Bala
#2

[eluser]louis w[/eluser]
It might be easiest to have both applications include a login functionality however give them both the same cookie scope. If they share cookies (make sure there would not be any other conflicts) then if a user logs into Application 1 they would also be logged into Application 2.
#3

[eluser]bkarat[/eluser]
Hi !

Thank you. Yes, this should do the job. Basically I have to use the same session name in both the applications (correct?). Also, I have to initialize all the session parameters at both the places?

Best regards,
Bala




Theme © iAndrew 2016 - Forum software by © MyBB