Last modified: 2014-11-14 09:25:09 UTC
We need an ability to pass an empty string parameter, such as api.php?continue=&... -- this is especially critical with the new "continue" param that enables the simplified continue mode (empty string), or will be used in the subsequent api calls as a regular string returned from previous call. Implementation proposal: Every string parameter should have a checkbox in front of the text field (to allign with the boolean parameters). * User can set the checkbox to mean "send an empty string as value" * Starting to type in the text field should automatically set the checkbox. * Deleting text in the field would clear the checkbox. * Clearing the checkbox should delete all text.
Why is the magic value "" instead of something like "start"? To save bytes?
(In reply to comment #1) > Why is the magic value "" instead of something like "start"? To save bytes? :) No, but I didn't think the sandbox would not let me pass in an empty string value as a parameter. Also, there could be other modules that I am not aware of that may allow empty string parameters. That's why i think apisandbox should be able to handle such cases. This was also anomie's opinion when discussed on IRC. There was a number of other ideas - always return the "continue" element in addition to "query-continue" in the result, unless there was a "continue" parameter. Or add a "string|bool" api parameter type, and let apisandbox handle that as described above, while keeping all other strings as non-empty.