ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Running Multiple Applications with one CodeIgniter Installation

July 17, 2008 9:24am

Subscribe [2]
  • #1 / Jul 17, 2008 9:24am

    khuzaimi

    4 posts

    refer from http://ellislab.com/codeigniter/user-guide/general/managing_apps.html

    if i running multiple application, how about folder config,controllers,views, etc… in my second application.

    is it i must download another fresh folder config,controller,... or make by own using mkdir config.

  • #2 / Jul 17, 2008 9:45am

    xwero

    4145 posts

    just copy the application directory for multiple apps and rename them.

  • #3 / Jul 17, 2008 10:27am

    khuzaimi

    4 posts

    in /var/www/codeigniter/index.php

    if ($application_folder == ‘’)
      {
    $application_folder = 'application/foo';
    $application_folder = 'application/bar';
    }

    like that?

  • #4 / Jul 17, 2008 10:36am

    AgentPhoenix

    137 posts

    Each application has to have it’s own index.php file so to speak.  In the case you gave, you’d duplicate index.php to foo.php and bar.php and then in each of those files, set the application folder for that particular application.

  • #5 / Jul 20, 2008 6:09am

    khuzaimi

    4 posts

    system/application/foo/
    system/application/foo/config/
    system/application/foo/controllers/
    system/application/foo/errors/
    system/application/foo/libraries/
    system/application/foo/models/
    system/application/foo/views/
    system/application/bar/
    system/application/bar/config/
    system/application/bar/controllers/
    system/application/bar/errors/
    system/application/bar/libraries/
    system/application/bar/models/
    system/application/bar/views/

    that mean each application like foo and bar have foo.php and bar.php at the same level system/

    it is possible to have index.php for foo and bar application

  • #6 / Jul 20, 2008 12:41pm

    Randy Casburn

    997 posts

    @khuzaimi—can you describe what you want to achieve?

    The basic idea then would be to call your ‘foo’ application with:

    http://yoursite.com/foo.php

    and call your ‘bar’ application with:

    http://yoursite.com/bar.php

    and you would set up a basic home page called index.php that would provide a menu to access either of these.

    if you want more functionality there are other options.  You can search the forums for ‘HMVC’ for other ways of setting up your applications too.

    Hope this helps,

    Randy

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases