|
|||
|
I installed zend framework 0.7 and its working fine. But now i would like to add a shoping cart under the
web_root/ directory so it would be web_root/shoppingcart/ but every time I go to my http://localhost/shoppingcart/ -> it redirects me back to index.php under web_root. How can I fix this? |
|
||||
|
Hello,
I am not quite sure regarding this matter... I don't have installed 0.7.0, my old sites are still under 0.6.0 (and i won't switch now cause i am afraid of potential compatibility problems) but using 0.6.0 i would simply put Zend.php into your localhost, and also Zend folder.... I think (but not sure), your problem has to do with: Using Zend_Controller in subfolder Check this tutorial to see if you can solve something... |
|
|||
|
Do you have mod_rewrite rules in effect?
You may need to append the file name to the URL to bypass them if they're in effect. e.g. http://localhost/shoppingcart/index.php should work. |
|
|||
|
Can you give me a simple example?
is there some way to do this through Zend? It seems like there should be a simple solution since this is such a common occurence to have a shopping cart installed in a different directory or a forum in a forum directory. How can I fix this? |
|
|||
|
Well, my solution perhaps,
1. Copy your Shopping folder into App/Views to produce: App/Views/Shopping. 2. Create ShoppingIndex.php in the App/Controllers. with function indexAction() to render your 'Shopping/index.php'. 3. That's all. I tried it based on your post, and it works. Hope it helps |
|
|||
|
Quote:
![]() |
![]() |
| Thread Tools | |
| Display Modes | |
|
|