0

How to pass when controller name is inside folder.

index.php?c=welcome

I tried this index.php?c=A/welcome which is not working.

2 Answers 2

1

The config file has this:

$config['controller_trigger']   = 'c';
$config['function_trigger']     = 'm';
$config['directory_trigger']    = 'd'; 

It says: "// experimental not currently in use"

I looked at the Router class that handles this and it looks like it uses the value passed in ?d= to set the directory...you might want to try that.

It would look like

index.php?d=A&c=welcome
Sign up to request clarification or add additional context in comments.

Comments

0

Just pass the folder name before controller and append the variables after it. like

  • index.php / foldername / controllerName / functionName

NOTE: Use of "index.php" is mostly depends on you as you have used them with others.

1 Comment

brother i know how to pass like this..i am trying to achieve this from query string index.php?c=a/name

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.