Bugs :  K-Meleon Web Browser Forum
You can talk about issues with k-meleon here.  
$ARG stopping on comma in value
Posted by: JamesD
Date: June 30, 2009 08:17PM

In both the setmenu() and setaccel() statements, an augument that contains a comma will delete the comma and everything following the comma when a variable is set to the $ARG value.

EXAMPLE
Snippet_ArgCode{
$_Snippet_ArgVal = $ARG ;
alert($_Snippet_ArgVal. "  is the ArgVal", "Snippet_ACCEL_ArgCode  DEBUG:, INFO);
}

_Snippet_accelerators{
setaccel( "CTRL SHIFT VK_F9" ,"macros(Snippet_ArgCode(Charlotte, NC))"); 
}

$_Snippet_ArgVal will only contain "Charlotte".

In this thread http://kmeleonbrowser.org/forum/read.php?1,94047 the urlencode() and urldecode() had to be used to process a URL containing a comma.

Options: ReplyQuote
Re: $ARG stopping on comma in value
Posted by: kko
Date: July 01, 2009 07:56PM

Well, yes. An argument containing a closing parenthesis will have the same effect. smiling smiley

I just wouldn't say it's a bug. You have to be careful when using macro arguments. From my point of view, it's not the purpose to store arbitrary data in the menu/accel system. This is a misuse. Use macro variables or the preferences system to store data.

The default macros demonstrate best practice, hotlink.kmm is a good example.

Options: ReplyQuote
Re: $ARG stopping on comma in value
Posted by: JamesD
Date: July 01, 2009 09:51PM

@ kko

OK, I can buy in to that. I was able to work around when I needed to so it is not a big deal.

Options: ReplyQuote


K-Meleon forum is powered by Phorum.