The [P]
flag on mod_rewrite rules is a new one on me, but from the docs it looks like it tells Apache to proxy the request to the given URL (using mod_proxy). So it actually makes another request to that URL internally and serves it back to the user, it's not a redirect. The equivalent in ZF would be to route the request to an action which uses Zend_Http_Client
to make another request to the remote server.
It can't think of any situation in which this would be a good idea. The example you gave is rewriting a request to a remote CDN. By doing this you completely negate all the advantages of having a CDN in the first place (better performance, lower bandwidth costs). Perhaps if you can explain your use case there might be a better way to achieve what you are trying to do.