At 3:26 PM -0400 9/30/99, Patrick wrote:
>The line that begins with "-->" is where I need to understand
>how I can easily truncate the "urlshow" down to, lets say, 60
>characters max (or whatever value is in "urlshow_length").
>
>    int     showurl_length = config.Value("urlshow_length");
>    char *urlshow = match->getURL();
>--> urlshow needs to be reduced down to "urlshow_length" bytes here <--
>    vars.Add("URLSHOW", new String(urlshow));

Since this is a char *, you can simply place a null character in the 
appropriate place.

urlshow[urlshow_length] = '\0';  // Remember that offsets start at 0

-Geoff


------------------------------------
To unsubscribe from the htdig3-dev mailing list, send a message to
[EMAIL PROTECTED] containing the single word "unsubscribe" in
the SUBJECT of the message.

Reply via email to