[wp-hackers] Possibly OT: Question about rewriting external links
David Chait
davebytes at comcast.net
Fri Jun 23 03:08:08 GMT 2006
JS is a good approach.
Another would be something that output buffers the entire page -- if not
running an advanced-cache system (i.e., WP-Cache 2), you could hook in
there, do what it does, but rewrite all links in the html... Or run a
modified WP-Cache 2 that does your rewrite AND caches the rewritten
versions, and then flush it when the system is all back online and disable
the rewriting.
-d
----- Original Message -----
From: "Paul Menard" <codehooligans at codehooligans.com>
To: <wp-hackers at lists.automattic.com>
Sent: Thursday, June 22, 2006 10:55 PM
Subject: [wp-hackers] Possibly OT: Question about rewriting external links
| Hey all,
|
| This morning I received an urgent client call. I put together this
| site, about 80 pages, a few weeks ago. On this site, are links that
| take the user to an external eCommerce system to purchase products.
| Seems this external system was down so the client wanted me to go
| through the pages and change the links to point to a local page with
| a message that the eCommerce system was down blah blah blah.
|
| I was able to put together a quick JavaScript function to read all
| the anchors on page load and changed the href. So no big issue. Sure
| I could have build some plugin filter to handle this and convert the
| content. But there are some hard-coded menu links and sidebar
| template text not page of page/post content.
|
| I was wondering is there a good way via Apache or whatever to rewrite
| the URL as the page exits the Web server? Meaning to my knowledge for
| example rewrite rules are performed when the user hits the server,
| inbound. I'm looking to see if there is some filter to convert links
| as part of the outbound delivery to the client browser.
|
| I don't expect to find an answer. Just looking to make sure I'm not
| missing something.
|
| P-
| _______________________________________________
| wp-hackers mailing list
| wp-hackers at lists.automattic.com
| http://lists.automattic.com/mailman/listinfo/wp-hackers
|
More information about the wp-hackers
mailing list