What is the difference between redirect and forward in Zend framework
Please provide real and practical examples.
both are totally different things _forward is internal redirection of zf , i.e practically user browser even dont know about this redirection , but inside zf all the hooks after predispatch gets invoked . Whereas in _redirect case user browser takes control of redirection and make second request hence everthing inside zf gets invoked once age (bootstrap , routing etc) .
clearely _forward is less resource intensive then _redirect but if you need the code inside bootstrap to be called (in case you have made changes in config and want it to reload) then you should do _redirect .