#8071 closed enhancement (fixed)
mapcss concat() and cond()
Reported by: | Polyglot | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | 14.01 |
Component: | Core | Version: | |
Keywords: | mapcss support | Cc: |
Description (last modified by )
This works:
text: rcn_ref;
or:
text: tag(rcn_ref);
When the name tag is present, this also works:
text: concat(tag(rcn_ref), " ", tag(name));
Without a name tag, no text is shown, though.
So I tried this:
text: name?rcn_ref:concat(tag(rcn_ref), " ", tag(name));
and this:
text: cond(name,rcn_ref,concat(tag(rcn_ref), " ", tag(name)));
Would it be possible to simply add a blank string in concat() if the tag is not available.
That would be the most intuitive.
cond() doesn't work as I would expect it either.
Polyglot
Attachments (0)
Change History (9)
comment:1 Changed 11 years ago by
Description: | modified (diff) |
---|
comment:2 Changed 11 years ago by
Description: | modified (diff) |
---|
comment:3 Changed 11 years ago by
comment:4 Changed 11 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
I found an easier way to solve the problem: using different ::layers to show the different tags instead of trying to concatenate them.
comment:6 Changed 11 years ago by
Oh, I'm sorry. It wasn't clear to me whether it was appropriate to have reported it, since there was no reaction (except a more or less negative one, questioning whether it was supposed to work the way I expected it to work) and I managed to solve my problem in another way.
cond() is fine though.
comment:9 Changed 9 years ago by
Milestone: | → 14.01 |
---|
The following works:
This too:
It would be a lot simpler if empty tags were simply replaced by an empty string though.
Polyglot