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 9266531
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T14:20:27+00:00 2026-06-18T14:20:27+00:00

I am confused with codeigniter routing. I am implementing URL masking in my project

  • 0

I am confused with codeigniter routing. I am implementing URL masking in my project by using router in codeigniter.

From this I got confusion about the routing.routes has given below.

$route['project/shareToFacebook/(:any)']="project/shareToFacebook/$1";
$route['project/shareToFacebook/(:any)']="project/profile/$1";

My question is when I called the controller shareToFacebook what does route will do?

whether controller profile will be invoke or the controller shareToFacebook will be invoke?

  • 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-06-18T14:20:28+00:00Added an answer on June 18, 2026 at 2:20 pm

    Note: Routes will run in the order they are defined. Higher routes will always take precedence over lower ones.

    CodeIgniter user guide: Routing

    You will always be sent to shareToFacebook, but you will be sent to any of these routes only if you pass some parameters so when you will call the controller it will open it’s index method regardless, if you won’t pass any arguments.

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

Sidebar

Related Questions

Pardon for my beginner in object oriented PHP Codeigniter. I am confused about using
I'm thinking about using CodeIgniter for a new project. I was reading the user-guide
I am confused, again, about implementing OOP in CodeIgniter. By design, I have two
I am confused why codeigniter wont let me use this: $(function() { var csrf
I am using Active Record on CodeIgniter. I am confused on which approach I
Really confused why the QR output using RcppArmadillo is different than QR output from
Pretty confused right now, while i feel i know a bit about vhosts this
Got confused why this is giving me error I think my code is correct
Being confused again after reading about this anti-pattern and the many concerns about it
I'm little confused about controller and model in MVC framework (codeIgniter). Its clear to

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.