Posts Tagged ‘Zope’

$_SERVER['REQUEST_URI'] in Zope

Adam Alton - September 11th, 2009

Having a head that contains a PHP-shaped hammer I have a tendency to look for PHP-shaped nails when trying to make stuff.  So I’ve always been annoyed at not being able to find the equivalent of $_SERVER['REQUEST_URI'] in Zope.

Then the other day, when Rich was tweaking (read:fixing) the app that I built as my training project when I started at Rubber Towers he stuck in this:

x = self.REQUEST.ACTUAL_URL

Bingo!

It gives you the actual url that was requested by the browser, query string and all.  Sweet.