0

I want to remove controller and function name from my url. my url looks like

example.com/config/addRoom.aspx

where "config" controller name & "addRoom" function/method name. I am using htaccess for remove index.php. and I configure my routes.php file like this

    $route['room'] = "config/addRoom";

but it's not working. pages are not found plz help

2
  • try url example.com/room Commented Oct 21, 2014 at 11:01
  • @RakeshSharma it redirect me the same page like this link example.com/config/addRoom.aspx when i write this url manually but i want when i visit example.com/config/addRoom.aspx this link by clicking menu that is <?php echo anchor('config/addRoom', 'Room Config');?> my url will be look like example.com/room. haow can i do this? Commented Oct 21, 2014 at 11:20

1 Answer 1

1

Please Write "room" at the place from where you want the redirection .. like now you are writing

in Controller :- redirect("config/addRoom") ;

Make It Redirect("room");

Or In View :- now you are write like href="config/addRoom"

Please Make it

href="room"

Sign up to request clarification or add additional context in comments.

Comments

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.