6,566
edits
(Anchoring fix - the post anchoring is now at the very end of the URI, and only if 'p' has been supplied and 'anchor' has not.) |
(Added support for a 'u' parameter for specifying a forum user number.) |
||
Line 1: | Line 1: | ||
{{project infrastructure|forum|link=no}}<!-- | {{project infrastructure|forum|link=no}}<!-- | ||
-->{{#if: {{{f|{{{t|{{{p|{{{anchor|{{{hilit|}}}}}}}}}}}}}}} | -->{{#if: {{{u|}}} | ||
| /memberlist.php?mode=viewprofile&u={{{u}}} <!-- URI component required for showing a user --> | |||
| {{#if: {{{f|{{{t|{{{p|{{{anchor|{{{hilit|}}}}}}}}}}}}}}} | |||
| {{#if: {{{t|{{{p|{{{anchor|{{{hilit|}}}}}}}}}}}} | |||
| /viewtopic.php? <!-- Add viewtopic.php if any parameters, excluding 'f', are supplied. --> | |||
| /viewforum.php? <!-- Add viewforum.php if only the 'f' parameter is supplied. --> | |||
}} | |||
}}<!-- | |||
-->{{#if: {{{f|}}} | |||
| f={{{f}}}<!-- | |||
-->{{#if: {{{t|{{{p|{{{hilit|}}}}}}}}} | &}}<!-- Add an ampersand if t, p or hilit are present afterwards. --> | |||
}}<!-- | |||
-->{{#if: {{{t|}}} | |||
| t={{{t}}}<!-- | |||
-->{{#if: {{{p|{{{hilit|}}}}}} | &}}<!-- Add an ampersand if p or hilit are present afterwards --> | |||
}}<!-- | |||
-->{{#if: {{{p|}}} | |||
| p={{{p}}}<!-- | |||
-->{{#if: {{{hilit|}}} | &}}<!-- Add an ampersand if hilit is present afterwards --> | |||
}}<!-- | |||
-->{{#if: {{{hilit|}}} | |||
| hilit={{{hilit}}} | |||
}}<!-- | |||
-->{{#if: {{{anchor|{{{p|}}}}}}<!-- Post anchoring --> | |||
| #{{#if: {{{anchor|}}} | |||
| {{{anchor}}} | |||
| p{{{p}}} | |||
}} | |||
}} | }} | ||
}}<noinclude> | }}<noinclude> | ||
Line 38: | Line 41: | ||
{{!}} ''t'' = | {{!}} ''t'' = | ||
{{!}} ''p'' = | {{!}} ''p'' = | ||
{{!}} ''u'' = | |||
{{!}} ''anchor'' = | {{!}} ''anchor'' = | ||
{{!}} ''hilit'' = | {{!}} ''hilit'' = | ||
Line 47: | Line 51: | ||
; p: Post number to be passed to phpBB's viewtopic.php (optional). | ; p: Post number to be passed to phpBB's viewtopic.php (optional). | ||
; u: User number to be passed to phpBB's memberlist.php (optional). If supplied, the {{param|f}}, {{param|t}}, {{param|p}}, {{param|anchor}}, and {{param|hilit}} parameters will be ignored. | |||
; anchor: HTML anchor, used for jumping to posts (optional). | ; anchor: HTML anchor, used for jumping to posts (optional). | ||
Line 115: | Line 121: | ||
{{forum url|p=111333|hilit=contains+a+problem}} | {{forum url|p=111333|hilit=contains+a+problem}} | ||
=== User === | |||
{{obr}}forum url{{!}}u=2{{cbr}} | |||
{{forum url|u=2}} | |||
== Related templates == | == Related templates == |