regsub, string concatenation?
phk at phk.freebsd.dk
Mon Apr 21 08:19:29 CEST 2008
In message <fuail6$ksu$1 at ger.gmane.org>, Jon Drukman writes:
>i'm trying to rewrite all incoming URLs to include the http host header
>as part of the destination url. example:
> set req.url = regsub(req.url, "^", "/site/" + req.http.host);
You can't do it directly right now, but this may be a feasible
set req.http.foobar = "/site/"
set req.http.foo = regsub(req.url, "^", req.http.foobar);
Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG | TCP/IP since RFC 956
FreeBSD committer | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
More information about the varnish-misc