Jump to content
This wiki has been automatically closed because there have been no edits or log actions made within the last 60 days. If you are a user (who is not the bureaucrat) that wishes for this wiki to be reopened, please request that at Requests for reopening wikis. If this wiki is not reopened within 6 months it may be deleted. Note: If you are a bureaucrat on this wiki, you can go to Special:ManageWiki and uncheck the "Closed" box to reopen it.

Examples/Parameter: scroll (example 2): Difference between revisions

m
Finish refining this before I move it (it's going to be the second of 2 examples, the first didn't work I think because of caching change, which can be overridden)
imported>FrozenPlum
m (See if disabling cache causes this to work)
imported>FrozenPlum
m (Finish refining this before I move it (it's going to be the second of 2 examples, the first didn't work I think because of caching change, which can be overridden))
Line 6:
==Example==
 
This selects pages from [[:Category:Fruit examples]] and sets thedisplay count to display the first 3 articles. inThe that<code>scroll</code> categoryparameter (usingenables ascrolling and URL variablevariables. insteadThe of<code>resultsheader</code> argument uses a number,helper sotemplate the([[Template:Extension countDPL canscroll]]) beto overwrittencreate asthe needed)scrolling navigation. TheA [[mw:Help:Magic_words#Statistics|magic word]] (<code>scroll<nowiki>{{PAGESINCATEGORY:Category}}</nowiki></code>) parameterand enablessome scrollingparameters throughare thefed categoryto resultthat settemplate, andso alsoit enablescan support fordetermine the usetotal number of URLpages variablesand the amount to changeshow and offset for the DPL3navigation querydisplay. The <code>resultsheaderallowcachedresults=''false''</code> displaysprevents textcaching, thatso givesresult thechanges <code>DPL_count</code>are variableimmediately value,seen andwithout the currentneed {{DPL|offset}}to manually purge the valuecache.
 
Adding <code>&DPL_offset=3</code> to the end of the ([[mw:Manual:Parameters_to_index.php|index.php]]-style) URL seen below, causes the contents of the DPL3 query displayed on-page to change; the next 3 results in the result set are displayed.
 
<code><nowiki>https://dpl3.miraheze.org/w/index.php?title=Criteria_for_page_selection/Parameter:_scroll_(example_1)&DPL_count=10&DPL_offset=3</nowiki></code>
<pre>
{{#dpl:execandexit=geturlargs}}
Line 38 ⟶ 35:
[[Category:Uses category parameter]]
[[Category:Uses count parameter]]
[[Category:Uses offset parameter]]
[[Category:Uses scroll parameter]]
[[Category:Uses resultsheader parameter]]
[[Category:Uses allowcachedresults parameter]]
</noinclude>
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.