Page 1 of 1
Acceptable characters in string parm.
Posted: Wed May 18, 2011 9:25 am
by Jim Reed
Are there reserved characters other than '&' that cannot be passed in a parameter srting in a hyperlink? A '#' was included as part of a test address line, which caused the program to return "MCH3601 - pointer not set". Am I correct that the 'p' and 'l' in the parm value and length controls have to be lower case?
Re: Acceptable characters in string parm.
Posted: Wed May 18, 2011 1:31 pm
by David
Yes, the 'p' and 'l' parameter names must be specified in lowercase.
There are a number of characters which are reserved in URLs and must be encoded if they occur inside a parameter value.
Many languages have built-in functions for this. For example, if the links are created with JavaScript, you can use the encodeURIComponent() function to encode the data parts.
If the links are created with RPG, a good way to do it is to create an ILE sub-procedure to perform the encoding of those data parts for you.
See here for the set of reserved characters and their encodings:
http://en.wikipedia.org/wiki/Percent-encoding