You don't want to urlencode the entire URL because it will encode things like the colon and forward-slash. Instead, you'll need to split up your url into parts and only encode the parts between the forward-slashes (after the domain).
An easier way to do this is use the "url" view helper. It automatically encodes the parameters for you by default. You can disable encoding by passing in false to the 4th parameter when invoking the helper. -- Hector 2010/5/12 Саша Стаменковић <[email protected]> > Hi. > > I'm trying to crawl some images from the web, and I have problem when there > is space in url. Example > http://www.site.com/images/ArticleImages/SpaceFolder/Img_320X250.jpg gives > exception 'Zend_Uri_Exception' with message > 'Invalid URI supplied' in D:\Libraries\ZendFramework\Zend\Uri\Http.php:156. > > If I urlencode it, then schema is not valid. Should I parse and rebuild URL > or there is some easier way around this? > > Regards, > Saša Stamenković >
