* Blinky the Shark is quoted & my replies are inline below :
> John E. Davis wrote:
>> On 6 Sep 2007 06:02:50 GMT, Blinky the Shark < @ >
>> wrote:
>>> /stuff/comp/
>>
>> What version of slang are you using? If you are using version 1,
>> you will need to replace lines such as
>>
>> throw InvalidParmError, "foo";
>>
>> with
>>
>> error ("foo");
>>
>> try/catch/throw/finally semantics were not added until version 2.
>
> Bingo! That got it, John.
>
> I sure can't figure out why I reported it working yesterday, after he
> added his header checks.
> it on some posts - not just testing it - later.
>
> Is this all because I just turned 60? :)
>
> Here's the version for slang v1.
>
> #v+
> %
>
> define whois_postinghost () {
>
> variable status= is_article_visible ();
>
> if ( status & 1) {
> variable postinghost= extract_article_header ( "NNTP-Posting-Host");
>
> variable ph_exists= strlen ( postinghost);
>
> if ( ph_exists > 0) {
> () = system ( "whois "+postinghost+" | less");
> } else {
> error ("This article doesn't contain a NNTP-Posting-Host header");
> }
>
> } else {
> error ("You need to display the article to check");
> }
>
> }
>
> definekey ( "whois_postinghost", "\eH", "article");
> #v-
>
> I hope those delimiters work; I've never tried using them before, and I
> hope the characters I *see* in Troy's posts are what one actually enters
> when trying to delimit code.
Yep, looks fine here.
> I wonder why in the first-line comment it's not referred to as
> .
Because I have adopted as the filename here, and that's
what I've quoted on my web page. Sorry for the confusion. Both
work.
--
Troy Piggins | /~troy
** NEW MACRO 5/9/07 ** ___ | __ __ ,-O (o- O
slrn macros and howto: |___ | |/ |/ | O ) //\ O
/~troy/slrn ___| | | | | `-O V_/_ OOO