Hello. I apologize if this is the wrong place to send something like this,
or if there's anything wrong with the way I'm going about this, but I'm
not quite sure what the normal practice on this type of thing is.

I have been confused by the mysterious credentials() arguments in the
past, and recently I've dealt with some folks on IRC who were similarly
confused. We thought it might be nice to modify the documentation to make
it a bit more clear, so I have written an extra paragraph that I think
might explain things more clearly.

I am not subscribed to the list, so I'd appreciate if any replies got
forwarded to my email address. Please let me know if there's
anything wrong with how I did the patch, etc. Thanks!

Carey
--- UserAgent.pm        2003-11-21 03:48:13.000000000 -0800
+++ UserAgent-revd.pm   2004-02-29 14:52:01.000000000 -0800
@@ -958,6 +958,14 @@
 Set the user name and password to be used for a realm.  It is often more
 useful to specialize the get_basic_credentials() method instead.
 
+$uname and $pass are relatively straightforward, but $netloc and $realm 
+might be confusing. These values can generally be obtained by looking 
+at the password prompt shown by most browsers. $realm will usually be 
+in quotes or parentheses, and $netloc will usually be the hostname 
+displayed. Note that $netloc should be simply the hostname with the 
+port appended (e.g. "www.example.com:80"), and should not contain 
+"http://"; in the front.
+
 =item $ua->max_size
 
 =item $ua->max_size( $bytes )

Reply via email to