|
|||
|
I got a question is it possible to use Zends rerouter to reroute from
http://anto.example.com to http://example.com/profile/index/username/anto ? |
|
|||
|
I dont know if there is a way with the zend framework to do this, so could someone please advise if there is.
If I was just taking a proceedural approach, First you would make sure that you have a wildcard for your domain. *.mydomain.com all points to 10.0.0.1 Next, you use $ SERVER variable to grab the URL. I can't remember what the variable is, but I have done it before. Its HOST something. Anyway, once you isolate your domain, simple REGEX will grab the subdomain, and then an easy 301 redirect to the /path/to/page works a charm. Now if anyone knows a way in ZF to do this, it would save me some problems for a future project. |
|
|||
|
there is no such feauture in ZF, however you can extend functionality of Zend_Controller_Router, check out here: Nabble - Zend Framework - map domain name to module
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|