I can't "open a bug" (bugzilla is very confusing for me) and I don't know how to browse old proposals/requests, so I feel better to post here two ideas, just to let you revise them and - if you like - to go on into bugzilla.
1. I'd like to have a {{nbsp:string}} function, to replace all spaces with html entities into string. It would very useful to format table cell content where spaces must be avoided, while saving the original string.
2. I'd like to generalize {{#titleparts:string}} transforming it into a general str.split() function something like {{split:string|char}} where string is the string to split, and char is the splitting character). I use a lot #titleparts as a "string-splitter", and I can manage difficult issues with ease (i.e.: how to pass multiple values into a single parameter of a template) but sometimes I'd like to use a character different from / (i.e. splitting a list of page/subpage names).
Alex
Alex Brollo, 14/12/2010 09:10:
I can't "open a bug" (bugzilla is very confusing for me) and I don't know how to browse old proposals/requests, so I feel better to post here two ideas, just to let you revise them and - if you like - to go on into bugzilla.
- I'd like to have a {{nbsp:string}} function, to replace all spaces
with html entities into string. It would very useful to format table cell content where spaces must be avoided, while saving the original string.
There's a class for this: http://en.wikipedia.org/wiki/Template:Nowrap
- I'd like to generalize {{#titleparts:string}} transforming it into a
general str.split() function something like {{split:string|char}} where string is the string to split, and char is the splitting character). I use a lot #titleparts as a "string-splitter", and I can manage difficult issues with ease (i.e.: how to pass multiple values into a single parameter of a template) but sometimes I'd like to use a character different from / (i.e. splitting a list of page/subpage names).
This should be http://www.mediawiki.org/wiki/Extension:StringFunctions , which will never be implemented in Wikimedia projects.
Nemo
2010/12/14 Federico Leva (Nemo) nemowiki@gmail.com
Alex Brollo, 14/12/2010 09:10:
- I'd like to have a {{nbsp:string}} function, to replace all spaces
with html entities into string. It would very useful to format table cell content where spaces must be avoided, while saving the original string.
There's a class for this: http://en.wikipedia.org/wiki/Template:Nowrap
- I'd like to generalize {{#titleparts:string}} transforming it into a
general str.split() function something like {{split:string|char}} where string is the string to split, and char is the splitting character). I use a lot #titleparts as a "string-splitter", and I can manage difficult issues with ease (i.e.: how to pass multiple values into a single parameter of a template) but sometimes I'd like to use a character different from / (i.e. splitting a list of page/subpage names).
This should be http://www.mediawiki.org/wiki/Extension:StringFunctions , which will never be implemented in Wikimedia projects.
1. Thank you Nemo!! Problem solved. 2. There are lots of string functions already implemented - lc, uc, lcfirs, ucfirst, #titleparts... PAGENAME, FULLPAGENAME, BASEPAGENAME... - today. IMHO a generalized *split* function would be great to extend just a little bit the field of #titleparts to implement an efficient, simple way to manage simple arrays. StringFunctions could fire fantasy - *split* function would only increase efficiency to solve common issues.
Alex
2010/12/14 Alex Brollo alex.brollo@gmail.com
2010/12/14 Federico Leva (Nemo) nemowiki@gmail.com
Alex Brollo, 14/12/2010 09:10:
- I'd like to have a {{nbsp:string}} function, to replace all spaces
with html entities into string. It would very useful to format table cell content where spaces must be avoided, while saving the original string.
There's a class for this: http://en.wikipedia.org/wiki/Template:Nowrap
Nowrap is an excellent idea, I guess is would be extremely useful. Nevertheless the goal was to solve the "dotted lines into index summaries quiz" and I just found an alternative way to obtain what I needed, avoiding nowrap and covering too the case of text longer than a single row into a html box: http://it.wikisource.org/wiki/Wikisource:Pagina_delle_prove#Ancora_puntini
I don't know if such a trick is "original" - it's so hard to discover something new into wiki...;-) - but I know that I'm searching for it from the beginning of my source trip. :-)
wikisource-l@lists.wikimedia.org