php - Custom querystring-based routing in CodeIgniter or Phalcon


I develop webapps for a relatively large enterprise. In order to follow the company's security policy of only using obfuscated URIs, I usually use a homebrew framework using the front controller pattern.

Before obfuscation, the URIs come in this format:

The entire query string gets processed first when generating links to produce URIs in this format:

where the value ofq isurlencode(base64_encode('controller=A&action=B'))

The front controller will, on receiving a request, first decode the value ofq and then set the parameters to$_GET, then the appropriate controller and action will be called based on that.

I'm about to start working on a new project and I want to try using a framework, either CodeIgniter (which I'm relatively familiar with) or Phalcon (which I would like to try). How do I implement this URI routing scheme in either framework? From my understanding both by default uses segment-based routing.

People are also looking for solutions to the problem: php - Laravel 5.3 Eloquent - How to post data to multiple tables with a form?


Didn't find the answer?

Our community is visited by hundreds of web development professionals every day. Ask your question and get a quick answer for free.

Ask a Question

Write quick answer

Do you know the answer to this question? Write a quick response to it. With your help, we will make our community stronger.

Similar questions

Find the answer in similar questions on our website.