Last modified: 2011-01-30 16:02:25 UTC
Background: I'm using a global setting page for a news package, and one of the setting set on that page is the namespace for new news entries. The news entry form is set up thus: {{#forminput:form=CFFC News Entry|query string=namespace={{#show: CFFC News Global Settings | ?CFFC News Namespace# -}}}} The problem is, the output form looks like this: <p><input type="text" name="page_name" size="25" value="" class="formInput" /> <input type="hidden" name="form" value="CFFC News Entry"> <input type="hidden" name="namespace" value="				 					News" /> <input type="submit" value="Create or edit" /></p> <p> </form> All that leading noise in the namespace value results in a page name that can't be created. The ideal solution would be to have #show, at least, strip leading and trailing white space, however that may have formatting consequences for people who've written, “some text{{#show: ...}}some other text”, and had white space inserted. For the time being, a work around I'm using is to pack the #show inside padleft, with the padding set to zero: {{#forminput:form=CFFC News Entry|query string=namespace={{padleft:{{#show: CFFC News Global Settings | ?CFFC News Namespace# -}}|0}}}}
What version of SMW are you using? Can you link to where this is occurring? If not, can you replicate it on a public wiki?
Semantic Bundle Version 0.6.20101202, so SMW 1.5.4. I see I'm out of date! Here's a test page: http://chch.ultimate.org.nz/wiki/view/User:Jwm/sandbox I'll upgrade in the next day and test again.
SMW 1.5.4 contained a whitespace issue, which has been fixed in 1.5.5.