[Tutor] urlparse question

Jaco.Smuts@za.didata.com Jaco.Smuts@za.didata.com
Mon, 26 Aug 2002 14:42:26 +0200

Hello there

I am busy writing a small app to extract keywords (amongst other things)
from search engine referer urls stored in a mysql database (using apache

1 - Please tell me if I'm re-inventing the wheel.
2 - If not , what I'm struggling with is to get the differnet url
querystring parameters, what am I missing ?

the url is

using urlparse I can get

urlValue[0] = 'http'
urlValue[1] = 'www.google.com'
urlValue[2] = '/search'
urlValue[3] = ''
urlValue[4] = 'hl=en&lr=&ie=UTF-8&oe=utf-8&q=south+africa+travel+cape+town'
urlValue[5] = ''

What I'm looking for is a way (using a library, not regex if possible) to
parse out of urlValue[4]

Any ideas ?

Thanks in advance
Jaco Smuts

This message contains information intended solely for the addressee,
which is confidential or private in nature and subject to legal privilege.
If you are not the intended recipient, you may not peruse, use,
disseminate, distribute or copy this message or any file attached to this
message. Any such unauthorised use is prohibited and may be unlawful. If
you have received this message in error, please notify the sender
immediately by e-mail, facsimile or telephone and thereafter delete the
original message from your machine. 
Furthermore, the information contained in this message, and any
attachments thereto, is for information purposes only and may contain the
personal views and opinions of the author, which are not necessarily the
views and opinions of Dimension Data (South Africa) (Proprietary) Limited
or is subsidiaries and associated companies ("Dimension Data"). Dimension
Data therefore does not accept liability for any claims, loss or damages
of whatsoever nature, arising as a result of the reliance on such
information by anyone. 
Whilst all reasonable steps are taken to ensure the accuracy and
integrity of information transmitted electronically and to preserve the
confidentiality thereof, Dimension Data accepts no liability or
responsibility whatsoever if information or data is, for whatsoever
reason, incorrect, corrupted or does not reach its intended destination.