On Mon, 2 Sep 2019 at 12:16, s8evq <[email protected]> wrote: > Okay, this project is done. I have made the transclusion on the four pages: > > https://wiki.openstreetmap.org/wiki/Hiking > https://wiki.openstreetmap.org/wiki/Walking_Routes > https://wiki.openstreetmap.org/wiki/Tag:route%3Dhiking > https://wiki.openstreetmap.org/wiki/Tag:route%3Dfoot
Thanks for putting in the effort. A minor issue is perhaps the layout of Tag:route=hiking and Tag:route=foot. > Probably because of the transclusion, the table only start under the > ValueDescription template. This results in quite some white space on the > page. > I'm not sure what bit you mean because, at a quick glance, I don't see a white space problem. I'm probably missing it. So take a look at https://en.wikipedia.org/wiki/Wikipedia:Transclusion at the bit about selective transclusion (which may not apply to what you're doing, I'm not sure) which says: *This selective transclusion method often adds a line break above and/or below the section transclusion, depending upon the source and target document markup; to avoid this issue, wrap the selective transclusion template in a {{trim <https://en.wikipedia.org/wiki/Template:Trim>}} template.* In other words, use the following modifications to the transclusion code listed immediately above: - Code for transcluding a section in the body of an article: {{trim|{{#section-h:PAGENAME|SECTIONNAME}}}} - Code for transcluding the lead of an article: {{trim|{{#section-h:PAGENAME}}}} So whatever you're doing, try wrapping it in a trim and see if that fixes it. It probably won't, and I expect somebody to tell me what an idiot I am for thinking it might. However, what I did spot is that all four pages have route=hiking and route=foot in the relation table. It's somewhat confusing to see an explanation of route=foot in a page about hiking and an explanation of route=hiking in a page about walking. I haven't tried it but I believe this may be fixable. I think the fix involves passing parameters to the template and conditionals within the template. But I may be missing something and it's actually a lot harder, a lot different or both a lot harder and a lot different. So you'll have to read the documentation and experiment (and eventually give up in frustration). I think you can do something like this on the four pages: {{Template:Tagging_scheme_for_hiking_and_foot_route_relations|walking=yes|hiking=no}} and then in your template {{ifeq: {{{walking|yes}}} | <table row about walking tag}} {{ifeq: {{{hiking|yes}}} | <table row about hiking tag}} See https://en.wikipedia.org/wiki/Help:Conditional_expressions for help with conditionals. Try it with ordinary text not in a table first. I may have some of that completely wrong, but eventually you should get it working. And then you have to get it working in an actual table, which is complicated. It's complicated because the table row separator is | and the #ifeq separator is also | and things get confused. How to deal with that is discussed at https://en.wikipedia.org/wiki/Help:Conditional_tables Good luck with understanding that. -- Paul
_______________________________________________ Tagging mailing list [email protected] https://lists.openstreetmap.org/listinfo/tagging
