Problem with this command

0 views
Skip to first unread message

Klink C

unread,
Dec 23, 2007, 2:45:47 PM12/23/07
to YubNub
This command seems to be on the fritz. Can anyone help me out?
http://
{strReplace -find / -replace -string
{%
-{strFind -find / -string
{% 1 %s}
}
{% 1 %s}
}
}
.
{switch {% 2 %s} | c => com, o => org, n => net, g => gov, => com, *
=> {% 2 %s}}
{if0 -value
{strFind -find / -string
{% 1 %s}
}
-else
{%
{strFind -find / -string
{% 1 %s}
}-
{if0 -value
{strFind -find " " -string %s}
-else {strFind -find " " -string %s}
}
%s}
[no url encoding]

when I enter "google," it returns: http://Error!, or you are using a
YubNub command incorrectly..com{if0 -value 0 -then -else Error!, or
you are using a YubNub command incorrectly.

when I enter "google/history," it returns: http://googlehistory.com{if0
-value 7 -then -else

when I enter "google n," it returns http://Error!, or you are using a
YubNub command incorrectly..net{if0 -value 0 -then -else Error!, or
you are using a YubNub command incorrectly.

when I enter "google/history n," it returns http://googlehistory.net{if0
-value 7 -then -else

I can't seem to figure this out, and I've been working on this for
hours now.
Bonus points for anyone who can figure out what this command will do-
(Hint: I'll call it ffurl)

Brian

unread,
Dec 26, 2007, 5:40:50 PM12/26/07
to YubNub
Klink,

If I understand correctly what the command should do, this should
work:

http://{iff {strfind -find / -string {% 1 %s}} -then {strreplace -
find / -replace .{switch {% 2 %s} | c => com, o => org, n => net, g =>
gov, => com, * => {% 2 %s}}/ -string {% 1 %s}} -else {% 1 %s}.{switch
{% 2 %s} | c => com, o => org, n => net, g => gov, => com, * => {% 2
%s}}} [no url encoding]

If that's not what you are trying to do, let me know.

Brian
> when I enter "google n," it returnshttp://Error!, or you are using a
> YubNub command incorrectly..net{if0 -value 0 -then -else Error!, or
> you are using a YubNub command incorrectly.
>
> when I enter "google/history n," it returnshttp://googlehistory.net{if0
Reply all
Reply to author
Forward
0 new messages