Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6001677
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T00:52:07+00:00 2026-05-23T00:52:07+00:00

I am using Tank Auth library in Codeigniter with HMVC and the entire tank

  • 0

I am using Tank Auth library in Codeigniter with HMVC and the entire tank auth mvc files are in its own module called ‘auth’. tank auth loads a view (domain.com/application/modules/auth/views/auth/login_form.php) found inside a folder (auth) using:

$this->load->view('auth/login_form', $data);

As far as I know the above code will load login_form.php inside the auth folder properly without HMVC. However with HMVC, I need the following code to get the view to load:

$this->load->view('auth/auth/login_form', $data);

Is there a setting that we should change so we dont have to refer to the view file by (module name)/(views folder name)/(view filename) ? Or is this perfectly normal and most people does it this way?

It seems troublesome that I have to add the module folder name ‘auth’ to every view() function call, and change all of them should I change the name of the module folder.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T00:52:08+00:00Added an answer on May 23, 2026 at 12:52 am

    Assuming you’re using Modular Extensions – HMVC:

    If you have auth set up as a module already, you can just call:

    $this->load->view('login_form', $data);
    

    The file /views/login_form.php will be loaded from within the current module. This applies to models, language files, libraries etc. Think of the module as its own application, this is what you would normally do.

    Additionally, to load a file from another module or a controller outside the module’s directory, you can use $this->load->view('auth/login_form');

    If the file is not found, it will check the other module paths including the default directory. This may or may not be the way other HMVC packages work, I’m not sure – but it’s the way MX works.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using Codeigniter PHP Framework with Tank Auth authentication library. In my config
I am using the Tank Auth library for CodeIgniter. When a user is registered,
I am using Tank Auth authentication library with Codeigniter 2.0.3 (one version before the
Using Tank Auth for first time along with HMVC. In my application there are
I'm using Codeigniter and Tank Auth for a e-commerce website. I'm finding that if
I am using Tank Auth for Codeigniter to facilitate user registration and login. Problem:
I don't do much PHP but I saw this library called, Tank Auth for
I'm using CI's Auth Tank library to query records for certain users. The variable
I found another bug in my cms where Im using the Tank Auth library
I have a simple tank wars style game using the allegro open source library.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.