<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.drugwiki.net/wen/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Sysop</id>
	<title>Drugwiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://www.drugwiki.net/wen/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Sysop"/>
	<link rel="alternate" type="text/html" href="https://www.drugwiki.net/drugs/Special:Contributions/Sysop"/>
	<updated>2026-09-05T20:51:05Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.44.2</generator>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11298</id>
		<title>MediaWiki:Sidebar</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11298"/>
		<updated>2025-12-14T08:30:53Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
* navigation&lt;br /&gt;
** mainpage|mainpage-description&lt;br /&gt;
** recentchanges-url|recentchanges&lt;br /&gt;
** randompage-url|randompage&lt;br /&gt;
** helppage|help-mediawiki&lt;br /&gt;
** specialpages-url|specialpages&lt;br /&gt;
** [https://edudrugs.org/tor-market/ Drugs on darknet]&lt;br /&gt;
* SEARCH&lt;br /&gt;
* TOOLBOX&lt;br /&gt;
* LANGUAGES&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11297</id>
		<title>MediaWiki:Sidebar</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11297"/>
		<updated>2025-12-14T08:30:13Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
* navigation&lt;br /&gt;
** mainpage|mainpage-description&lt;br /&gt;
** recentchanges-url|recentchanges&lt;br /&gt;
** randompage-url|randompage&lt;br /&gt;
** helppage|help-mediawiki&lt;br /&gt;
** specialpages-url|specialpages&lt;br /&gt;
* SEARCH&lt;br /&gt;
* TOOLBOX&lt;br /&gt;
* LANGUAGES&lt;br /&gt;
** [https://edudrugs.org/tor-market/ Drugs on darknet]&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11296</id>
		<title>MediaWiki:Sidebar</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11296"/>
		<updated>2025-12-14T08:29:53Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
* navigation&lt;br /&gt;
** mainpage|mainpage-description&lt;br /&gt;
** recentchanges-url|recentchanges&lt;br /&gt;
** randompage-url|randompage&lt;br /&gt;
** helppage|help-mediawiki&lt;br /&gt;
** specialpages-url|specialpages&lt;br /&gt;
* SEARCH&lt;br /&gt;
* TOOLBOX&lt;br /&gt;
* LANGUAGES&lt;br /&gt;
[https://edudrugs.org/tor-market/ Tor]&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11295</id>
		<title>MediaWiki:Sidebar</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11295"/>
		<updated>2025-12-14T08:29:27Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
* navigation&lt;br /&gt;
** mainpage|mainpage-description&lt;br /&gt;
** recentchanges-url|recentchanges&lt;br /&gt;
** randompage-url|randompage&lt;br /&gt;
** helppage|help-mediawiki&lt;br /&gt;
** specialpages-url|specialpages&lt;br /&gt;
* SEARCH&lt;br /&gt;
* TOOLBOX&lt;br /&gt;
* LANGUAGES&lt;br /&gt;
* [https://edudrugs.org/tor-market/ Drugs on darknet]&lt;br /&gt;
[https://edudrugs.org/tor-market/ Tor]&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11294</id>
		<title>MediaWiki:Sidebar</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11294"/>
		<updated>2025-12-14T08:28:09Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
* navigation&lt;br /&gt;
** mainpage|mainpage-description&lt;br /&gt;
** recentchanges-url|recentchanges&lt;br /&gt;
** randompage-url|randompage&lt;br /&gt;
** helppage|help-mediawiki&lt;br /&gt;
** specialpages-url|specialpages&lt;br /&gt;
* SEARCH&lt;br /&gt;
* TOOLBOX&lt;br /&gt;
* LANGUAGES&lt;br /&gt;
* [https://edudrugs.org/tor-market/ Drugs on darknet]&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11293</id>
		<title>MediaWiki:Sidebar</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11293"/>
		<updated>2025-12-14T08:27:41Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
* navigation&lt;br /&gt;
** mainpage|mainpage-description&lt;br /&gt;
** recentchanges-url|recentchanges&lt;br /&gt;
** randompage-url|randompage&lt;br /&gt;
** helppage|help-mediawiki&lt;br /&gt;
** specialpages-url|specialpages&lt;br /&gt;
* SEARCH&lt;br /&gt;
* TOOLBOX&lt;br /&gt;
* LANGUAGES&lt;br /&gt;
* [https://edudrugs.org/tor-market/|Drugs on darknet]&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11292</id>
		<title>MediaWiki:Sidebar</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=MediaWiki:Sidebar&amp;diff=11292"/>
		<updated>2025-12-14T08:27:25Z</updated>

		<summary type="html">&lt;p&gt;Sysop: Created page with &amp;quot; * navigation ** mainpage|mainpage-description ** recentchanges-url|recentchanges ** randompage-url|randompage ** helppage|help-mediawiki ** specialpages-url|specialpages * SEARCH * TOOLBOX * LANGUAGES * https://edudrugs.org/tor-market/|Drugs on darknet&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
* navigation&lt;br /&gt;
** mainpage|mainpage-description&lt;br /&gt;
** recentchanges-url|recentchanges&lt;br /&gt;
** randompage-url|randompage&lt;br /&gt;
** helppage|help-mediawiki&lt;br /&gt;
** specialpages-url|specialpages&lt;br /&gt;
* SEARCH&lt;br /&gt;
* TOOLBOX&lt;br /&gt;
* LANGUAGES&lt;br /&gt;
* https://edudrugs.org/tor-market/|Drugs on darknet&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Featured&amp;diff=11291</id>
		<title>Template:Featured</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Featured&amp;diff=11291"/>
		<updated>2025-12-14T08:25:16Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;*[https://edudrugs.org/tor-market/ Darknet and the drugs]&lt;br /&gt;
*[https://darkweb.wtf Verified Darknet Markets]&lt;br /&gt;
*[[Darknet_Markets|Market Guide]]&lt;br /&gt;
*[[#|Why LSD is better than Crack Cocaine]]&lt;br /&gt;
&lt;br /&gt;
== Amanita Muscaria ==&lt;br /&gt;
&lt;br /&gt;
On the rise - shroom from the forrest is re entering the stage.&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Featured&amp;diff=11290</id>
		<title>Template:Featured</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Featured&amp;diff=11290"/>
		<updated>2025-11-30T10:32:09Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;*[https://darkweb.wtf Verified Darknet Markets]&lt;br /&gt;
*[[Darknet_Markets|Market Guide]]&lt;br /&gt;
*[[#|Why LSD is better than Crack Cocaine]]&lt;br /&gt;
&lt;br /&gt;
== Amanita Muscaria ==&lt;br /&gt;
&lt;br /&gt;
On the rise - shroom from the forrest is re entering the stage.&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11289</id>
		<title>Darknet Markets</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11289"/>
		<updated>2025-11-30T10:30:53Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= How do people buy drugs on Darknet =&lt;br /&gt;
&lt;br /&gt;
Using Darknet Markets has come more and more popular in recent years. People buy what they need on these &amp;quot;eBay-like&amp;quot; shopping plattforms. Whether they need legal- or illegal substances - everything is available on these sites. Paying with Bitcoin makes the transaction invisible and using the web browser TOR makes the visit anonymous.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Prerequisites for using Darknet Shopping Markets ==&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin and the browser TOR. You can NOT even visit this type of sites with Chrome or Internet Explorer, so start here.&lt;br /&gt;
&lt;br /&gt;
*Buy some Bitcoin, we recommend &#039;&#039;&#039;LocalCoinSwap&#039;&#039;&#039; available here: https://localcoinswap.com/?rc=965C9547&lt;br /&gt;
*Get TOR browser: https://www.torproject.org/download/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= List of Darknet Markets =&lt;br /&gt;
&lt;br /&gt;
There are International Markets, as well as Country specific. Caution: Be very careful from where you get your links, save the links in a textfile on your computer for next time to protect yourself from getting phished. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== BEST Market right now is Catharsis ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Catharsis Market&#039;&#039;&#039;, more info at https://darkweb.wtf/?catharsis&lt;br /&gt;
&lt;br /&gt;
Safe access shortlink (Open in TOR) catharsis.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
Catharsis is by far the &#039;&#039;&#039;best marketplace currently (December 2025)&#039;&#039;&#039;. Always easy to login, smooth process for registering. Very intuitive design so you automatically understand where to click and how to do. The admin added &#039;&#039;&#039;Dead Drop&#039;&#039;&#039; feature for some months ago which has become very popular in many &#039;&#039;&#039;European&#039;&#039;&#039; countries.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Other live markets ==&lt;br /&gt;
&lt;br /&gt;
=== Dream Market v2 ===&lt;br /&gt;
&lt;br /&gt;
*http://dream2.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market (Busted) ===&lt;br /&gt;
&lt;br /&gt;
This one is worth registering at and keeping an eye on, extremely fast loading and simple. Im talking about Archetyp Market and the link is below, check it out.&lt;br /&gt;
&lt;br /&gt;
Theres also more information about [[Archetyp Market]] available.&lt;br /&gt;
&lt;br /&gt;
=== INCOGNITO MARKET (Exit Scam) ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Read more and learn how to use [[Incognito Market]] in this guide.&lt;br /&gt;
&lt;br /&gt;
The following is a brief discussion about Incognito market, with several very innovative features.&lt;br /&gt;
&lt;br /&gt;
*A clean and friendly user interface that is designed to be easy to navigate.&lt;br /&gt;
*Recon API integration for streamlined vendor applications&lt;br /&gt;
*Fast page load speed (first paint) and user experience with low latency.&lt;br /&gt;
*Authentication designed with security in mind, added secret word concept to prevent security issues caused by lazy password reuse&lt;br /&gt;
*Anonguard, an automated and dynamic DDoS defense that only appears when under attack.&lt;br /&gt;
*Incogbot, our friendly mascot is available for chat over jabber with vendors. Vendors can check/interact with their orders and receive notifications with Incogbot, all the while not losing security with OTR and anti-phishing countermeasures on our jabber bot.&lt;br /&gt;
*Unique featuring system that makes sure featured listings are shown to the buyers most likely to be interested in the item.&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market ===&lt;br /&gt;
&lt;br /&gt;
This one is new, but really unique. We actually expect Archetyp to become the leading darknet Market in very short time. If you look at the user experience and the fast loading, the easy to understand design it will grow fast. The question that remains if the team is experienced enough to handle it? In either case, I indeed encourage you to take a look at this special market.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that Archetyp is Monero (XMR) only market, you need to exchange your Bitcoin into Monero in order to buy - which actually is more secure that btc.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAMMED) Dark0de Reborn ===&lt;br /&gt;
&lt;br /&gt;
A market with alot of vendors and stuff to order. You will find the top rated international vendors on [[Dark0de Market]].&lt;br /&gt;
&lt;br /&gt;
=== (CLOSING DOWN) TORREZ Market ===&lt;br /&gt;
&lt;br /&gt;
Torrez Market is walletless and with a nice clean design. Probably the leading market. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Step-by-step Guide on How to buy and sell [[ToRRez]] Market.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
=== Versus Market ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Monopoly Market ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== (ASEAN) ASAP Market === &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== White House Market ===&lt;br /&gt;
&lt;br /&gt;
White House Market is retiring and closing down the market soon. This was announced 2021-10-01.&lt;br /&gt;
&lt;br /&gt;
The Market remains open some time, how long has not been said but they want to give their users time to settle open trades and withdraw their funds. If you have money on your account login and withdraw.&lt;br /&gt;
&lt;br /&gt;
==== Alternatives to White House Market on the below link ====&lt;br /&gt;
&lt;br /&gt;
*https://darkweb.wtf/?WhiteHouseMarket&lt;br /&gt;
&lt;br /&gt;
Transactions require monero now, starting in 2021. No Bitcoin transactions.&lt;br /&gt;
&lt;br /&gt;
== How to buy stuff on the Darknet ==&lt;br /&gt;
&lt;br /&gt;
Make extra sure that you have entirely read this whole tutorial before diving in – it’s very, very important you fully comprehend each and every step. The following guide is to assist you to buy on the Darknet Markets, the steps explained are the same for all markets - however some details can be different and there are market specific help for beginners available as well.&lt;br /&gt;
&lt;br /&gt;
I strongly (VERY STRONGLY) recommend that you save this link in a plain text file or password app on your own computer, there are alot of phising sites out there that try to provide people with fake links. Be careful and especially if you have alot of Bitcoin. NOTE: ONLY WORKS IN TOR WEB BROWSER - NOT YOUR ORDINARY CHROME OR INTERNET EXPLORER - YOU MUST USE TOR TO ACCESS DARKNET AND .ONION-links.&lt;br /&gt;
&lt;br /&gt;
== Part 1 – Preparing ==&lt;br /&gt;
&#039;&#039;&#039;Install Tor Browser&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
To visit the darkweb, you will need to visit https://www.torproject.org/projects/torbrowser.html and download what is known as the Tor Browser Bundle, for your current OS. There are plenty of detailed instructions for installing it on its download webpage, for OS X, Windows, even Debian, too.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;VPN - Optional step but recommended if you are going to buy frequently or bigger amounts.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
You can find one here to best suit you, we review the best VPN Services for privacy on the market. Every time you use your computer your IP address is shown which reveals your actual physical address which means you can be traced very easily. A VPN must be used along with Tor (Tor is the free browser explained below) to make your online activity anonymous. When using a VPN Service it will hide your identity and location while also encrypting all of you internet traffic from everyone including your internet service provider. This technology will also protect you from identity theft and hacking when using free wifi because everything is encrypted. Any time you are searching for music, movies to download, pirated content, drugs or anything illegal then you should be using a VPN to fly under the radar. The law is trying to monitor everything we do now so don’t make it easy for them, don’t end up like the original mastermind of Silk Road and get busted. This is a must have in your anonymous arsenal.&lt;br /&gt;
&lt;br /&gt;
Your first-ever step in buying something via any marketplace whatsoever, is properly setting-up your digital environment. Following below is a bare standard minimum in order to stay safe when buying personal items. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;PGP - Optional step but strongly recommended. It&#039;s ok to make a first time purchase on Dream Market to try it out before you set this up since it has a small learning curve.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
PGP is an especially useful method of encrypting/decrypting sensitive messages. It’s not very good of an idea to tell a vendor, your home address without first encrypting it, because should the hidden service get seized, LE will have clearly-cut evidence of the crime you have committed. One thought to bear in mind is that not all versions of GPG are created equally, so avoid using GPG methods such as iGolder or those utilizing the BouncyCastle libraries.&lt;br /&gt;
&lt;br /&gt;
This site has long had essential, fundamental guides covering GPG for each and every mainstream OS, Linux, OS X, and then Windows. Linux is the best choice, obviously; however, you will be fine ordering personal goods on either OS X and Windows.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Get some Bitcoins&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Bitcoins2.jpg|200px]]&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin in order to pay, Bitcoins are anonymous and that is the main reason and it is also very hard to trace transactions from one part to another, and even if someone does it is hard to know who is the owner of the Bitcoin address.&lt;br /&gt;
&lt;br /&gt;
So you need to BUY some Bitcoins and the best way is to use AgoraDesk, where you buy from users that want to sell some of their. Some of them will require your ID, a photo of your passport or similiar (Are you just ordering small amounts and occasionally this could be ok) but there are also vendors that can meet up with you and you buy the Bitcoins face-to-face paying in cash.&lt;br /&gt;
&lt;br /&gt;
There are other ways getting Bitcoins of course and whichever way you buy Bitcoin is completely up to your own preference. Regardless, AgoraDesk is one of the most widely-popular options for a reason: it can be done anonymously. There’ve also been reports of Coinbase taking ban action against accounts involved in Darkweb Market deposits, so avoid that if you’re able. No need to use Tor while buying Bitcoins, because it is totally legal and buying through Tor often becomes a cumbersome ordeal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Wallet&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Now that you’ve purchased some Bitcoins, you need to store them somewhere. A particularly great choice is the open-source Electrum Wallet. This is also cross-platform and has a downloadable version for Android phones. Go ahead, download it here. https://electrum.org/download.html Using the Electrum Wallet is quite easily accomplished.&lt;br /&gt;
&lt;br /&gt;
== Part 2 – Some beginning tips ==&lt;br /&gt;
&lt;br /&gt;
Some beginning tips for new users are laid out, here – some are from personal experiences and others from stories across the web:&lt;br /&gt;
&lt;br /&gt;
Remember to use your birth name and real address, as nothing more than a fake name/address draws such negative attention to mail carriers. They are usually fairly familiar with residents of which houses on any block to which they deliver mail regularly and are obligated to report suspicious packages. You can actually get a P.O. Box for a small enough sum of cash, if you live with people who tend to dig through your snail mail.&lt;br /&gt;
&lt;br /&gt;
If you do end up deciding to use a faux name, ensure you’ve got real-looking document forgeries to back that up, should confrontation occur. Fake identification, plus utility-bill scans are mostly sufficient to open up a P.O. box under said faux name.Be patient when you can, majority of the time. Dream Market isn’t Amazon or anything like that – things do often suffer through unexpected delays; vendors usually mark ordered items as shipped immediately, even though they only ship the day after that. &lt;br /&gt;
&lt;br /&gt;
Weather and holidays can also significantly delay proper shipping timeframes. The only time you should rebutt an order’s shipment after not arriving, is after you have waited at least 14 days, or even when Auto-finalize is about to be activated. There will be more covered on this, later.&lt;br /&gt;
&lt;br /&gt;
Encrypt basically everything, messages and all, which you send. These few several minutes are worth losing out on a long-term incarceration.&lt;br /&gt;
&lt;br /&gt;
Should there be any negative experience with a vendor, try to message them, prior to giving a bad review. Chances are that the vendor will go to extreme lengths to make sure you get what you need, and have it all sorted sufficiently. Be as kind and polite as you can; it will move you farther in the process of getting stuff done.&lt;br /&gt;
&lt;br /&gt;
No one should ever know you make purchases on DNMs. This includes not telling your friends or even your blood relatives.&lt;br /&gt;
&lt;br /&gt;
Laundering the coins with which you pay, using something such as Bitcoin Fog or Grams’s Helix is a necessary thing to do, but that is your choice. If you buy personal items, this isn’t required, life or death, and as a result, it won’t be covered in this tutorial.&lt;br /&gt;
&lt;br /&gt;
Anything in the market that looks too CHEAP to be true, is, in all probability, a scam.&lt;br /&gt;
&lt;br /&gt;
Never ever, ever Finalize-Early, even with trusted vendors as they, too, sometimes eventually exit-scam.&lt;br /&gt;
If and when you are able to, ship domestically as much as possible (from within your own country).&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Anonymous email address&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
this could be important when and if the need to communicate with anyone arises, using a Gmail or Hotmail address is bound to not be of very good privacy. Instead, sign up for a free ProtonMail address. Link: https://protonmail.com&lt;br /&gt;
&lt;br /&gt;
== Part 3 – Getting used ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FE vs No-FE&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
FE (finalize-early) is a procedure by which the vendor can retrieve the payment from any sale without waiting for the escrow, which is designed to make sure you do receive your product, to release funds. It’s quite discouraged in this industry, due to the obvious risks involved. Will you encounter a scam on an FE listing, your funds are undoubtedly not recoverable&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Buying from within your own country&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Depending on how much risk you are willing to undergo, and how long you are willing to wait to truly receive your shipped order, you can choose a specific “Shipping From” location during the search process. Ordering from “hot” nations, for instance, such as Pakistan, the Netherlands, and even Colombia are much riskier due to known trade practices in those places.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Judging the Vendor&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Each vendor has his or her PGP key listed as well as the feedback they have received thus far. Just remember, a vendor having mostly positive reviews doesn’t make them bulletproof.&lt;br /&gt;
&lt;br /&gt;
Another great way to get a general feel of a vendor’s reliability is to read reviews of them on the marketplace boards. this site’s listing, and/or the usual Subreddit, DarkNetMarkets. You can also the candidate vendor’s reviews on Grams.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Give feedback&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
If you are satisfied, please remember to leave positive feedback. The most vital component of the darkweb marketplace system is its ratings.&lt;br /&gt;
&lt;br /&gt;
== Old &amp;amp; Closed Markets ==&lt;br /&gt;
&lt;br /&gt;
Below markets does not exist anymore. The reason is different for each of them, Exit Scam being one of the most common reasons but once in a while a markets also gets busted and seized. In some rare occassions the market admins decides to retire in a honorable way. Dream Market one good example on how to retire with honor. &lt;br /&gt;
&lt;br /&gt;
=== (SCAM) Corona Market ===&lt;br /&gt;
&lt;br /&gt;
The admin closed the market place, no further info given. Probably Exit scam.&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Dark Market ===&lt;br /&gt;
&lt;br /&gt;
*THIS MARKET HAS BEEN SEIZED BY GERMAN POLICE&lt;br /&gt;
&lt;br /&gt;
=== (DOWN) Empire Market ===&lt;br /&gt;
&lt;br /&gt;
[[Empire Market]] is the oldest and probably the most reliable, or was until the 22 august 2020. That was when someone started to massively attack the site with DDoS-attacks and everybody is awaiting to see if they manage to get the site back upp and again. Please be careful with links you find, they can be phishing links.. always get the latest links from https://darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
Empire launched in January 2018 shortly after AlphaBay&#039;s demise and grew to 1.3 million users. A staff member estimates under condition of anonymity that the admins profited 2,638 BTC, $30 million USD.&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Deepsea Market === &lt;br /&gt;
&lt;br /&gt;
=== (OUT OF BUSINESS) BitBazaar ===&lt;br /&gt;
&lt;br /&gt;
BitBazaar is a relatively new darkweb market that supports a significant number of cryptocurrencies, features one of the highest referral commission rates, allows purchases without user accounts, and has an ebay-style auction system.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAM) Pax Romana ===&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Agartha ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Samsara Market ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Cryptonia ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Nightmare Market ===&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Exit Scam - Alert july 2019, Do not use!&#039;&#039;&#039;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=ToRRez&amp;diff=11288</id>
		<title>ToRRez</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=ToRRez&amp;diff=11288"/>
		<updated>2025-11-30T10:29:48Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
== ATTENTION ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;TORREZ MARKET IS RETIRING, THIS WAS ANNOUNCED ON THE 17 DECEMBER OF 2021. THE SITE WILL REMAIN OPEN FOR SOME WEEKS TO COME SO USERS AND VENDORS CAN SETTLE OPEN TRADES AND WITHDRAW ANY REMAINING FUNDS.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Most vendors has annnounced that they have opened up accounts on the following markets.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
=== Best Torrez Market alternatives 2026 ===&lt;br /&gt;
&lt;br /&gt;
*Take a look on more alternatives here if you wish: https://darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= About Torrez Market =&lt;br /&gt;
[[File:HomeTorrez1.png|200px|thumb|right|Drugs on Torrez Market]]&lt;br /&gt;
&#039;&#039;Torrez Market&#039;&#039; is one the leading darknet markets accessible by using a ONION-browser like TOR. On Torrez you can buy and sell pretty much anything and one of the main product categories are drugs and medicine that in most countries are against the law to buy or sell or possess. You can get any substance you like.. cocaine, speed, hash, ecstasy, lsd you name it.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Theres more than 30 000 products up for sale, (may 2021) and over thousand different vendors announcing their goods. Over 200 000 people are registered as buyers. And increasing every day.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Most listings are drugs. Have you never checked out the darknet? Now is the time.&lt;br /&gt;
&lt;br /&gt;
== How to access Torrez Market ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;If you already know how to access the darknet, then use the below URL or any mirror below to navigate to Torrez and create your account.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== First time on Darknet? ===&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;If you have not before accessed the darknet, then you need to prepare a few things.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
First, download TOR from here and install it: https://www.torproject.org/download/ This goes for desktop computers, if you are on a phone then you need Orbot for Android phones or any Onion browser for iPhone (you can search for Onion browser in AppStore)&lt;br /&gt;
&lt;br /&gt;
*Link to Orbot: https://play.google.com/store/apps/details?id=org.torproject.torbrowser&lt;br /&gt;
*Link to Onion browser for iPhone: https://apps.apple.com/se/app/onion-browser/id519296448&lt;br /&gt;
&lt;br /&gt;
== ONION URLs to Torrez Market ==&lt;br /&gt;
&lt;br /&gt;
Mirrors are alternative URLs that go the same site. These are all from Torrez Mirror list, if the one you have does not work, then try one of the below. And be extremely careful from where you get your darknet links, many sites are putting up false links and trying to trick you to send Bitcoin to a wallet they manage. It is called Phishing. One safe resource is https://darkweb.wtf - and Torrez is listed here too: https://darkweb.wtf/?ToRReZ&lt;br /&gt;
&lt;br /&gt;
== (BEGINNERS GUIDE) First step to start using Torrez ==&lt;br /&gt;
&lt;br /&gt;
So the .Onion url you need is below, and it includes an invite code (E1Gg). You can also enter the code manually in the next steps. Usually the first works good, if not pick another one from above list.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass the captcha&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Almost all darknet sites uses some sort of captcha to make sure you are a human visitor. Get used to it, it can be frustrating sometimes but the Torrez captcha is pretty easy. Just enter the five biggest and most visible characters, if you dont make it the first time, try a few more times and you will get it right.&lt;br /&gt;
&lt;br /&gt;
Sometimes the market can be under heavy load so occasionally you might see a broken screen or have to wait a minute. If more than a minute passes without nothing then reload the page or go back and try again. The message &amp;quot;Please wait, you will be automatically redirected&amp;quot; is normally shown and usually it takes about 5 seconds to load.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Torrez-market-captcha.png|200px]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Chose your username and password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
And also enter a PIN code. It can be any 4 numbers you like. If you start purchasing later on you might need it. Save all the details in a textfile or note it down on your computer or phone (or piece of paper if you like it old school).&lt;br /&gt;
&lt;br /&gt;
Also enter the Invite code, which is &amp;quot;E1Gg&amp;quot; and once again pass the captcha, click Submit.&lt;br /&gt;
&lt;br /&gt;
[[File:RegTorrez1.png|300px]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Mnemonic&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Next step is a combination of words, this is to restore your account if you for example forget your password. Copy the words, paste them in the field below and save them in your textfile together with your username, PIN and password. Also keep the adress to Torrez there so you dont need to Google for it.&lt;br /&gt;
&lt;br /&gt;
[[File:Mnemomic.png|200px]]&lt;br /&gt;
&lt;br /&gt;
==== Enter Torrez ====&lt;br /&gt;
&lt;br /&gt;
You should now be back on the login screen, and able to enter your login details together with the captcha.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:LoginTorrez.png|300px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Some news should be displayed as below&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Newstorrez.png|200px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Clicking &amp;quot;ok&amp;quot; will take you to the home of Torrez and all the categories and cool stuff to buy is on the left side. Check out your favourite!&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:HomeTorrez1.png|300px]]&lt;br /&gt;
&lt;br /&gt;
==== Step by step guide for buying on Torrez Market ====&lt;br /&gt;
&lt;br /&gt;
You can pay in a few diffferent ways but it is always with cryptocoin like Bitcoin or Monero. Torrez also accepts Litecoin and ZCash. Most common is Bitcoin, for the casual buyer it is safe enough and easy to get hold of some. Monero is safest since it leaves less traces. You can also pay from a wallet on Torrez, to which you can send Coins and the payment is reserved from the balance or you can send directly when making the purchase.&lt;br /&gt;
&lt;br /&gt;
==== Buying coke from Torrez ====&lt;br /&gt;
&lt;br /&gt;
For this example purchase we gonna order cocaine. Browse Stimulants from the category view and chose Cocaine.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Coketorrez.png|300px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The Fishscale from Germany looks interesting, the vendor has a great history. Lets buy some gram for the weeknd&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Fishtorreztestbuy1.png|300px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Clicking Place order takes me to the screen where I need to enter my adress, advanced users always encrypt the adress manually but for this first time we make it easy. Write your adress and any message to the seller.&lt;br /&gt;
&lt;br /&gt;
[[File:Buyadresstorrez.png|200px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next choose the currency you want to pay in, click it so it gets a dark border. We chose Bitcoin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Walletlessbuy.png|200px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next check and review your order, and click next&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Revieworder.png|200px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And instructions for paying&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Revieworder.png|300px]]&lt;br /&gt;
&lt;br /&gt;
==== Paying ====&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin now, to pay the order. If you already have that - great. If not you will need to buy some. To buy some Bitcoin easily and pretty safe go to below URL in your &#039;&#039;ordinary browser&#039;&#039; - no need to use TOR here.&lt;br /&gt;
&lt;br /&gt;
*https://changelly.com/?from=btc&amp;amp;to=xmr&amp;amp;amount=0.005&amp;amp;ref_id=pFNEnraG8SVy9f7E&lt;br /&gt;
&lt;br /&gt;
Register an account, you can use your real mail and name here. It is not illegal to buy Bitcoin. And you might have to verify who you are also by taking a pic of your ID or Passport. Dont worry, no one will connect you with the purchase on darknet and we will add a step for more safety also.&lt;br /&gt;
&lt;br /&gt;
*Download and install Electrum: https://electrum.org/#download&lt;br /&gt;
&lt;br /&gt;
Electrum is a Bitcoin wallet for Mac, Windows, Android and Linux. iPhone users head to app store and download Coinomi or another Bitcoin wallet for your iPhone. This wallet is to have a step between the purchase of Bitcoin and transaction on Torrez, It is not recommended to send directly from a legit site to the darknet, chances are that the coins will get freezed. With a own wallet in between you are safe.&lt;br /&gt;
&lt;br /&gt;
Buy and pay the amount of Bitcoin you need any ad you find suitable. Different countries can have different ways of paying, you want your Bitcoin more or less immediately so chose a fast method rather than Bank transfer.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== (GUIDE FOR SELLING) Torrez Market ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Create vendor account&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Always up-to-date info on Torrez Market available here with working links (Trusted site) [https://darkweb.wtf/?ToRReZ Torrez Market]&lt;br /&gt;
&lt;br /&gt;
To be able to sell on the market, please create vendor account. If you are verified and well established vendor, please open support ticket and ask for a bond waiver. Make sure to have your PGP key already attached to the account, otherwise administration will not be able to perform verification.&lt;br /&gt;
&lt;br /&gt;
If you are just starting or have no history yet, please choose vendor account type and make a purchase.&lt;br /&gt;
&lt;br /&gt;
Regular - The Vendor bond is $250.00, and there is no listing limit. The fee for every order is between 4%-5%.&lt;br /&gt;
&lt;br /&gt;
Once you pay, or get vendor account from administration, you will have an access to vendor&#039;s links in the sidebar panel, just under the categories tree.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Prepare your vendor account&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Before you start selling, there are few things that needs to be done on your vendor account. Please choose Vendor Dashboard link from the menu and go to Settings tab and set:&lt;br /&gt;
&lt;br /&gt;
Refund Policies - you can predefine as much refund policies as you want and use them while creating a listing.&lt;br /&gt;
Shipping Options - you can predefine as much refund shipping options as you want.&lt;br /&gt;
It will be necessary only if you sell physical items.&lt;br /&gt;
Shipping to - please select to which continent or country you will ship your items.&lt;br /&gt;
Name - give your shipping option some clear and understandable name, as this is what buyer sees while making purchase.&lt;br /&gt;
Maximum Quantity - how many items do you allow in one package.&lt;br /&gt;
Price in USD - set your shipping price in USD.&lt;br /&gt;
Price for any other - if you allow more than one item in the package, please specify how much do you want to charge for any extra item. You can also set this amount to 0 if you do not want to charge anything for extra items in the package.&lt;br /&gt;
Min &amp;amp; max delivery time - please specify in how many days (minimum and maximum) your package should arrive to the buyer.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Decide which currencies you want to support&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
After initial setting of you vendor account, it is time to decide what currencies do you want to support. You can choose between BTC, XMR, LTC and ZEC. All of them have to be set in Vendor Tools - Settings - Cryptocurrency settings. Please keep in mind that if you set your details here, you can still choose what payment types you want to support, for each item while creating the listing. You are not tied to those settings but you will not be able to enable payment option if you do not set the details in that section first.&lt;br /&gt;
&lt;br /&gt;
BTC and LTC - we accept Extended Public Keys only. It can be xpub, ypub or zpub, depending on your wallet and needs.&lt;br /&gt;
Zcash - we accept Extended Public Key (xpub) or z-address. We recommend using z-addresses for better privacy.&lt;br /&gt;
Monero - we accept any Monero address, except integrated one.&lt;br /&gt;
&lt;br /&gt;
You also are required to set in how many blocks you want your payout transaction to be processed. You can choose between 1 and 100 blocks. Higher block amount means lower transaction fee but slower transaction. Our default value is 10 blocks for every supported coin.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;What are Extended Public Keys and how to get them&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Extended Public Key is a master public key from your wallet. The market uses it to create unique address for each order. Please keep in mind that Public Key is different from Private Key. Public Key will not allow the market to access the funds, never.&lt;br /&gt;
&lt;br /&gt;
We strongly recommend to create separate wallets for market usage. You should never mix your private coins with the coins you have get from your sales. Always make sure to mix or break the chain with your Bitcoins.&lt;br /&gt;
&lt;br /&gt;
We recommend using Electrum wallet, which is already integrated in Tails or Whonix. Using the market with Electrum wallet is simple and easy. For Bitcoin and Litecoin, just open up your Electrum wallet, go to Wallet menu and click Information. You will get your Extended Public Key from the opened window. Just copy it and fill in your settings.&lt;br /&gt;
&lt;br /&gt;
For Monero, just use any address you wish, except integrated one. There is no need to rotate your address in your settings, as Monero is fully private coin but feel free to update your address from time to time, just to be on the safe side.&lt;br /&gt;
&lt;br /&gt;
Zcash is a bit trickier to use when it comes to obtaining Extended Public Key. We recommend receiving Zcash into your z-address, which makes it untraceable. You can also get an Extended Public Key for ZEC, from hardware devices like Ledger or Trezor.&lt;br /&gt;
Going on vacation? Set Away Mode.&lt;br /&gt;
&lt;br /&gt;
In Vendor Tools - Settings you have an option to set the Away Mode. Before you will be able to set it, you have to clear pending orders, if there are any outstanding ones. Once you set the away mode, just choose the date and you can also choose away message, which will show on every item you have listed.&lt;br /&gt;
&lt;br /&gt;
When your account is in Away Mode, your listings are pushed down to the bottom of the list and are properly marked. Buyers can still go through your offers but cannot purchase them, until your account will be back from the Away Mode.&lt;br /&gt;
&lt;br /&gt;
=== Add your first product ===&lt;br /&gt;
&lt;br /&gt;
If your account is all set, it is time to create the listing. You can choose the option Create Listing from the sidebar or Sell Item from Vendor Dashboard.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Basic information&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*Title - give your item proper title, so people will know what is being sold. Do not use any tricks, and words that does not fit your item description.&lt;br /&gt;
*Subtitle - you can give your item subtitle in here, just put some brief description for example or any other information you find important.&lt;br /&gt;
*Category - please choose proper category for your item. Keep in mind that if you do not know to which subcategory link your item, just use the parent category.&lt;br /&gt;
*Ships From - select from which country or continent do you ship your item. You can leave it blank for both physical or digital items. If you leave it blank, your item will not show up if buyer is looking for an item using Shipping From option as a filter.&lt;br /&gt;
*Description - please describe your item properly. We do not allow to use any html/bb tags so please do not use them as they will not be displayed. Make sure to not to spam your description with keywords that does not match the item you sell. This might be considered as a spam offer and can be blocked by moderators.&lt;br /&gt;
*Refunds Policy - if you have predefined Refund Policy in previous step, now it is the time to select it. You can also click the button Provide custom policy - and make custom one, for each item.&lt;br /&gt;
*Type - please choose either you want to sell a physical or the digital item. If you choose the digital one, you will be asked to provide it&#039;s details in later stage.&lt;br /&gt;
*Price in USD - because of the crypto price fluctuations, we take the price in USD so the price in chosen crypto will be properly adjusted to match your required USD price.&lt;br /&gt;
*Payment Options - this is where you decide which payment options do you want to make available for the buyers. You can easily choose between Simple Escrow mode or Multisignature Escrow. It is just the matter of checking the checkbox, there is no other action needed.&lt;br /&gt;
&lt;br /&gt;
=== Finalize Early ===&lt;br /&gt;
&lt;br /&gt;
If you have a Finalize Early enabled on your account, you can choose if you want to enable it for every listing, separately. You can choose between disabling, enabling optional FE or required FE depending on the type of Finalize Early you have.&lt;br /&gt;
Details&lt;br /&gt;
&lt;br /&gt;
If you sell physical item, here you have to choose which shipping options you want to assign to the item. Also please specify the quantity. You can type 0 if you have unlimited amount of items.&lt;br /&gt;
&lt;br /&gt;
If you sell digital item, here you have to choose what kind of auto delivery you want to enable for your item:&lt;br /&gt;
&lt;br /&gt;
Disabled - item will not be auto delivered. You have to manually provide item&#039;s content, after your order is paid.&lt;br /&gt;
Every customer should get same item - item will be auto delivered. You have to manually provide item&#039;s content in Purchase Message. You are also required to specify how many items you want to sell.&lt;br /&gt;
Every customer should get own, unique item - item will be auto delivered, randomly chosen from the items you have to manually provide in later steps.&lt;br /&gt;
&lt;br /&gt;
If you choose &amp;quot;Every customer should get own, unique item&amp;quot; - we will provide you the text area where you have to put your digital item entries. Keep in mind that one line in this field equals to the one item. You are limited to 255 characters per one line and you can add up to 1000 items at the same time here. If you want to top up your items, you can do that later on, while your listing is already active.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Discounts&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Here you can define discounts if you sell certain kind of an item. You have to provide minimum and maximum amount of items and the discount (in percentage) that applies to that range.&lt;br /&gt;
&lt;br /&gt;
If you are eligible to create Finalize Early listings, you can define the discount for the buyer if he decides to use Finalize Early option on his purchase.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Purchase message&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
If you sell physical item, here you can set some message which will be displayed to the buyer, straight after payment confirmation. On the screen you can see the variables which can be used within purchase message.&lt;br /&gt;
&lt;br /&gt;
If you sell physical item, here you can set some message which will be displayed to the buyer, straight after his payment will confirm. On the screen you can see the variables which can be used within purchase message. If you sell digital item with disabled auto delivery, this message has the same role as described above.&lt;br /&gt;
&lt;br /&gt;
If you sell digital item with &amp;quot;Every customer should get same item&amp;quot; - you should specify the item location in your Purchase Message, for example if you sell some tutorial - provide the link to download etc.&lt;br /&gt;
&lt;br /&gt;
If you sell digital item with &amp;quot;Every customer should get own, unique item&amp;quot; - we have prepared example message to the customer. The most important is [item-data] variable, which will randomly choose the item from Auto Delivery Entries you have set in previous stage.&lt;br /&gt;
&lt;br /&gt;
Please keep in mind that for auto delivered items, Purchase Message is the first and the only message buyer receives automatically, after purchase is confirmed. Please make sure to provide all necessary information in it, so you do not have to process those orders manually.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pictures&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
You can attach up to five pictures per one item. After you attach them, you can delete or mark as a primary whatever picture you choose. We accept pictures up to 2MB size and we will remove all exif data for you, in case you forget to do that.&lt;br /&gt;
Review&lt;br /&gt;
&lt;br /&gt;
Here you can review all the details of your listing, before you decide to publish it. For your convenience, you can move between all the parts of the listing process with no feat of loosing any saved data. You can also start over with the clear forms, by clicking appropriate button.&lt;br /&gt;
&lt;br /&gt;
If your item is ready, just click Publish Listing button. In case there is anything missing, the system will forward you to the subpage with missing stuff.&lt;br /&gt;
&lt;br /&gt;
==== Managing your orders and items ====&lt;br /&gt;
&lt;br /&gt;
Whenever you have an order to process, the system will notify you with little badge with the number of orders to process. The counter badge will be visible next to the Vendor Dashboard link on your sidebar or on Order&#039;s tab after you go to the Vendor Dashboard Section.&lt;br /&gt;
&lt;br /&gt;
All orders are displayed on the list and you can clearly see which ones requires what action. You can check those by looking at Status field. To interact with the order, just click on the item&#039;s name and you will be redirected to the order page with all necessary information and steps you have to take (if any) .&lt;br /&gt;
&lt;br /&gt;
To manage your existing listings, just go to the Items tab. You will also be informed there, how many listing you currently own. You will see the full breakdown of your items, including data like item status, how many of items you sold already and how much items you have left. Every item can be individually controlled, here are possible actions:&lt;br /&gt;
&lt;br /&gt;
*Pause / Activate listing - here you can stop displaying your item for unlimited time or enable already stopped item.&lt;br /&gt;
*Delete listing - rather self explanatory. Keep in mind that you cannot retrieve your deleted item!&lt;br /&gt;
*Duplicate listing - this options forwards you to create the new item with all the details pre filled from the chosen listing.&lt;br /&gt;
*Edit listing - this options lets you update the listing details, like description, title etc.&lt;br /&gt;
*Add quantity - this operation is only available to physical items and lets you increase the quantity of currently sold item.&lt;br /&gt;
*Add auto delivery items - this operation is only available to unique digital items. You can add more auto delivery entries in here.&lt;br /&gt;
*Edit pictures - this option allow you to add and remove images attached to item listing.&lt;br /&gt;
&lt;br /&gt;
Because sometimes we use icons, especially for managing items, it is good to hover the mouse on them for a second to read the icon description.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Releasing funds from Multisignature Escrow&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
When you get paid using Multisignature Escrow, you need to complete few simple steps to sign the transaction and release the funds:&lt;br /&gt;
&lt;br /&gt;
*Just go to your order page and you will see payout address and transaction hex.&lt;br /&gt;
*To sign the transaction we recommend to use coinb.in site. Attention: it requires javascript to work, as all operations are done locally, on user&#039;s computer so it is safe to use it. We still recommend to download coinb.in site to your local computer.&lt;br /&gt;
*Go to the Sign tab, on the very top of the page.&lt;br /&gt;
*Please copy transaction hex from the market and paste it on the site, in the large text field (under the private key input field).&lt;br /&gt;
*To get your private key, open your Electrum wallet.&lt;br /&gt;
*Go to the Addresses tab and find your payout address, which you can take from the order page. Use ctrl+f to use search option.&lt;br /&gt;
*Click with the right mouse button on the address, and chose Private key from the menu.&lt;br /&gt;
*Copy only the value after colon, so if you see something like p2wpkh:L2Zxxx... then start copying from letter L. You can leave your Electrum open, you will need it soon.&lt;br /&gt;
*Now paste the private key to the coinb.in site, just above the transaction hex which you copied earlier.&lt;br /&gt;
*Submit and wait for the signed transaction output, how long you wait depends on the speed of your computer but it should happen in seconds.&lt;br /&gt;
*Copy the signed transaction which will appear on the screen.&lt;br /&gt;
*Go back to Electrum wallet, choose Tools - Load Transaction - From text, from the top menu.&lt;br /&gt;
*Paste the signed transaction and click Load Transaction.&lt;br /&gt;
*Now only thing you have to do is to broadcast the transaction and your payout is completed.&lt;br /&gt;
&lt;br /&gt;
The above process applies to Bitcoin and Litecoin, considering that you use Electrum wallet. If you want to broadcast transaction from the different wallet, you will need to import your redeem script into it. Redeem script is visible on order summary: Multisignature redeem script.&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11287</id>
		<title>Darknet Markets</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11287"/>
		<updated>2025-11-30T10:29:28Z</updated>

		<summary type="html">&lt;p&gt;Sysop: /* Archetyp Market */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= How do people buy drugs on Darknet =&lt;br /&gt;
&lt;br /&gt;
Using Darknet Markets has come more and more popular in recent years. People buy what they need on these &amp;quot;eBay-like&amp;quot; shopping plattforms. Whether they need legal- or illegal substances - everything is available on these sites. Paying with Bitcoin makes the transaction invisible and using the web browser TOR makes the visit anonymous.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Prerequisites for using Darknet Shopping Markets ==&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin and the browser TOR. You can NOT even visit this type of sites with Chrome or Internet Explorer, so start here.&lt;br /&gt;
&lt;br /&gt;
*Buy some Bitcoin, we recommend &#039;&#039;&#039;LocalCoinSwap&#039;&#039;&#039; available here: https://localcoinswap.com/?rc=965C9547&lt;br /&gt;
*Get TOR browser: https://www.torproject.org/download/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= List of Darknet Markets =&lt;br /&gt;
&lt;br /&gt;
There are International Markets, as well as Country specific. Caution: Be very careful from where you get your links, save the links in a textfile on your computer for next time to protect yourself from getting phished. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== BEST Market right now is Catharsis ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Catharsis Market&#039;&#039;&#039;, more info at https://darkweb.wtf/?catharsis&lt;br /&gt;
&lt;br /&gt;
Safe access shortlink (Open in TOR) catharsis.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
Catharsis is by far the &#039;&#039;&#039;best marketplace currently (December 2025)&#039;&#039;&#039;. Always easy to login, smooth process for registering. Very intuitive design so you automatically understand where to click and how to do. The admin added &#039;&#039;&#039;Dead Drop&#039;&#039;&#039; feature for some months ago which has become very popular in many &#039;&#039;&#039;European&#039;&#039;&#039; countries.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Other live markets ==&lt;br /&gt;
&lt;br /&gt;
=== Dream Market v2 ===&lt;br /&gt;
&lt;br /&gt;
*http://dream2.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market (Busted) ===&lt;br /&gt;
&lt;br /&gt;
This one is worth registering at and keeping an eye on, extremely fast loading and simple. Im talking about Archetyp Market and the link is below, check it out.&lt;br /&gt;
&lt;br /&gt;
Theres also more information about [[Archetyp Market]] available.&lt;br /&gt;
&lt;br /&gt;
=== INCOGNITO MARKET (Exit Scam) ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Read more and learn how to use [[Incognito Market]] in this guide.&lt;br /&gt;
&lt;br /&gt;
The following is a brief discussion about Incognito market, with several very innovative features.&lt;br /&gt;
&lt;br /&gt;
*A clean and friendly user interface that is designed to be easy to navigate.&lt;br /&gt;
*Recon API integration for streamlined vendor applications&lt;br /&gt;
*Fast page load speed (first paint) and user experience with low latency.&lt;br /&gt;
*Authentication designed with security in mind, added secret word concept to prevent security issues caused by lazy password reuse&lt;br /&gt;
*Anonguard, an automated and dynamic DDoS defense that only appears when under attack.&lt;br /&gt;
*Incogbot, our friendly mascot is available for chat over jabber with vendors. Vendors can check/interact with their orders and receive notifications with Incogbot, all the while not losing security with OTR and anti-phishing countermeasures on our jabber bot.&lt;br /&gt;
*Unique featuring system that makes sure featured listings are shown to the buyers most likely to be interested in the item.&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market ===&lt;br /&gt;
&lt;br /&gt;
This one is new, but really unique. We actually expect Archetyp to become the leading darknet Market in very short time. If you look at the user experience and the fast loading, the easy to understand design it will grow fast. The question that remains if the team is experienced enough to handle it? In either case, I indeed encourage you to take a look at this special market.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that Archetyp is Monero (XMR) only market, you need to exchange your Bitcoin into Monero in order to buy - which actually is more secure that btc.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAMMED) Dark0de Reborn ===&lt;br /&gt;
&lt;br /&gt;
A market with alot of vendors and stuff to order. You will find the top rated international vendors on [[Dark0de Market]].&lt;br /&gt;
&lt;br /&gt;
=== (CLOSING DOWN) TORREZ Market ===&lt;br /&gt;
&lt;br /&gt;
Torrez Market is walletless and with a nice clean design. Probably the leading market. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Step-by-step Guide on How to buy and sell [[ToRRez]] Market.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
=== Versus Market ===&lt;br /&gt;
*pqqmr3p3tppwqvvapi6fa7jowrehgd36ct6lzr26qqormaqvh6gt4jyd.onion&lt;br /&gt;
&lt;br /&gt;
=== Monopoly Market ===&lt;br /&gt;
*monopolyberbucxu.onion&lt;br /&gt;
&lt;br /&gt;
=== (ASEAN) ASAP Market === &lt;br /&gt;
*http://aseanm2r6znqjuackec6j7yiauyq4fcvghmskixd4xqbkvdos6eu6qyd.onion&lt;br /&gt;
&lt;br /&gt;
=== White House Market ===&lt;br /&gt;
&lt;br /&gt;
White House Market is retiring and closing down the market soon. This was announced 2021-10-01.&lt;br /&gt;
&lt;br /&gt;
The Market remains open some time, how long has not been said but they want to give their users time to settle open trades and withdraw their funds. If you have money on your account login and withdraw.&lt;br /&gt;
&lt;br /&gt;
==== Alternatives to White House Market on the below link ====&lt;br /&gt;
&lt;br /&gt;
*https://darkweb.wtf/?WhiteHouseMarket&lt;br /&gt;
&lt;br /&gt;
Transactions require monero now, starting in 2021. No Bitcoin transactions.&lt;br /&gt;
&lt;br /&gt;
== How to buy stuff on the Darknet ==&lt;br /&gt;
&lt;br /&gt;
Make extra sure that you have entirely read this whole tutorial before diving in – it’s very, very important you fully comprehend each and every step. The following guide is to assist you to buy on the Darknet Markets, the steps explained are the same for all markets - however some details can be different and there are market specific help for beginners available as well.&lt;br /&gt;
&lt;br /&gt;
I strongly (VERY STRONGLY) recommend that you save this link in a plain text file or password app on your own computer, there are alot of phising sites out there that try to provide people with fake links. Be careful and especially if you have alot of Bitcoin. NOTE: ONLY WORKS IN TOR WEB BROWSER - NOT YOUR ORDINARY CHROME OR INTERNET EXPLORER - YOU MUST USE TOR TO ACCESS DARKNET AND .ONION-links.&lt;br /&gt;
&lt;br /&gt;
== Part 1 – Preparing ==&lt;br /&gt;
&#039;&#039;&#039;Install Tor Browser&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
To visit the darkweb, you will need to visit https://www.torproject.org/projects/torbrowser.html and download what is known as the Tor Browser Bundle, for your current OS. There are plenty of detailed instructions for installing it on its download webpage, for OS X, Windows, even Debian, too.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;VPN - Optional step but recommended if you are going to buy frequently or bigger amounts.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
You can find one here to best suit you, we review the best VPN Services for privacy on the market. Every time you use your computer your IP address is shown which reveals your actual physical address which means you can be traced very easily. A VPN must be used along with Tor (Tor is the free browser explained below) to make your online activity anonymous. When using a VPN Service it will hide your identity and location while also encrypting all of you internet traffic from everyone including your internet service provider. This technology will also protect you from identity theft and hacking when using free wifi because everything is encrypted. Any time you are searching for music, movies to download, pirated content, drugs or anything illegal then you should be using a VPN to fly under the radar. The law is trying to monitor everything we do now so don’t make it easy for them, don’t end up like the original mastermind of Silk Road and get busted. This is a must have in your anonymous arsenal.&lt;br /&gt;
&lt;br /&gt;
Your first-ever step in buying something via any marketplace whatsoever, is properly setting-up your digital environment. Following below is a bare standard minimum in order to stay safe when buying personal items. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;PGP - Optional step but strongly recommended. It&#039;s ok to make a first time purchase on Dream Market to try it out before you set this up since it has a small learning curve.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
PGP is an especially useful method of encrypting/decrypting sensitive messages. It’s not very good of an idea to tell a vendor, your home address without first encrypting it, because should the hidden service get seized, LE will have clearly-cut evidence of the crime you have committed. One thought to bear in mind is that not all versions of GPG are created equally, so avoid using GPG methods such as iGolder or those utilizing the BouncyCastle libraries.&lt;br /&gt;
&lt;br /&gt;
This site has long had essential, fundamental guides covering GPG for each and every mainstream OS, Linux, OS X, and then Windows. Linux is the best choice, obviously; however, you will be fine ordering personal goods on either OS X and Windows.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Get some Bitcoins&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Bitcoins2.jpg|200px]]&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin in order to pay, Bitcoins are anonymous and that is the main reason and it is also very hard to trace transactions from one part to another, and even if someone does it is hard to know who is the owner of the Bitcoin address.&lt;br /&gt;
&lt;br /&gt;
So you need to BUY some Bitcoins and the best way is to use AgoraDesk, where you buy from users that want to sell some of their. Some of them will require your ID, a photo of your passport or similiar (Are you just ordering small amounts and occasionally this could be ok) but there are also vendors that can meet up with you and you buy the Bitcoins face-to-face paying in cash.&lt;br /&gt;
&lt;br /&gt;
There are other ways getting Bitcoins of course and whichever way you buy Bitcoin is completely up to your own preference. Regardless, AgoraDesk is one of the most widely-popular options for a reason: it can be done anonymously. There’ve also been reports of Coinbase taking ban action against accounts involved in Darkweb Market deposits, so avoid that if you’re able. No need to use Tor while buying Bitcoins, because it is totally legal and buying through Tor often becomes a cumbersome ordeal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Wallet&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Now that you’ve purchased some Bitcoins, you need to store them somewhere. A particularly great choice is the open-source Electrum Wallet. This is also cross-platform and has a downloadable version for Android phones. Go ahead, download it here. https://electrum.org/download.html Using the Electrum Wallet is quite easily accomplished.&lt;br /&gt;
&lt;br /&gt;
== Part 2 – Some beginning tips ==&lt;br /&gt;
&lt;br /&gt;
Some beginning tips for new users are laid out, here – some are from personal experiences and others from stories across the web:&lt;br /&gt;
&lt;br /&gt;
Remember to use your birth name and real address, as nothing more than a fake name/address draws such negative attention to mail carriers. They are usually fairly familiar with residents of which houses on any block to which they deliver mail regularly and are obligated to report suspicious packages. You can actually get a P.O. Box for a small enough sum of cash, if you live with people who tend to dig through your snail mail.&lt;br /&gt;
&lt;br /&gt;
If you do end up deciding to use a faux name, ensure you’ve got real-looking document forgeries to back that up, should confrontation occur. Fake identification, plus utility-bill scans are mostly sufficient to open up a P.O. box under said faux name.Be patient when you can, majority of the time. Dream Market isn’t Amazon or anything like that – things do often suffer through unexpected delays; vendors usually mark ordered items as shipped immediately, even though they only ship the day after that. &lt;br /&gt;
&lt;br /&gt;
Weather and holidays can also significantly delay proper shipping timeframes. The only time you should rebutt an order’s shipment after not arriving, is after you have waited at least 14 days, or even when Auto-finalize is about to be activated. There will be more covered on this, later.&lt;br /&gt;
&lt;br /&gt;
Encrypt basically everything, messages and all, which you send. These few several minutes are worth losing out on a long-term incarceration.&lt;br /&gt;
&lt;br /&gt;
Should there be any negative experience with a vendor, try to message them, prior to giving a bad review. Chances are that the vendor will go to extreme lengths to make sure you get what you need, and have it all sorted sufficiently. Be as kind and polite as you can; it will move you farther in the process of getting stuff done.&lt;br /&gt;
&lt;br /&gt;
No one should ever know you make purchases on DNMs. This includes not telling your friends or even your blood relatives.&lt;br /&gt;
&lt;br /&gt;
Laundering the coins with which you pay, using something such as Bitcoin Fog or Grams’s Helix is a necessary thing to do, but that is your choice. If you buy personal items, this isn’t required, life or death, and as a result, it won’t be covered in this tutorial.&lt;br /&gt;
&lt;br /&gt;
Anything in the market that looks too CHEAP to be true, is, in all probability, a scam.&lt;br /&gt;
&lt;br /&gt;
Never ever, ever Finalize-Early, even with trusted vendors as they, too, sometimes eventually exit-scam.&lt;br /&gt;
If and when you are able to, ship domestically as much as possible (from within your own country).&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Anonymous email address&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
this could be important when and if the need to communicate with anyone arises, using a Gmail or Hotmail address is bound to not be of very good privacy. Instead, sign up for a free ProtonMail address. Link: https://protonmail.com&lt;br /&gt;
&lt;br /&gt;
== Part 3 – Getting used ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FE vs No-FE&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
FE (finalize-early) is a procedure by which the vendor can retrieve the payment from any sale without waiting for the escrow, which is designed to make sure you do receive your product, to release funds. It’s quite discouraged in this industry, due to the obvious risks involved. Will you encounter a scam on an FE listing, your funds are undoubtedly not recoverable&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Buying from within your own country&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Depending on how much risk you are willing to undergo, and how long you are willing to wait to truly receive your shipped order, you can choose a specific “Shipping From” location during the search process. Ordering from “hot” nations, for instance, such as Pakistan, the Netherlands, and even Colombia are much riskier due to known trade practices in those places.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Judging the Vendor&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Each vendor has his or her PGP key listed as well as the feedback they have received thus far. Just remember, a vendor having mostly positive reviews doesn’t make them bulletproof.&lt;br /&gt;
&lt;br /&gt;
Another great way to get a general feel of a vendor’s reliability is to read reviews of them on the marketplace boards. this site’s listing, and/or the usual Subreddit, DarkNetMarkets. You can also the candidate vendor’s reviews on Grams.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Give feedback&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
If you are satisfied, please remember to leave positive feedback. The most vital component of the darkweb marketplace system is its ratings.&lt;br /&gt;
&lt;br /&gt;
== Old &amp;amp; Closed Markets ==&lt;br /&gt;
&lt;br /&gt;
Below markets does not exist anymore. The reason is different for each of them, Exit Scam being one of the most common reasons but once in a while a markets also gets busted and seized. In some rare occassions the market admins decides to retire in a honorable way. Dream Market one good example on how to retire with honor. &lt;br /&gt;
&lt;br /&gt;
=== (SCAM) Corona Market ===&lt;br /&gt;
&lt;br /&gt;
The admin closed the market place, no further info given. Probably Exit scam.&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Dark Market ===&lt;br /&gt;
&lt;br /&gt;
*THIS MARKET HAS BEEN SEIZED BY GERMAN POLICE&lt;br /&gt;
&lt;br /&gt;
=== (DOWN) Empire Market ===&lt;br /&gt;
&lt;br /&gt;
[[Empire Market]] is the oldest and probably the most reliable, or was until the 22 august 2020. That was when someone started to massively attack the site with DDoS-attacks and everybody is awaiting to see if they manage to get the site back upp and again. Please be careful with links you find, they can be phishing links.. always get the latest links from https://darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
Empire launched in January 2018 shortly after AlphaBay&#039;s demise and grew to 1.3 million users. A staff member estimates under condition of anonymity that the admins profited 2,638 BTC, $30 million USD.&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Deepsea Market === &lt;br /&gt;
&lt;br /&gt;
=== (OUT OF BUSINESS) BitBazaar ===&lt;br /&gt;
&lt;br /&gt;
BitBazaar is a relatively new darkweb market that supports a significant number of cryptocurrencies, features one of the highest referral commission rates, allows purchases without user accounts, and has an ebay-style auction system.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAM) Pax Romana ===&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Agartha ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Samsara Market ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Cryptonia ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Nightmare Market ===&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Exit Scam - Alert july 2019, Do not use!&#039;&#039;&#039;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Incognito_Market&amp;diff=11286</id>
		<title>Incognito Market</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Incognito_Market&amp;diff=11286"/>
		<updated>2025-11-30T10:29:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Incognito Market is a darknet based marketplace where you can buy drugs and medicine, both legal and not.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
= Exit Scam of the century performed by Incognito admin in 2024 =&lt;br /&gt;
&lt;br /&gt;
== ONION link to Incognito ==&lt;br /&gt;
&lt;br /&gt;
You can ONLY reach Incognito Market with your ONION-browser like TOR. It&#039;s not possible to use your Internet Explorer or Safari default browser for these part of the internet called the darknet. You can download TOR browser and install it here, it takes just a brief moment: https://www.torproject.org/download/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Register on Incognito ===&lt;br /&gt;
&lt;br /&gt;
Fill in your desired username and password and the captcha.&lt;br /&gt;
&lt;br /&gt;
[[File:Incognito_market.png|400px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Add money ===&lt;br /&gt;
&lt;br /&gt;
Sending Bitcoin or Monero to your account is easy, just click the &amp;quot;dollar&amp;quot;-button on the upper right corner and generate an address.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Depostin incognito.png|400px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The address is valid for 6 hours, so make sure you generate one before sending. Other markets might have the same address longer and permanent so dont send to an address you used before, you need a fresh one every time.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Deposti2incognito.png|400px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== What can you buy on Incognito Market ==&lt;br /&gt;
&lt;br /&gt;
You will find drugs, both legal and also substances that could be illegal in your country, it is up to you as a user to be aware of that and the risks. However - registering and checking out a darknet market is not against the law so go ahead and check out the market without fear.&lt;br /&gt;
&lt;br /&gt;
There are many vendors to chose from, below a few examples&lt;br /&gt;
&lt;br /&gt;
[[File:Some vendors incognito.png|400px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
A closer look on what the vendor HeinekenExpress has to offer..&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Drugs heinekenexpress.png|400px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Ketamine ===&lt;br /&gt;
&lt;br /&gt;
Lets check whats available in the category dissociatives. We searched for ketamine below..&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Keta on incognito.png|400px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We found the pretty known dutch vendor HeinekenExpress on Incognito, they been selling on the darknet for many many years and people like their stuff. Lets take a look how the buying process is.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:2gketaheineken.png|400px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Clicking the product takes you to the page where you write your delivery address and in the next step pay with either Bitcoin or Monero.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Bying on incognito.png|400px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== What can you buy or sell on Incognito ==&lt;br /&gt;
&lt;br /&gt;
Incognito Market has a strict harm-reduction policy on substances allowed on the market. Currently allowing the below categories.&lt;br /&gt;
&lt;br /&gt;
BENZODIAZEPINES&lt;br /&gt;
Ex.&lt;br /&gt;
- Alprazolam&lt;br /&gt;
- Clonazolam&lt;br /&gt;
- Diazepam&lt;br /&gt;
- Flubromazolam&lt;br /&gt;
- Lorazepam&lt;br /&gt;
-&lt;br /&gt;
Etc.&lt;br /&gt;
&lt;br /&gt;
CANNABINOIDS&lt;br /&gt;
Ex.&lt;br /&gt;
- Cannabis&lt;br /&gt;
- Edibles&lt;br /&gt;
- Assorted cannabis products&lt;br /&gt;
Etc.&lt;br /&gt;
&lt;br /&gt;
DISSOCIATIVES&lt;br /&gt;
Ex.&lt;br /&gt;
- 2-FDCK&lt;br /&gt;
- DXM&lt;br /&gt;
- Ketamine&lt;br /&gt;
Etc.&lt;br /&gt;
&lt;br /&gt;
PSYCHEDELICS&lt;br /&gt;
Ex.&lt;br /&gt;
- LSD&lt;br /&gt;
- Psilocybin Mushrooms&lt;br /&gt;
- DMT&lt;br /&gt;
- Mescaline&lt;br /&gt;
- 2C-Xs&lt;br /&gt;
Etc.&lt;br /&gt;
&lt;br /&gt;
STIMULANTS, ENTACTOGENS AND NOOTROPICS&lt;br /&gt;
Ex.&lt;br /&gt;
- Amphetamine&lt;br /&gt;
- Methamphetamine&lt;br /&gt;
- MDMA&lt;br /&gt;
- MDA&lt;br /&gt;
- Modafinil&lt;br /&gt;
- Cocaine&lt;br /&gt;
Etc.&lt;br /&gt;
&lt;br /&gt;
MISCELLANEOUS&lt;br /&gt;
- Viagra, Cialis, etc.&lt;br /&gt;
- Insulin&lt;br /&gt;
- GHB&lt;br /&gt;
- Alcohol and Tobacco&lt;br /&gt;
- Narcan and similar anti-OD substances&lt;br /&gt;
- Test kits&lt;br /&gt;
&lt;br /&gt;
== More about Incognito Market ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Below is information and text grabbed from their market information...&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Incognito Market originally launched during the holidays last year. We&#039;ve managed to stay out of fights and have maintained good continuous uptime during the year. Our small but dedicated team focuses on giving you the best market experience. If you&#039;ve had some past experience with our feedback thread, you&#039;ll definitely be amazed at how fast we implement your suggestions in a rolling update.&lt;br /&gt;
&lt;br /&gt;
So, what makes us different?&lt;br /&gt;
&lt;br /&gt;
✅ Friendly Interface and User Experience&lt;br /&gt;
On first look, you&#039;ll find that Incognito Market aims to provide an interface that is aesthetic and as simple as possible, with most of the functionalities appearing only when they are required. Our UX is straightforward and easily comprehendable, with no redundant bells and whistles so that you can focus on your shopping without much effort.&lt;br /&gt;
&lt;br /&gt;
✅ Attentive Market Support&lt;br /&gt;
Our market support staff is friendly and responsive, and are always nice to our users. I don&#039;t think that there are negative feedback yet on our market support.&lt;br /&gt;
&lt;br /&gt;
✅ Fast and Secure Codebase&lt;br /&gt;
Incognito Market is written from ground up with a self-designed framework that provides us the maximum flexibility and security required. Also, the framework is designed in a way that allows it to maintain a small bandwidth usage hence reducing the loading time required for our users.&lt;br /&gt;
&lt;br /&gt;
✅ Solid Uptime&lt;br /&gt;
We have recorded only one major outtage since our launch, our system design allows us to not require taking down the servers for most maintenances. Furthermore, our recent infrastructure upgrade further strengthens the reliability and availability of our services.&lt;br /&gt;
&lt;br /&gt;
✅ OTR Jabber Bot&lt;br /&gt;
Tired of logging into our market? Yes, you saw it right. Simply chat with our OTR-secured jabber bot and you can easily manage your orders and listings. Currently, this is only exclusively available for vendors, but who knows? We might open it up for buyers as well soon.&lt;br /&gt;
&lt;br /&gt;
✅ Community Projects&lt;br /&gt;
In addition to Incognito Market, our team also maintains /d/Antinalysis (a Bitcoin analysis service available to the general public) and /d/Sector.city (an anonymous and fast email service).&lt;br /&gt;
&lt;br /&gt;
✅ Withdrawal Crypto Analysis&lt;br /&gt;
For all our withdrawals, we provide optional free fund risk assessments done by Antinalysis in order to increase the safety of our users.&lt;br /&gt;
&lt;br /&gt;
✅ For High Rollers&lt;br /&gt;
If you&#039;re in for a high risk game, we got a casino with some of the common games you&#039;ll find in their physical counterparts!&lt;br /&gt;
&lt;br /&gt;
So, now that I&#039;m interested. How should I join?&lt;br /&gt;
&lt;br /&gt;
For Buyers&lt;br /&gt;
Simply sign up and start buying from your favourite vendors! Our FAQ covers everything you should need to know, and any other questions can be asked here on the subdread or in our modmail and PMs.&lt;br /&gt;
&lt;br /&gt;
For Vendors&lt;br /&gt;
To register as a vendor, first create and sign into a regular user account, and submit an application. Established vendors who have good track records on reputable markets will have their bond fully waived and, depending on rep, may be applicable for FE privileges.&lt;br /&gt;
&lt;br /&gt;
Come and give us a try, you sure won&#039;t regret it !!!&lt;br /&gt;
&lt;br /&gt;
And as always, please feel free to provide any feature requests or suggestions.&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Archetyp_Market&amp;diff=11285</id>
		<title>Archetyp Market</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Archetyp_Market&amp;diff=11285"/>
		<updated>2025-11-30T10:27:43Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= 2025 BEST Market right now is Catharsis =&lt;br /&gt;
&lt;br /&gt;
Catharsis Market, more info at https://darkweb.wtf/?catharsis&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Safe access shortlink (Open in TOR) catharsis.darkweb.wtf&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Catharsis is by far the best marketplace currently (December 2025)&#039;&#039;&#039;. Always easy to login, smooth process for registering. Very intuitive design so you automatically understand where to click and how to do. The admin added Dead Drop feature for some months ago which has become very popular in many European countries. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== History and old info about Archetyp ==&lt;br /&gt;
&lt;br /&gt;
 This Markeplace got seized 2025-06-11 and is not operating any longer. Monero (XMR) only. Archetyp Market opened mid 2021 and was launched as an European only market. The market is special, and does not look like any other market yet.&lt;br /&gt;
&lt;br /&gt;
=== Pay with Monero ===&lt;br /&gt;
&lt;br /&gt;
Monero (XMR) is the best cryptocoin when it comes to safety. It is very anonymous. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Registering on Archetyp Market ===&lt;br /&gt;
&lt;br /&gt;
First of all, enter the captcha on the white screen, 6 digits and then click the broken circle. Next, fill in your desired username, and also a display-name (visible to vendors and other users).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== One of the fastest growing markets ===&lt;br /&gt;
&lt;br /&gt;
Archetyp was launched for the European market and some months later the boom started and as of 2021-11-12 there are almost 1 000 new users every day registering here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Rules on Archetyp ===&lt;br /&gt;
&lt;br /&gt;
On Archetyp you can buy and sell (if you register a vendor account) a large variety of different substances - both legal and illegal. What you buy is up to you, but visiting a darknet market - and even buying is not against the law. Now if you buy something that is not allowed in your country it is up to you to be aware of.&lt;br /&gt;
&lt;br /&gt;
Some bulletpoints from the Archetyp Staff.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Be friendly. Treat others the way you want to be treated. Good behavior is always encouraged.&lt;br /&gt;
*Be fair. Provide fair and honest feedback, understand possible issues on the other end.&lt;br /&gt;
*Be honest. Describe your goods properly, tell others the truth while maintaining your OPSEC standards.&lt;br /&gt;
*Be helpful. Report violations, provide guidance for those in need. We are stronger together.&lt;br /&gt;
&lt;br /&gt;
==== Drugs only market ====&lt;br /&gt;
&lt;br /&gt;
Nothing except medicine and substances are allowed on Archetyp, meaning no guns, no porn, no malware, no fraud items or stolen credit cards - &#039;&#039;&#039;only drugs&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Interview with Archetyp ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;We sent a few questions to the admin of the market, a small interview. Check out the answers below.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;You opened as an EU only market, why?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Initially we opened as EU only market, that was back in May 2020, we wanted to offer a specialized market for Europe, where everything will be customized for Europe only, to serve European interests. On the stoners days, 4/20 2021 what seems to be another market, started a DDoS attack against our onion. As we were not able to find out, which market performed these attacks, our best possible way to payback, was to expand our market to the whole world, to try and takeaway some customers from the attacker \m/&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Aren’t you afraid of getting busted?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
No, not really. While I do have a lot respect towards the police authority and do not underestimate them, I know whereon my security is based and that I have to make sure to keep this at all times.&lt;br /&gt;
&lt;br /&gt;
I think what many people do not keep in mind is, that only because Monero currently counts as &amp;quot;untraceable&amp;quot;, this is not a promise that will still count in the future, there are companies who work active on tracing Monero transactions. The biggest mistakes of busted admins, where often papertrails. &lt;br /&gt;
&lt;br /&gt;
With increasing computation power, it will get easier to trace Monero transactions. If I send a transaction today, there is no guarantee that this transaction will be untraceable in 5 years. My &amp;quot;crimes&amp;quot; will not be lapsed till then, therefore I have to make sure, that my anonymity will still remain, even in 10 years. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Why is only drugs and medicine allowed on your market?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Would drugs be legal in an utopia? Yes. Would Fraud be legal in an utopia? No.&lt;br /&gt;
I think all drugs should be legalized, while I would want harder punishments for Fraud. Drugs use does not directly cause harm. Drug abuse does. We should not ban dangerous substances, but educate about them. I think there is a lot of potential in various mind altering substances. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;What do you think you will be doing in 5 years, what is your vision?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
In five years I&#039;ll run the biggest drug market, while maintaining highest security and quality standards. We have a lot planned with Archetyp, and we continue to always improve. I&#039;m sure we will never stop this way of operation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Do you think drugs will be legalized any time soon?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Worldwide: No. &lt;br /&gt;
Within the the EU, I can see drugs going to be decriminalized, I can not think of a when though. I think the youth is more ready to do it. In Germany cannabis is likely to get legalized within 4 years, so that&#039;s a first step.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Thanks to YosemiteGhostWrite for the answers.&#039;&#039;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Archetyp_Market&amp;diff=11284</id>
		<title>Archetyp Market</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Archetyp_Market&amp;diff=11284"/>
		<updated>2025-11-30T10:26:52Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This Markeplace got seized 2025-06-11 and is not operating any longer. Monero (XMR) only. Archetyp Market opened mid 2021 and was launched as an European only market. The market is special, and does not look like any other market yet.&lt;br /&gt;
&lt;br /&gt;
== BEST Market right now is Catharsis ==&lt;br /&gt;
&lt;br /&gt;
Catharsis Market, more info at https://darkweb.wtf/?catharsis&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Safe access shortlink (Open in TOR) catharsis.darkweb.wtf&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Catharsis is by far the best marketplace currently (December 2025)&#039;&#039;&#039;. Always easy to login, smooth process for registering. Very intuitive design so you automatically understand where to click and how to do. The admin added Dead Drop feature for some months ago which has become very popular in many European countries. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== History and old info about Archetyp ==&lt;br /&gt;
&lt;br /&gt;
=== Pay with Monero ===&lt;br /&gt;
&lt;br /&gt;
Monero (XMR) is the best cryptocoin when it comes to safety. It is very anonymous. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Registering on Archetyp Market ===&lt;br /&gt;
&lt;br /&gt;
First of all, enter the captcha on the white screen, 6 digits and then click the broken circle. Next, fill in your desired username, and also a display-name (visible to vendors and other users).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== One of the fastest growing markets ===&lt;br /&gt;
&lt;br /&gt;
Archetyp was launched for the European market and some months later the boom started and as of 2021-11-12 there are almost 1 000 new users every day registering here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Rules on Archetyp ===&lt;br /&gt;
&lt;br /&gt;
On Archetyp you can buy and sell (if you register a vendor account) a large variety of different substances - both legal and illegal. What you buy is up to you, but visiting a darknet market - and even buying is not against the law. Now if you buy something that is not allowed in your country it is up to you to be aware of.&lt;br /&gt;
&lt;br /&gt;
Some bulletpoints from the Archetyp Staff.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Be friendly. Treat others the way you want to be treated. Good behavior is always encouraged.&lt;br /&gt;
*Be fair. Provide fair and honest feedback, understand possible issues on the other end.&lt;br /&gt;
*Be honest. Describe your goods properly, tell others the truth while maintaining your OPSEC standards.&lt;br /&gt;
*Be helpful. Report violations, provide guidance for those in need. We are stronger together.&lt;br /&gt;
&lt;br /&gt;
==== Drugs only market ====&lt;br /&gt;
&lt;br /&gt;
Nothing except medicine and substances are allowed on Archetyp, meaning no guns, no porn, no malware, no fraud items or stolen credit cards - &#039;&#039;&#039;only drugs&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Interview with Archetyp ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;We sent a few questions to the admin of the market, a small interview. Check out the answers below.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;You opened as an EU only market, why?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Initially we opened as EU only market, that was back in May 2020, we wanted to offer a specialized market for Europe, where everything will be customized for Europe only, to serve European interests. On the stoners days, 4/20 2021 what seems to be another market, started a DDoS attack against our onion. As we were not able to find out, which market performed these attacks, our best possible way to payback, was to expand our market to the whole world, to try and takeaway some customers from the attacker \m/&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Aren’t you afraid of getting busted?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
No, not really. While I do have a lot respect towards the police authority and do not underestimate them, I know whereon my security is based and that I have to make sure to keep this at all times.&lt;br /&gt;
&lt;br /&gt;
I think what many people do not keep in mind is, that only because Monero currently counts as &amp;quot;untraceable&amp;quot;, this is not a promise that will still count in the future, there are companies who work active on tracing Monero transactions. The biggest mistakes of busted admins, where often papertrails. &lt;br /&gt;
&lt;br /&gt;
With increasing computation power, it will get easier to trace Monero transactions. If I send a transaction today, there is no guarantee that this transaction will be untraceable in 5 years. My &amp;quot;crimes&amp;quot; will not be lapsed till then, therefore I have to make sure, that my anonymity will still remain, even in 10 years. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Why is only drugs and medicine allowed on your market?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Would drugs be legal in an utopia? Yes. Would Fraud be legal in an utopia? No.&lt;br /&gt;
I think all drugs should be legalized, while I would want harder punishments for Fraud. Drugs use does not directly cause harm. Drug abuse does. We should not ban dangerous substances, but educate about them. I think there is a lot of potential in various mind altering substances. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;What do you think you will be doing in 5 years, what is your vision?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
In five years I&#039;ll run the biggest drug market, while maintaining highest security and quality standards. We have a lot planned with Archetyp, and we continue to always improve. I&#039;m sure we will never stop this way of operation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Do you think drugs will be legalized any time soon?&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Worldwide: No. &lt;br /&gt;
Within the the EU, I can see drugs going to be decriminalized, I can not think of a when though. I think the youth is more ready to do it. In Germany cannabis is likely to get legalized within 4 years, so that&#039;s a first step.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Thanks to YosemiteGhostWrite for the answers.&#039;&#039;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11283</id>
		<title>Darknet Markets</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11283"/>
		<updated>2025-11-30T10:25:15Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= How do people buy drugs on Darknet =&lt;br /&gt;
&lt;br /&gt;
Using Darknet Markets has come more and more popular in recent years. People buy what they need on these &amp;quot;eBay-like&amp;quot; shopping plattforms. Whether they need legal- or illegal substances - everything is available on these sites. Paying with Bitcoin makes the transaction invisible and using the web browser TOR makes the visit anonymous.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Prerequisites for using Darknet Shopping Markets ==&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin and the browser TOR. You can NOT even visit this type of sites with Chrome or Internet Explorer, so start here.&lt;br /&gt;
&lt;br /&gt;
*Buy some Bitcoin, we recommend &#039;&#039;&#039;LocalCoinSwap&#039;&#039;&#039; available here: https://localcoinswap.com/?rc=965C9547&lt;br /&gt;
*Get TOR browser: https://www.torproject.org/download/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= List of Darknet Markets =&lt;br /&gt;
&lt;br /&gt;
There are International Markets, as well as Country specific. Caution: Be very careful from where you get your links, save the links in a textfile on your computer for next time to protect yourself from getting phished. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== BEST Market right now is Catharsis ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Catharsis Market&#039;&#039;&#039;, more info at https://darkweb.wtf/?catharsis&lt;br /&gt;
&lt;br /&gt;
Safe access shortlink (Open in TOR) catharsis.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
Catharsis is by far the &#039;&#039;&#039;best marketplace currently (December 2025)&#039;&#039;&#039;. Always easy to login, smooth process for registering. Very intuitive design so you automatically understand where to click and how to do. The admin added &#039;&#039;&#039;Dead Drop&#039;&#039;&#039; feature for some months ago which has become very popular in many &#039;&#039;&#039;European&#039;&#039;&#039; countries.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Other live markets ==&lt;br /&gt;
&lt;br /&gt;
=== Dream Market v2 ===&lt;br /&gt;
&lt;br /&gt;
*http://dream2.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market (Busted) ===&lt;br /&gt;
&lt;br /&gt;
This one is worth registering at and keeping an eye on, extremely fast loading and simple. Im talking about Archetyp Market and the link is below, check it out.&lt;br /&gt;
&lt;br /&gt;
Theres also more information about [[Archetyp Market]] available.&lt;br /&gt;
&lt;br /&gt;
=== INCOGNITO MARKET (Exit Scam) ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Read more and learn how to use [[Incognito Market]] in this guide.&lt;br /&gt;
&lt;br /&gt;
The following is a brief discussion about Incognito market, with several very innovative features.&lt;br /&gt;
&lt;br /&gt;
*A clean and friendly user interface that is designed to be easy to navigate.&lt;br /&gt;
*Recon API integration for streamlined vendor applications&lt;br /&gt;
*Fast page load speed (first paint) and user experience with low latency.&lt;br /&gt;
*Authentication designed with security in mind, added secret word concept to prevent security issues caused by lazy password reuse&lt;br /&gt;
*Anonguard, an automated and dynamic DDoS defense that only appears when under attack.&lt;br /&gt;
*Incogbot, our friendly mascot is available for chat over jabber with vendors. Vendors can check/interact with their orders and receive notifications with Incogbot, all the while not losing security with OTR and anti-phishing countermeasures on our jabber bot.&lt;br /&gt;
*Unique featuring system that makes sure featured listings are shown to the buyers most likely to be interested in the item.&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market ===&lt;br /&gt;
&lt;br /&gt;
This one is new, but really unique. We actually expect Archetyp to become the leading darknet Market in very short time. If you look at the user experience and the fast loading, the easy to understand design it will grow fast. The question that remains if the team is experienced enough to handle it? In either case, I indeed encourage you to take a look at this special market.&lt;br /&gt;
&lt;br /&gt;
Reach Archetype at this URL:&lt;br /&gt;
&lt;br /&gt;
*Safe shortlink: http://archetyp.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
OR Onion&lt;br /&gt;
&lt;br /&gt;
*https://darkweb.wtf/?archetyp&lt;br /&gt;
&lt;br /&gt;
Note that Archetyp is Monero (XMR) only market, you need to exchange your Bitcoin into Monero in order to buy - which actually is more secure that btc.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAMMED) Dark0de Reborn ===&lt;br /&gt;
&lt;br /&gt;
A market with alot of vendors and stuff to order. You will find the top rated international vendors on [[Dark0de Market]].&lt;br /&gt;
&lt;br /&gt;
=== (CLOSING DOWN) TORREZ Market ===&lt;br /&gt;
&lt;br /&gt;
Torrez Market is walletless and with a nice clean design. Probably the leading market. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Step-by-step Guide on How to buy and sell [[ToRRez]] Market.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
=== Versus Market ===&lt;br /&gt;
*pqqmr3p3tppwqvvapi6fa7jowrehgd36ct6lzr26qqormaqvh6gt4jyd.onion&lt;br /&gt;
&lt;br /&gt;
=== Monopoly Market ===&lt;br /&gt;
*monopolyberbucxu.onion&lt;br /&gt;
&lt;br /&gt;
=== (ASEAN) ASAP Market === &lt;br /&gt;
*http://aseanm2r6znqjuackec6j7yiauyq4fcvghmskixd4xqbkvdos6eu6qyd.onion&lt;br /&gt;
&lt;br /&gt;
=== White House Market ===&lt;br /&gt;
&lt;br /&gt;
White House Market is retiring and closing down the market soon. This was announced 2021-10-01.&lt;br /&gt;
&lt;br /&gt;
The Market remains open some time, how long has not been said but they want to give their users time to settle open trades and withdraw their funds. If you have money on your account login and withdraw.&lt;br /&gt;
&lt;br /&gt;
==== Alternatives to White House Market on the below link ====&lt;br /&gt;
&lt;br /&gt;
*https://darkweb.wtf/?WhiteHouseMarket&lt;br /&gt;
&lt;br /&gt;
Transactions require monero now, starting in 2021. No Bitcoin transactions.&lt;br /&gt;
&lt;br /&gt;
== How to buy stuff on the Darknet ==&lt;br /&gt;
&lt;br /&gt;
Make extra sure that you have entirely read this whole tutorial before diving in – it’s very, very important you fully comprehend each and every step. The following guide is to assist you to buy on the Darknet Markets, the steps explained are the same for all markets - however some details can be different and there are market specific help for beginners available as well.&lt;br /&gt;
&lt;br /&gt;
I strongly (VERY STRONGLY) recommend that you save this link in a plain text file or password app on your own computer, there are alot of phising sites out there that try to provide people with fake links. Be careful and especially if you have alot of Bitcoin. NOTE: ONLY WORKS IN TOR WEB BROWSER - NOT YOUR ORDINARY CHROME OR INTERNET EXPLORER - YOU MUST USE TOR TO ACCESS DARKNET AND .ONION-links.&lt;br /&gt;
&lt;br /&gt;
== Part 1 – Preparing ==&lt;br /&gt;
&#039;&#039;&#039;Install Tor Browser&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
To visit the darkweb, you will need to visit https://www.torproject.org/projects/torbrowser.html and download what is known as the Tor Browser Bundle, for your current OS. There are plenty of detailed instructions for installing it on its download webpage, for OS X, Windows, even Debian, too.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;VPN - Optional step but recommended if you are going to buy frequently or bigger amounts.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
You can find one here to best suit you, we review the best VPN Services for privacy on the market. Every time you use your computer your IP address is shown which reveals your actual physical address which means you can be traced very easily. A VPN must be used along with Tor (Tor is the free browser explained below) to make your online activity anonymous. When using a VPN Service it will hide your identity and location while also encrypting all of you internet traffic from everyone including your internet service provider. This technology will also protect you from identity theft and hacking when using free wifi because everything is encrypted. Any time you are searching for music, movies to download, pirated content, drugs or anything illegal then you should be using a VPN to fly under the radar. The law is trying to monitor everything we do now so don’t make it easy for them, don’t end up like the original mastermind of Silk Road and get busted. This is a must have in your anonymous arsenal.&lt;br /&gt;
&lt;br /&gt;
Your first-ever step in buying something via any marketplace whatsoever, is properly setting-up your digital environment. Following below is a bare standard minimum in order to stay safe when buying personal items. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;PGP - Optional step but strongly recommended. It&#039;s ok to make a first time purchase on Dream Market to try it out before you set this up since it has a small learning curve.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
PGP is an especially useful method of encrypting/decrypting sensitive messages. It’s not very good of an idea to tell a vendor, your home address without first encrypting it, because should the hidden service get seized, LE will have clearly-cut evidence of the crime you have committed. One thought to bear in mind is that not all versions of GPG are created equally, so avoid using GPG methods such as iGolder or those utilizing the BouncyCastle libraries.&lt;br /&gt;
&lt;br /&gt;
This site has long had essential, fundamental guides covering GPG for each and every mainstream OS, Linux, OS X, and then Windows. Linux is the best choice, obviously; however, you will be fine ordering personal goods on either OS X and Windows.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Get some Bitcoins&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Bitcoins2.jpg|200px]]&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin in order to pay, Bitcoins are anonymous and that is the main reason and it is also very hard to trace transactions from one part to another, and even if someone does it is hard to know who is the owner of the Bitcoin address.&lt;br /&gt;
&lt;br /&gt;
So you need to BUY some Bitcoins and the best way is to use AgoraDesk, where you buy from users that want to sell some of their. Some of them will require your ID, a photo of your passport or similiar (Are you just ordering small amounts and occasionally this could be ok) but there are also vendors that can meet up with you and you buy the Bitcoins face-to-face paying in cash.&lt;br /&gt;
&lt;br /&gt;
There are other ways getting Bitcoins of course and whichever way you buy Bitcoin is completely up to your own preference. Regardless, AgoraDesk is one of the most widely-popular options for a reason: it can be done anonymously. There’ve also been reports of Coinbase taking ban action against accounts involved in Darkweb Market deposits, so avoid that if you’re able. No need to use Tor while buying Bitcoins, because it is totally legal and buying through Tor often becomes a cumbersome ordeal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Wallet&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Now that you’ve purchased some Bitcoins, you need to store them somewhere. A particularly great choice is the open-source Electrum Wallet. This is also cross-platform and has a downloadable version for Android phones. Go ahead, download it here. https://electrum.org/download.html Using the Electrum Wallet is quite easily accomplished.&lt;br /&gt;
&lt;br /&gt;
== Part 2 – Some beginning tips ==&lt;br /&gt;
&lt;br /&gt;
Some beginning tips for new users are laid out, here – some are from personal experiences and others from stories across the web:&lt;br /&gt;
&lt;br /&gt;
Remember to use your birth name and real address, as nothing more than a fake name/address draws such negative attention to mail carriers. They are usually fairly familiar with residents of which houses on any block to which they deliver mail regularly and are obligated to report suspicious packages. You can actually get a P.O. Box for a small enough sum of cash, if you live with people who tend to dig through your snail mail.&lt;br /&gt;
&lt;br /&gt;
If you do end up deciding to use a faux name, ensure you’ve got real-looking document forgeries to back that up, should confrontation occur. Fake identification, plus utility-bill scans are mostly sufficient to open up a P.O. box under said faux name.Be patient when you can, majority of the time. Dream Market isn’t Amazon or anything like that – things do often suffer through unexpected delays; vendors usually mark ordered items as shipped immediately, even though they only ship the day after that. &lt;br /&gt;
&lt;br /&gt;
Weather and holidays can also significantly delay proper shipping timeframes. The only time you should rebutt an order’s shipment after not arriving, is after you have waited at least 14 days, or even when Auto-finalize is about to be activated. There will be more covered on this, later.&lt;br /&gt;
&lt;br /&gt;
Encrypt basically everything, messages and all, which you send. These few several minutes are worth losing out on a long-term incarceration.&lt;br /&gt;
&lt;br /&gt;
Should there be any negative experience with a vendor, try to message them, prior to giving a bad review. Chances are that the vendor will go to extreme lengths to make sure you get what you need, and have it all sorted sufficiently. Be as kind and polite as you can; it will move you farther in the process of getting stuff done.&lt;br /&gt;
&lt;br /&gt;
No one should ever know you make purchases on DNMs. This includes not telling your friends or even your blood relatives.&lt;br /&gt;
&lt;br /&gt;
Laundering the coins with which you pay, using something such as Bitcoin Fog or Grams’s Helix is a necessary thing to do, but that is your choice. If you buy personal items, this isn’t required, life or death, and as a result, it won’t be covered in this tutorial.&lt;br /&gt;
&lt;br /&gt;
Anything in the market that looks too CHEAP to be true, is, in all probability, a scam.&lt;br /&gt;
&lt;br /&gt;
Never ever, ever Finalize-Early, even with trusted vendors as they, too, sometimes eventually exit-scam.&lt;br /&gt;
If and when you are able to, ship domestically as much as possible (from within your own country).&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Anonymous email address&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
this could be important when and if the need to communicate with anyone arises, using a Gmail or Hotmail address is bound to not be of very good privacy. Instead, sign up for a free ProtonMail address. Link: https://protonmail.com&lt;br /&gt;
&lt;br /&gt;
== Part 3 – Getting used ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FE vs No-FE&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
FE (finalize-early) is a procedure by which the vendor can retrieve the payment from any sale without waiting for the escrow, which is designed to make sure you do receive your product, to release funds. It’s quite discouraged in this industry, due to the obvious risks involved. Will you encounter a scam on an FE listing, your funds are undoubtedly not recoverable&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Buying from within your own country&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Depending on how much risk you are willing to undergo, and how long you are willing to wait to truly receive your shipped order, you can choose a specific “Shipping From” location during the search process. Ordering from “hot” nations, for instance, such as Pakistan, the Netherlands, and even Colombia are much riskier due to known trade practices in those places.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Judging the Vendor&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Each vendor has his or her PGP key listed as well as the feedback they have received thus far. Just remember, a vendor having mostly positive reviews doesn’t make them bulletproof.&lt;br /&gt;
&lt;br /&gt;
Another great way to get a general feel of a vendor’s reliability is to read reviews of them on the marketplace boards. this site’s listing, and/or the usual Subreddit, DarkNetMarkets. You can also the candidate vendor’s reviews on Grams.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Give feedback&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
If you are satisfied, please remember to leave positive feedback. The most vital component of the darkweb marketplace system is its ratings.&lt;br /&gt;
&lt;br /&gt;
== Old &amp;amp; Closed Markets ==&lt;br /&gt;
&lt;br /&gt;
Below markets does not exist anymore. The reason is different for each of them, Exit Scam being one of the most common reasons but once in a while a markets also gets busted and seized. In some rare occassions the market admins decides to retire in a honorable way. Dream Market one good example on how to retire with honor. &lt;br /&gt;
&lt;br /&gt;
=== (SCAM) Corona Market ===&lt;br /&gt;
&lt;br /&gt;
The admin closed the market place, no further info given. Probably Exit scam.&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Dark Market ===&lt;br /&gt;
&lt;br /&gt;
*THIS MARKET HAS BEEN SEIZED BY GERMAN POLICE&lt;br /&gt;
&lt;br /&gt;
=== (DOWN) Empire Market ===&lt;br /&gt;
&lt;br /&gt;
[[Empire Market]] is the oldest and probably the most reliable, or was until the 22 august 2020. That was when someone started to massively attack the site with DDoS-attacks and everybody is awaiting to see if they manage to get the site back upp and again. Please be careful with links you find, they can be phishing links.. always get the latest links from https://darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
Empire launched in January 2018 shortly after AlphaBay&#039;s demise and grew to 1.3 million users. A staff member estimates under condition of anonymity that the admins profited 2,638 BTC, $30 million USD.&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Deepsea Market === &lt;br /&gt;
&lt;br /&gt;
=== (OUT OF BUSINESS) BitBazaar ===&lt;br /&gt;
&lt;br /&gt;
BitBazaar is a relatively new darkweb market that supports a significant number of cryptocurrencies, features one of the highest referral commission rates, allows purchases without user accounts, and has an ebay-style auction system.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAM) Pax Romana ===&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Agartha ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Samsara Market ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Cryptonia ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Nightmare Market ===&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Exit Scam - Alert july 2019, Do not use!&#039;&#039;&#039;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11282</id>
		<title>Darknet Markets</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11282"/>
		<updated>2025-11-30T10:23:56Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= How do people buy drugs on Darknet =&lt;br /&gt;
&lt;br /&gt;
Using Darknet Markets has come more and more popular in recent years. People buy what they need on these &amp;quot;eBay-like&amp;quot; shopping plattforms. Whether they need legal- or illegal substances - everything is available on these sites. Paying with Bitcoin makes the transaction invisible and using the web browser TOR makes the visit anonymous.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Prerequisites for using Darknet Shopping Markets ==&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin and the browser TOR. You can NOT even visit this type of sites with Chrome or Internet Explorer, so start here.&lt;br /&gt;
&lt;br /&gt;
*Buy some Bitcoin, we recommend &#039;&#039;&#039;LocalCoinSwap&#039;&#039;&#039; available here: https://localcoinswap.com/?rc=965C9547&lt;br /&gt;
*Get TOR browser: https://www.torproject.org/download/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= List of Darknet Markets =&lt;br /&gt;
&lt;br /&gt;
There are International Markets, as well as Country specific. Caution: Be very careful from where you get your links, save the links in a textfile on your computer for next time to protect yourself from getting phished. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== BEST Market right now is Catharsis ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Catharsis Market&#039;&#039;&#039;, more info at https://darkweb.wtf/?catharsis&lt;br /&gt;
&lt;br /&gt;
Safe access shortlink (Open in TOR) catharsis.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Other live markets ==&lt;br /&gt;
&lt;br /&gt;
=== Dream Market v2 ===&lt;br /&gt;
&lt;br /&gt;
*http://dream2.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market (Busted) ===&lt;br /&gt;
&lt;br /&gt;
This one is worth registering at and keeping an eye on, extremely fast loading and simple. Im talking about Archetyp Market and the link is below, check it out.&lt;br /&gt;
&lt;br /&gt;
Theres also more information about [[Archetyp Market]] available.&lt;br /&gt;
&lt;br /&gt;
=== INCOGNITO MARKET (Exit Scam) ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Read more and learn how to use [[Incognito Market]] in this guide.&lt;br /&gt;
&lt;br /&gt;
The following is a brief discussion about Incognito market, with several very innovative features.&lt;br /&gt;
&lt;br /&gt;
*A clean and friendly user interface that is designed to be easy to navigate.&lt;br /&gt;
*Recon API integration for streamlined vendor applications&lt;br /&gt;
*Fast page load speed (first paint) and user experience with low latency.&lt;br /&gt;
*Authentication designed with security in mind, added secret word concept to prevent security issues caused by lazy password reuse&lt;br /&gt;
*Anonguard, an automated and dynamic DDoS defense that only appears when under attack.&lt;br /&gt;
*Incogbot, our friendly mascot is available for chat over jabber with vendors. Vendors can check/interact with their orders and receive notifications with Incogbot, all the while not losing security with OTR and anti-phishing countermeasures on our jabber bot.&lt;br /&gt;
*Unique featuring system that makes sure featured listings are shown to the buyers most likely to be interested in the item.&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market ===&lt;br /&gt;
&lt;br /&gt;
This one is new, but really unique. We actually expect Archetyp to become the leading darknet Market in very short time. If you look at the user experience and the fast loading, the easy to understand design it will grow fast. The question that remains if the team is experienced enough to handle it? In either case, I indeed encourage you to take a look at this special market.&lt;br /&gt;
&lt;br /&gt;
Reach Archetype at this URL:&lt;br /&gt;
&lt;br /&gt;
*Safe shortlink: http://archetyp.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
OR Onion&lt;br /&gt;
&lt;br /&gt;
*https://darkweb.wtf/?archetyp&lt;br /&gt;
&lt;br /&gt;
Note that Archetyp is Monero (XMR) only market, you need to exchange your Bitcoin into Monero in order to buy - which actually is more secure that btc.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAMMED) Dark0de Reborn ===&lt;br /&gt;
&lt;br /&gt;
A market with alot of vendors and stuff to order. You will find the top rated international vendors on [[Dark0de Market]].&lt;br /&gt;
&lt;br /&gt;
=== (CLOSING DOWN) TORREZ Market ===&lt;br /&gt;
&lt;br /&gt;
Torrez Market is walletless and with a nice clean design. Probably the leading market. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Step-by-step Guide on How to buy and sell [[ToRRez]] Market.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
=== Versus Market ===&lt;br /&gt;
*pqqmr3p3tppwqvvapi6fa7jowrehgd36ct6lzr26qqormaqvh6gt4jyd.onion&lt;br /&gt;
&lt;br /&gt;
=== Monopoly Market ===&lt;br /&gt;
*monopolyberbucxu.onion&lt;br /&gt;
&lt;br /&gt;
=== (ASEAN) ASAP Market === &lt;br /&gt;
*http://aseanm2r6znqjuackec6j7yiauyq4fcvghmskixd4xqbkvdos6eu6qyd.onion&lt;br /&gt;
&lt;br /&gt;
=== White House Market ===&lt;br /&gt;
&lt;br /&gt;
White House Market is retiring and closing down the market soon. This was announced 2021-10-01.&lt;br /&gt;
&lt;br /&gt;
The Market remains open some time, how long has not been said but they want to give their users time to settle open trades and withdraw their funds. If you have money on your account login and withdraw.&lt;br /&gt;
&lt;br /&gt;
==== Alternatives to White House Market on the below link ====&lt;br /&gt;
&lt;br /&gt;
*https://darkweb.wtf/?WhiteHouseMarket&lt;br /&gt;
&lt;br /&gt;
Transactions require monero now, starting in 2021. No Bitcoin transactions.&lt;br /&gt;
&lt;br /&gt;
== How to buy stuff on the Darknet ==&lt;br /&gt;
&lt;br /&gt;
Make extra sure that you have entirely read this whole tutorial before diving in – it’s very, very important you fully comprehend each and every step. The following guide is to assist you to buy on the Darknet Markets, the steps explained are the same for all markets - however some details can be different and there are market specific help for beginners available as well.&lt;br /&gt;
&lt;br /&gt;
I strongly (VERY STRONGLY) recommend that you save this link in a plain text file or password app on your own computer, there are alot of phising sites out there that try to provide people with fake links. Be careful and especially if you have alot of Bitcoin. NOTE: ONLY WORKS IN TOR WEB BROWSER - NOT YOUR ORDINARY CHROME OR INTERNET EXPLORER - YOU MUST USE TOR TO ACCESS DARKNET AND .ONION-links.&lt;br /&gt;
&lt;br /&gt;
== Part 1 – Preparing ==&lt;br /&gt;
&#039;&#039;&#039;Install Tor Browser&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
To visit the darkweb, you will need to visit https://www.torproject.org/projects/torbrowser.html and download what is known as the Tor Browser Bundle, for your current OS. There are plenty of detailed instructions for installing it on its download webpage, for OS X, Windows, even Debian, too.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;VPN - Optional step but recommended if you are going to buy frequently or bigger amounts.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
You can find one here to best suit you, we review the best VPN Services for privacy on the market. Every time you use your computer your IP address is shown which reveals your actual physical address which means you can be traced very easily. A VPN must be used along with Tor (Tor is the free browser explained below) to make your online activity anonymous. When using a VPN Service it will hide your identity and location while also encrypting all of you internet traffic from everyone including your internet service provider. This technology will also protect you from identity theft and hacking when using free wifi because everything is encrypted. Any time you are searching for music, movies to download, pirated content, drugs or anything illegal then you should be using a VPN to fly under the radar. The law is trying to monitor everything we do now so don’t make it easy for them, don’t end up like the original mastermind of Silk Road and get busted. This is a must have in your anonymous arsenal.&lt;br /&gt;
&lt;br /&gt;
Your first-ever step in buying something via any marketplace whatsoever, is properly setting-up your digital environment. Following below is a bare standard minimum in order to stay safe when buying personal items. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;PGP - Optional step but strongly recommended. It&#039;s ok to make a first time purchase on Dream Market to try it out before you set this up since it has a small learning curve.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
PGP is an especially useful method of encrypting/decrypting sensitive messages. It’s not very good of an idea to tell a vendor, your home address without first encrypting it, because should the hidden service get seized, LE will have clearly-cut evidence of the crime you have committed. One thought to bear in mind is that not all versions of GPG are created equally, so avoid using GPG methods such as iGolder or those utilizing the BouncyCastle libraries.&lt;br /&gt;
&lt;br /&gt;
This site has long had essential, fundamental guides covering GPG for each and every mainstream OS, Linux, OS X, and then Windows. Linux is the best choice, obviously; however, you will be fine ordering personal goods on either OS X and Windows.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Get some Bitcoins&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Bitcoins2.jpg|200px]]&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin in order to pay, Bitcoins are anonymous and that is the main reason and it is also very hard to trace transactions from one part to another, and even if someone does it is hard to know who is the owner of the Bitcoin address.&lt;br /&gt;
&lt;br /&gt;
So you need to BUY some Bitcoins and the best way is to use AgoraDesk, where you buy from users that want to sell some of their. Some of them will require your ID, a photo of your passport or similiar (Are you just ordering small amounts and occasionally this could be ok) but there are also vendors that can meet up with you and you buy the Bitcoins face-to-face paying in cash.&lt;br /&gt;
&lt;br /&gt;
There are other ways getting Bitcoins of course and whichever way you buy Bitcoin is completely up to your own preference. Regardless, AgoraDesk is one of the most widely-popular options for a reason: it can be done anonymously. There’ve also been reports of Coinbase taking ban action against accounts involved in Darkweb Market deposits, so avoid that if you’re able. No need to use Tor while buying Bitcoins, because it is totally legal and buying through Tor often becomes a cumbersome ordeal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Wallet&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Now that you’ve purchased some Bitcoins, you need to store them somewhere. A particularly great choice is the open-source Electrum Wallet. This is also cross-platform and has a downloadable version for Android phones. Go ahead, download it here. https://electrum.org/download.html Using the Electrum Wallet is quite easily accomplished.&lt;br /&gt;
&lt;br /&gt;
== Part 2 – Some beginning tips ==&lt;br /&gt;
&lt;br /&gt;
Some beginning tips for new users are laid out, here – some are from personal experiences and others from stories across the web:&lt;br /&gt;
&lt;br /&gt;
Remember to use your birth name and real address, as nothing more than a fake name/address draws such negative attention to mail carriers. They are usually fairly familiar with residents of which houses on any block to which they deliver mail regularly and are obligated to report suspicious packages. You can actually get a P.O. Box for a small enough sum of cash, if you live with people who tend to dig through your snail mail.&lt;br /&gt;
&lt;br /&gt;
If you do end up deciding to use a faux name, ensure you’ve got real-looking document forgeries to back that up, should confrontation occur. Fake identification, plus utility-bill scans are mostly sufficient to open up a P.O. box under said faux name.Be patient when you can, majority of the time. Dream Market isn’t Amazon or anything like that – things do often suffer through unexpected delays; vendors usually mark ordered items as shipped immediately, even though they only ship the day after that. &lt;br /&gt;
&lt;br /&gt;
Weather and holidays can also significantly delay proper shipping timeframes. The only time you should rebutt an order’s shipment after not arriving, is after you have waited at least 14 days, or even when Auto-finalize is about to be activated. There will be more covered on this, later.&lt;br /&gt;
&lt;br /&gt;
Encrypt basically everything, messages and all, which you send. These few several minutes are worth losing out on a long-term incarceration.&lt;br /&gt;
&lt;br /&gt;
Should there be any negative experience with a vendor, try to message them, prior to giving a bad review. Chances are that the vendor will go to extreme lengths to make sure you get what you need, and have it all sorted sufficiently. Be as kind and polite as you can; it will move you farther in the process of getting stuff done.&lt;br /&gt;
&lt;br /&gt;
No one should ever know you make purchases on DNMs. This includes not telling your friends or even your blood relatives.&lt;br /&gt;
&lt;br /&gt;
Laundering the coins with which you pay, using something such as Bitcoin Fog or Grams’s Helix is a necessary thing to do, but that is your choice. If you buy personal items, this isn’t required, life or death, and as a result, it won’t be covered in this tutorial.&lt;br /&gt;
&lt;br /&gt;
Anything in the market that looks too CHEAP to be true, is, in all probability, a scam.&lt;br /&gt;
&lt;br /&gt;
Never ever, ever Finalize-Early, even with trusted vendors as they, too, sometimes eventually exit-scam.&lt;br /&gt;
If and when you are able to, ship domestically as much as possible (from within your own country).&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Anonymous email address&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
this could be important when and if the need to communicate with anyone arises, using a Gmail or Hotmail address is bound to not be of very good privacy. Instead, sign up for a free ProtonMail address. Link: https://protonmail.com&lt;br /&gt;
&lt;br /&gt;
== Part 3 – Getting used ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FE vs No-FE&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
FE (finalize-early) is a procedure by which the vendor can retrieve the payment from any sale without waiting for the escrow, which is designed to make sure you do receive your product, to release funds. It’s quite discouraged in this industry, due to the obvious risks involved. Will you encounter a scam on an FE listing, your funds are undoubtedly not recoverable&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Buying from within your own country&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Depending on how much risk you are willing to undergo, and how long you are willing to wait to truly receive your shipped order, you can choose a specific “Shipping From” location during the search process. Ordering from “hot” nations, for instance, such as Pakistan, the Netherlands, and even Colombia are much riskier due to known trade practices in those places.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Judging the Vendor&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Each vendor has his or her PGP key listed as well as the feedback they have received thus far. Just remember, a vendor having mostly positive reviews doesn’t make them bulletproof.&lt;br /&gt;
&lt;br /&gt;
Another great way to get a general feel of a vendor’s reliability is to read reviews of them on the marketplace boards. this site’s listing, and/or the usual Subreddit, DarkNetMarkets. You can also the candidate vendor’s reviews on Grams.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Give feedback&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
If you are satisfied, please remember to leave positive feedback. The most vital component of the darkweb marketplace system is its ratings.&lt;br /&gt;
&lt;br /&gt;
== Old &amp;amp; Closed Markets ==&lt;br /&gt;
&lt;br /&gt;
Below markets does not exist anymore. The reason is different for each of them, Exit Scam being one of the most common reasons but once in a while a markets also gets busted and seized. In some rare occassions the market admins decides to retire in a honorable way. Dream Market one good example on how to retire with honor. &lt;br /&gt;
&lt;br /&gt;
=== (SCAM) Corona Market ===&lt;br /&gt;
&lt;br /&gt;
The admin closed the market place, no further info given. Probably Exit scam.&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Dark Market ===&lt;br /&gt;
&lt;br /&gt;
*THIS MARKET HAS BEEN SEIZED BY GERMAN POLICE&lt;br /&gt;
&lt;br /&gt;
=== (DOWN) Empire Market ===&lt;br /&gt;
&lt;br /&gt;
[[Empire Market]] is the oldest and probably the most reliable, or was until the 22 august 2020. That was when someone started to massively attack the site with DDoS-attacks and everybody is awaiting to see if they manage to get the site back upp and again. Please be careful with links you find, they can be phishing links.. always get the latest links from https://darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
Empire launched in January 2018 shortly after AlphaBay&#039;s demise and grew to 1.3 million users. A staff member estimates under condition of anonymity that the admins profited 2,638 BTC, $30 million USD.&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Deepsea Market === &lt;br /&gt;
&lt;br /&gt;
=== (OUT OF BUSINESS) BitBazaar ===&lt;br /&gt;
&lt;br /&gt;
BitBazaar is a relatively new darkweb market that supports a significant number of cryptocurrencies, features one of the highest referral commission rates, allows purchases without user accounts, and has an ebay-style auction system.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAM) Pax Romana ===&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Agartha ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Samsara Market ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Cryptonia ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Nightmare Market ===&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Exit Scam - Alert july 2019, Do not use!&#039;&#039;&#039;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11281</id>
		<title>Darknet Markets</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Darknet_Markets&amp;diff=11281"/>
		<updated>2025-11-30T10:22:15Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= How do people buy drugs on Darknet =&lt;br /&gt;
&lt;br /&gt;
Using Darknet Markets has come more and more popular in recent years. People buy what they need on these &amp;quot;eBay-like&amp;quot; shopping plattforms. Whether they need legal- or illegal substances - everything is available on these sites. Paying with Bitcoin makes the transaction invisible and using the web browser TOR makes the visit anonymous.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Prerequisites for using Darknet Shopping Markets ==&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin and the browser TOR. You can NOT even visit this type of sites with Chrome or Internet Explorer, so start here.&lt;br /&gt;
&lt;br /&gt;
*Buy some Bitcoin, we recommend LocalCoinSwap&lt;br /&gt;
*Get TOR browser: https://www.torproject.org/download/&lt;br /&gt;
&lt;br /&gt;
== List of Darknet Markets ==&lt;br /&gt;
&lt;br /&gt;
There are International Markets, as well as Country specific. Caution: Be very careful from where you get your links, save the links in a textfile on your computer for next time to protect yourself from getting phished. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== BEST Market right now is Catharsis ===&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Catharsis Market&#039;&#039;&#039;, more info at https://darkweb.wtf/?catharsis&lt;br /&gt;
&lt;br /&gt;
Safe access shortlink (Open in TOR) catharsis.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
=== Dream Market v2 ===&lt;br /&gt;
&lt;br /&gt;
*http://dream2.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market (Busted) ===&lt;br /&gt;
&lt;br /&gt;
This one is worth registering at and keeping an eye on, extremely fast loading and simple. Im talking about Archetyp Market and the link is below, check it out.&lt;br /&gt;
&lt;br /&gt;
Theres also more information about [[Archetyp Market]] available.&lt;br /&gt;
&lt;br /&gt;
=== INCOGNITO MARKET (Exit Scam) ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Read more and learn how to use [[Incognito Market]] in this guide.&lt;br /&gt;
&lt;br /&gt;
The following is a brief discussion about Incognito market, with several very innovative features.&lt;br /&gt;
&lt;br /&gt;
*A clean and friendly user interface that is designed to be easy to navigate.&lt;br /&gt;
*Recon API integration for streamlined vendor applications&lt;br /&gt;
*Fast page load speed (first paint) and user experience with low latency.&lt;br /&gt;
*Authentication designed with security in mind, added secret word concept to prevent security issues caused by lazy password reuse&lt;br /&gt;
*Anonguard, an automated and dynamic DDoS defense that only appears when under attack.&lt;br /&gt;
*Incogbot, our friendly mascot is available for chat over jabber with vendors. Vendors can check/interact with their orders and receive notifications with Incogbot, all the while not losing security with OTR and anti-phishing countermeasures on our jabber bot.&lt;br /&gt;
*Unique featuring system that makes sure featured listings are shown to the buyers most likely to be interested in the item.&lt;br /&gt;
&lt;br /&gt;
=== Archetyp Market ===&lt;br /&gt;
&lt;br /&gt;
This one is new, but really unique. We actually expect Archetyp to become the leading darknet Market in very short time. If you look at the user experience and the fast loading, the easy to understand design it will grow fast. The question that remains if the team is experienced enough to handle it? In either case, I indeed encourage you to take a look at this special market.&lt;br /&gt;
&lt;br /&gt;
Reach Archetype at this URL:&lt;br /&gt;
&lt;br /&gt;
*Safe shortlink: http://archetyp.darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
OR Onion&lt;br /&gt;
&lt;br /&gt;
*https://darkweb.wtf/?archetyp&lt;br /&gt;
&lt;br /&gt;
Note that Archetyp is Monero (XMR) only market, you need to exchange your Bitcoin into Monero in order to buy - which actually is more secure that btc.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAMMED) Dark0de Reborn ===&lt;br /&gt;
&lt;br /&gt;
A market with alot of vendors and stuff to order. You will find the top rated international vendors on [[Dark0de Market]].&lt;br /&gt;
&lt;br /&gt;
=== (CLOSING DOWN) TORREZ Market ===&lt;br /&gt;
&lt;br /&gt;
Torrez Market is walletless and with a nice clean design. Probably the leading market. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Step-by-step Guide on How to buy and sell [[ToRRez]] Market.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
=== Versus Market ===&lt;br /&gt;
*pqqmr3p3tppwqvvapi6fa7jowrehgd36ct6lzr26qqormaqvh6gt4jyd.onion&lt;br /&gt;
&lt;br /&gt;
=== Monopoly Market ===&lt;br /&gt;
*monopolyberbucxu.onion&lt;br /&gt;
&lt;br /&gt;
=== (ASEAN) ASAP Market === &lt;br /&gt;
*http://aseanm2r6znqjuackec6j7yiauyq4fcvghmskixd4xqbkvdos6eu6qyd.onion&lt;br /&gt;
&lt;br /&gt;
=== White House Market ===&lt;br /&gt;
&lt;br /&gt;
White House Market is retiring and closing down the market soon. This was announced 2021-10-01.&lt;br /&gt;
&lt;br /&gt;
The Market remains open some time, how long has not been said but they want to give their users time to settle open trades and withdraw their funds. If you have money on your account login and withdraw.&lt;br /&gt;
&lt;br /&gt;
==== Alternatives to White House Market on the below link ====&lt;br /&gt;
&lt;br /&gt;
*https://darkweb.wtf/?WhiteHouseMarket&lt;br /&gt;
&lt;br /&gt;
Transactions require monero now, starting in 2021. No Bitcoin transactions.&lt;br /&gt;
&lt;br /&gt;
== How to buy stuff on the Darknet ==&lt;br /&gt;
&lt;br /&gt;
Make extra sure that you have entirely read this whole tutorial before diving in – it’s very, very important you fully comprehend each and every step. The following guide is to assist you to buy on the Darknet Markets, the steps explained are the same for all markets - however some details can be different and there are market specific help for beginners available as well.&lt;br /&gt;
&lt;br /&gt;
I strongly (VERY STRONGLY) recommend that you save this link in a plain text file or password app on your own computer, there are alot of phising sites out there that try to provide people with fake links. Be careful and especially if you have alot of Bitcoin. NOTE: ONLY WORKS IN TOR WEB BROWSER - NOT YOUR ORDINARY CHROME OR INTERNET EXPLORER - YOU MUST USE TOR TO ACCESS DARKNET AND .ONION-links.&lt;br /&gt;
&lt;br /&gt;
== Part 1 – Preparing ==&lt;br /&gt;
&#039;&#039;&#039;Install Tor Browser&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
To visit the darkweb, you will need to visit https://www.torproject.org/projects/torbrowser.html and download what is known as the Tor Browser Bundle, for your current OS. There are plenty of detailed instructions for installing it on its download webpage, for OS X, Windows, even Debian, too.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;VPN - Optional step but recommended if you are going to buy frequently or bigger amounts.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
You can find one here to best suit you, we review the best VPN Services for privacy on the market. Every time you use your computer your IP address is shown which reveals your actual physical address which means you can be traced very easily. A VPN must be used along with Tor (Tor is the free browser explained below) to make your online activity anonymous. When using a VPN Service it will hide your identity and location while also encrypting all of you internet traffic from everyone including your internet service provider. This technology will also protect you from identity theft and hacking when using free wifi because everything is encrypted. Any time you are searching for music, movies to download, pirated content, drugs or anything illegal then you should be using a VPN to fly under the radar. The law is trying to monitor everything we do now so don’t make it easy for them, don’t end up like the original mastermind of Silk Road and get busted. This is a must have in your anonymous arsenal.&lt;br /&gt;
&lt;br /&gt;
Your first-ever step in buying something via any marketplace whatsoever, is properly setting-up your digital environment. Following below is a bare standard minimum in order to stay safe when buying personal items. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;PGP - Optional step but strongly recommended. It&#039;s ok to make a first time purchase on Dream Market to try it out before you set this up since it has a small learning curve.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
PGP is an especially useful method of encrypting/decrypting sensitive messages. It’s not very good of an idea to tell a vendor, your home address without first encrypting it, because should the hidden service get seized, LE will have clearly-cut evidence of the crime you have committed. One thought to bear in mind is that not all versions of GPG are created equally, so avoid using GPG methods such as iGolder or those utilizing the BouncyCastle libraries.&lt;br /&gt;
&lt;br /&gt;
This site has long had essential, fundamental guides covering GPG for each and every mainstream OS, Linux, OS X, and then Windows. Linux is the best choice, obviously; however, you will be fine ordering personal goods on either OS X and Windows.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Get some Bitcoins&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Bitcoins2.jpg|200px]]&lt;br /&gt;
&lt;br /&gt;
You need Bitcoin in order to pay, Bitcoins are anonymous and that is the main reason and it is also very hard to trace transactions from one part to another, and even if someone does it is hard to know who is the owner of the Bitcoin address.&lt;br /&gt;
&lt;br /&gt;
So you need to BUY some Bitcoins and the best way is to use AgoraDesk, where you buy from users that want to sell some of their. Some of them will require your ID, a photo of your passport or similiar (Are you just ordering small amounts and occasionally this could be ok) but there are also vendors that can meet up with you and you buy the Bitcoins face-to-face paying in cash.&lt;br /&gt;
&lt;br /&gt;
There are other ways getting Bitcoins of course and whichever way you buy Bitcoin is completely up to your own preference. Regardless, AgoraDesk is one of the most widely-popular options for a reason: it can be done anonymously. There’ve also been reports of Coinbase taking ban action against accounts involved in Darkweb Market deposits, so avoid that if you’re able. No need to use Tor while buying Bitcoins, because it is totally legal and buying through Tor often becomes a cumbersome ordeal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Wallet&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Now that you’ve purchased some Bitcoins, you need to store them somewhere. A particularly great choice is the open-source Electrum Wallet. This is also cross-platform and has a downloadable version for Android phones. Go ahead, download it here. https://electrum.org/download.html Using the Electrum Wallet is quite easily accomplished.&lt;br /&gt;
&lt;br /&gt;
== Part 2 – Some beginning tips ==&lt;br /&gt;
&lt;br /&gt;
Some beginning tips for new users are laid out, here – some are from personal experiences and others from stories across the web:&lt;br /&gt;
&lt;br /&gt;
Remember to use your birth name and real address, as nothing more than a fake name/address draws such negative attention to mail carriers. They are usually fairly familiar with residents of which houses on any block to which they deliver mail regularly and are obligated to report suspicious packages. You can actually get a P.O. Box for a small enough sum of cash, if you live with people who tend to dig through your snail mail.&lt;br /&gt;
&lt;br /&gt;
If you do end up deciding to use a faux name, ensure you’ve got real-looking document forgeries to back that up, should confrontation occur. Fake identification, plus utility-bill scans are mostly sufficient to open up a P.O. box under said faux name.Be patient when you can, majority of the time. Dream Market isn’t Amazon or anything like that – things do often suffer through unexpected delays; vendors usually mark ordered items as shipped immediately, even though they only ship the day after that. &lt;br /&gt;
&lt;br /&gt;
Weather and holidays can also significantly delay proper shipping timeframes. The only time you should rebutt an order’s shipment after not arriving, is after you have waited at least 14 days, or even when Auto-finalize is about to be activated. There will be more covered on this, later.&lt;br /&gt;
&lt;br /&gt;
Encrypt basically everything, messages and all, which you send. These few several minutes are worth losing out on a long-term incarceration.&lt;br /&gt;
&lt;br /&gt;
Should there be any negative experience with a vendor, try to message them, prior to giving a bad review. Chances are that the vendor will go to extreme lengths to make sure you get what you need, and have it all sorted sufficiently. Be as kind and polite as you can; it will move you farther in the process of getting stuff done.&lt;br /&gt;
&lt;br /&gt;
No one should ever know you make purchases on DNMs. This includes not telling your friends or even your blood relatives.&lt;br /&gt;
&lt;br /&gt;
Laundering the coins with which you pay, using something such as Bitcoin Fog or Grams’s Helix is a necessary thing to do, but that is your choice. If you buy personal items, this isn’t required, life or death, and as a result, it won’t be covered in this tutorial.&lt;br /&gt;
&lt;br /&gt;
Anything in the market that looks too CHEAP to be true, is, in all probability, a scam.&lt;br /&gt;
&lt;br /&gt;
Never ever, ever Finalize-Early, even with trusted vendors as they, too, sometimes eventually exit-scam.&lt;br /&gt;
If and when you are able to, ship domestically as much as possible (from within your own country).&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Anonymous email address&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
this could be important when and if the need to communicate with anyone arises, using a Gmail or Hotmail address is bound to not be of very good privacy. Instead, sign up for a free ProtonMail address. Link: https://protonmail.com&lt;br /&gt;
&lt;br /&gt;
== Part 3 – Getting used ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;FE vs No-FE&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
FE (finalize-early) is a procedure by which the vendor can retrieve the payment from any sale without waiting for the escrow, which is designed to make sure you do receive your product, to release funds. It’s quite discouraged in this industry, due to the obvious risks involved. Will you encounter a scam on an FE listing, your funds are undoubtedly not recoverable&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Buying from within your own country&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Depending on how much risk you are willing to undergo, and how long you are willing to wait to truly receive your shipped order, you can choose a specific “Shipping From” location during the search process. Ordering from “hot” nations, for instance, such as Pakistan, the Netherlands, and even Colombia are much riskier due to known trade practices in those places.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Judging the Vendor&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Each vendor has his or her PGP key listed as well as the feedback they have received thus far. Just remember, a vendor having mostly positive reviews doesn’t make them bulletproof.&lt;br /&gt;
&lt;br /&gt;
Another great way to get a general feel of a vendor’s reliability is to read reviews of them on the marketplace boards. this site’s listing, and/or the usual Subreddit, DarkNetMarkets. You can also the candidate vendor’s reviews on Grams.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Give feedback&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
If you are satisfied, please remember to leave positive feedback. The most vital component of the darkweb marketplace system is its ratings.&lt;br /&gt;
&lt;br /&gt;
== Old &amp;amp; Closed Markets ==&lt;br /&gt;
&lt;br /&gt;
Below markets does not exist anymore. The reason is different for each of them, Exit Scam being one of the most common reasons but once in a while a markets also gets busted and seized. In some rare occassions the market admins decides to retire in a honorable way. Dream Market one good example on how to retire with honor. &lt;br /&gt;
&lt;br /&gt;
=== (SCAM) Corona Market ===&lt;br /&gt;
&lt;br /&gt;
The admin closed the market place, no further info given. Probably Exit scam.&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Dark Market ===&lt;br /&gt;
&lt;br /&gt;
*THIS MARKET HAS BEEN SEIZED BY GERMAN POLICE&lt;br /&gt;
&lt;br /&gt;
=== (DOWN) Empire Market ===&lt;br /&gt;
&lt;br /&gt;
[[Empire Market]] is the oldest and probably the most reliable, or was until the 22 august 2020. That was when someone started to massively attack the site with DDoS-attacks and everybody is awaiting to see if they manage to get the site back upp and again. Please be careful with links you find, they can be phishing links.. always get the latest links from https://darkweb.wtf&lt;br /&gt;
&lt;br /&gt;
Empire launched in January 2018 shortly after AlphaBay&#039;s demise and grew to 1.3 million users. A staff member estimates under condition of anonymity that the admins profited 2,638 BTC, $30 million USD.&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Deepsea Market === &lt;br /&gt;
&lt;br /&gt;
=== (OUT OF BUSINESS) BitBazaar ===&lt;br /&gt;
&lt;br /&gt;
BitBazaar is a relatively new darkweb market that supports a significant number of cryptocurrencies, features one of the highest referral commission rates, allows purchases without user accounts, and has an ebay-style auction system.&lt;br /&gt;
&lt;br /&gt;
=== (EXIT SCAM) Pax Romana ===&lt;br /&gt;
&lt;br /&gt;
=== (BUSTED) Agartha ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Samsara Market ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Cryptonia ===&lt;br /&gt;
&lt;br /&gt;
=== (CLOSED) Nightmare Market ===&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Exit Scam - Alert july 2019, Do not use!&#039;&#039;&#039;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Category:Steroids&amp;diff=11280</id>
		<title>Category:Steroids</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Category:Steroids&amp;diff=11280"/>
		<updated>2025-11-30T07:19:14Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Substances and brands used for muscle gain. &#039;&#039;&#039;Anabolic steroids&#039;&#039;&#039; are lab‑made versions of &#039;&#039;&#039;testosterone&#039;&#039;&#039;, technically known as anabolic‑androgenic steroids (AAS). “Anabolic” describes their muscle‑building effects, while “androgenic” refers to their role as sex hormones.&lt;br /&gt;
&lt;br /&gt;
==Testosterone==&lt;br /&gt;
The primary androgen, drives the development of male traits and occurs naturally at much higher levels in men than in women.&lt;br /&gt;
&lt;br /&gt;
These medications are prescribed mainly for low testosterone (male hypogonadism), but healthcare providers also use them to support muscle growth in certain medical conditions, such as specific cancers or AIDS.&lt;br /&gt;
&lt;br /&gt;
Some athletes and bodybuilders misuse anabolic steroids to boost performance or change their appearance. They are the most widely used appearance‑ and performance‑enhancing drugs, with an estimated 3 to 4 million people in the United States taking them without medical guidance.&lt;br /&gt;
&lt;br /&gt;
===Anabolic steroids are available in several forms===&lt;br /&gt;
&lt;br /&gt;
• Pills&lt;br /&gt;
• Injections&lt;br /&gt;
• Creams or gels&lt;br /&gt;
• Skin patches&lt;br /&gt;
• Implantable pellets&lt;br /&gt;
[[Category:Drugs]]&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Category:Drugs&amp;diff=11279</id>
		<title>Category:Drugs</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Category:Drugs&amp;diff=11279"/>
		<updated>2025-11-30T07:16:45Z</updated>

		<summary type="html">&lt;p&gt;Sysop: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;A drug is any substance that alters the body’s structure or function. It can serve medical purposes—such as diagnosing, treating, or preventing disease—and may come in the form of chemical compounds or biological products.&#039;&#039;&#039; More broadly, the term also includes &#039;&#039;&#039;psychoactive&#039;&#039;&#039; or &#039;&#039;&#039;intoxicating substances&#039;&#039;&#039; like alcohol, which may be legal or illegal depending on local laws.&lt;br /&gt;
&lt;br /&gt;
This is probably the biggest category on the english part of Drugwiki, most articles are listed here.&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:UserWelcome&amp;diff=11278</id>
		<title>Template:UserWelcome</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:UserWelcome&amp;diff=11278"/>
		<updated>2025-11-30T07:09:57Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;welcomeUser /&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:CustomExperienceOutput&amp;diff=11276</id>
		<title>Template:CustomExperienceOutput</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:CustomExperienceOutput&amp;diff=11276"/>
		<updated>2025-11-30T07:09:57Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[{{{1}}}|{{#replace:{{{1}}}|Experience:|}}]]&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Main_Page&amp;diff=11274</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Main_Page&amp;diff=11274"/>
		<updated>2025-11-30T07:09:57Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Everything about &#039;&#039;&#039;drugs&#039;&#039;&#039;! Is there something you want to know about a substance? Drugwiki is a living encyclopedia about drugs, narcotics, steroids and medicine.&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;background: transparent none repeat scroll 0% 0%; width: 60%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 60%; text-align: center; white-space: nowrap; color: rgb(0, 0, 0);&amp;quot; | &amp;lt;div style=&amp;quot;margin: 0pt; padding: 0.1em; font-size: 162%; color: rgb(0, 0, 0);&amp;quot;&amp;gt;&#039;&#039;&#039;[[Drugwiki|Drugwiki]]&#039;&#039;&#039;&amp;lt;/div&amp;gt; &amp;lt;div style=&amp;quot;top: 0.2em; font-size: 100%;&amp;quot;&amp;gt;A lexicon about drugs, narcotics, steroids and medicine.&amp;lt;/div&amp;gt; &amp;lt;div class=&amp;quot;plainlinks&amp;quot; id=&amp;quot;articlecount&amp;quot; style=&amp;quot;width: 100%; text-align: center; font-size: 100%;&amp;quot;&amp;gt;[[Drugwiki:Purpose|Purpose Explained]] [[Image:Bullet red.png|7px|·]] [[Drugwiki:Contact|Contact us]] [[Image:Bullet red.png|7px|·]] [[Drugwiki:Help|Help with Editing]] &amp;lt;br&amp;gt; &lt;br /&gt;
[[Drugwiki:Styleguide|Styleguide]] [[Image:Bullet red.png|7px|·]] Articles [[Special:Allpages|A to O]] [[Image:Bullet red.png|7px|·]] [[External_resources|External Resources]]&lt;br /&gt;
Number of Articles: [[Special:Statistics|{{NUMBEROFPAGES}}]]&amp;lt;/div&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Huvudfönster --&amp;gt; &lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;margin: 0px; border-spacing: 8px; width: 100%;&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| class=&amp;quot;MainPageBG&amp;quot; style=&amp;quot;border: 1px solid rgb(206, 223, 242); width: 50%; background-color: rgb(245, 250, 255); vertical-align: top;&amp;quot; | &lt;br /&gt;
{| cellspacing=&amp;quot;5&amp;quot; cellpadding=&amp;quot;2&amp;quot; width=&amp;quot;100%&amp;quot; style=&amp;quot;vertical-align: top; background-color: rgb(245, 250, 255);&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! &amp;lt;div style=&amp;quot;border: 1px solid rgb(163, 191, 177); margin: 0pt; padding: 0.2em 0.4em; background: rgb(206, 223, 242) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; font-size: 120%; font-weight: bold; text-align: left; color: rgb(0, 0, 0);&amp;quot;&amp;gt;About Drugwiki&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;color: rgb(0, 0, 0);&amp;quot; | {{Drugwiki:About}}&lt;br /&gt;
|-&lt;br /&gt;
! &amp;lt;div style=&amp;quot;border: 1px solid rgb(163, 191, 177); margin: 0pt; padding: 0.2em 0.4em; background: rgb(206, 223, 242) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; font-size: 120%; font-weight: bold; text-align: left; color: rgb(0, 0, 0);&amp;quot;&amp;gt;Drugwiki, the developement&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;color: rgb(0, 0, 0);&amp;quot; | &lt;br /&gt;
{{Utveckling}} &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
! &amp;lt;div style=&amp;quot;border: 1px solid rgb(163, 191, 177); margin: 0pt; padding: 0.2em 0.4em; background: rgb(206, 223, 242) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; font-size: 120%; font-weight: bold; text-align: left; color: rgb(0, 0, 0);&amp;quot;&amp;gt;Common drugs&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;color: rgb(0, 0, 0);&amp;quot; | &lt;br /&gt;
A &lt;br /&gt;
&lt;br /&gt;
*[[Alcohol]] &lt;br /&gt;
*[[Amphetamine]] &lt;br /&gt;
*[[Alkyl nitrites]] &lt;br /&gt;
*[[Alkaloids]]&lt;br /&gt;
&lt;br /&gt;
B &lt;br /&gt;
&lt;br /&gt;
*[[Benzodiazepine]] &lt;br /&gt;
*[[Barbiturate]] &lt;br /&gt;
*[[Buprenorphine]] &lt;br /&gt;
*[[BZP]]&lt;br /&gt;
&lt;br /&gt;
C &lt;br /&gt;
&lt;br /&gt;
*[[Cannabis]]&lt;br /&gt;
*[[Cocaine]]&lt;br /&gt;
*[[Coffee]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt; D &lt;br /&gt;
&lt;br /&gt;
*[[DXM]] &lt;br /&gt;
*[[DPT]]&lt;br /&gt;
&lt;br /&gt;
E &lt;br /&gt;
&lt;br /&gt;
*[[:Category:Ecstasy|Ecstasy]] &lt;br /&gt;
*[[Ephedrine]]&lt;br /&gt;
&lt;br /&gt;
F &lt;br /&gt;
&lt;br /&gt;
G &lt;br /&gt;
&lt;br /&gt;
*[[GHB]] &lt;br /&gt;
*[[GBL]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt; H &lt;br /&gt;
&lt;br /&gt;
*[[Haschish]] &lt;br /&gt;
*[[Heroine]]&lt;br /&gt;
&lt;br /&gt;
I &lt;br /&gt;
&lt;br /&gt;
J &lt;br /&gt;
&lt;br /&gt;
K &lt;br /&gt;
&lt;br /&gt;
*[[Ketamine]] &lt;br /&gt;
*[[Khat]] &lt;br /&gt;
*[[Codeine]]&lt;br /&gt;
&lt;br /&gt;
L &lt;br /&gt;
&lt;br /&gt;
*[[LSD]]&lt;br /&gt;
&lt;br /&gt;
M &lt;br /&gt;
&lt;br /&gt;
*[[Marijuana]] &lt;br /&gt;
*[[Methadone]] &lt;br /&gt;
*[[Methylphenidate]] &lt;br /&gt;
*[[Morphine]] &lt;br /&gt;
*[[MDA]] &lt;br /&gt;
*[[MDMA]] &lt;br /&gt;
*[[Methamphetamine]]&lt;br /&gt;
&lt;br /&gt;
N &lt;br /&gt;
&lt;br /&gt;
*[[Nicotine]]&lt;br /&gt;
&lt;br /&gt;
O &lt;br /&gt;
&lt;br /&gt;
*[[Opiate]] &lt;br /&gt;
*[[Opium]]&lt;br /&gt;
&lt;br /&gt;
P &lt;br /&gt;
&lt;br /&gt;
*[[PCP]] &lt;br /&gt;
*[[Poppers]]&lt;br /&gt;
&lt;br /&gt;
Q &lt;br /&gt;
&lt;br /&gt;
R &lt;br /&gt;
&lt;br /&gt;
*[[Rohypnol]]&lt;br /&gt;
&lt;br /&gt;
S &lt;br /&gt;
&lt;br /&gt;
*[[Salvia]] &lt;br /&gt;
*[[STP]]&lt;br /&gt;
&lt;br /&gt;
T &lt;br /&gt;
&lt;br /&gt;
*[[Tobacco]] &lt;br /&gt;
*[[THC]]&lt;br /&gt;
&lt;br /&gt;
U &lt;br /&gt;
&lt;br /&gt;
V &lt;br /&gt;
&lt;br /&gt;
*[[Valium]]&lt;br /&gt;
&lt;br /&gt;
W &lt;br /&gt;
&lt;br /&gt;
X &lt;br /&gt;
&lt;br /&gt;
Y &lt;br /&gt;
&lt;br /&gt;
Z &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Common Steroids&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
*[[Sustanon]] &lt;br /&gt;
*[[Deca Durabolin]] &lt;br /&gt;
*[[Winstrol]] &lt;br /&gt;
*[[Dianabol]] &lt;br /&gt;
*[[Primobolan Depot]]&lt;br /&gt;
*[[Parabolan]] &lt;br /&gt;
*[[Proviron]] &lt;br /&gt;
*[[Testoviron]] &lt;br /&gt;
*[[Spirospent]] &lt;br /&gt;
*[[Andriol]] &lt;br /&gt;
*[[HCG]] &lt;br /&gt;
*[[Masteron]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt; &lt;br /&gt;
&amp;lt;div align=&amp;quot;right&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Högerspalt --&amp;gt; &lt;br /&gt;
&lt;br /&gt;
| class=&amp;quot;MainPageBG&amp;quot; style=&amp;quot;border: 1px solid rgb(206, 223, 242); width: 50%; background-color: rgb(245, 250, 255); vertical-align: top;&amp;quot; | &lt;br /&gt;
{| cellspacing=&amp;quot;5&amp;quot; cellpadding=&amp;quot;2&amp;quot; width=&amp;quot;100%&amp;quot; style=&amp;quot;vertical-align: top; background-color: rgb(245, 250, 255);&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! &amp;lt;div style=&amp;quot;border: 1px solid rgb(163, 191, 177); margin: 0pt; padding: 0.2em 0.4em; background: rgb(206, 223, 242) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; font-size: 120%; font-weight: bold; text-align: left; color: rgb(0, 0, 0);&amp;quot;&amp;gt;Featured news&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;color: rgb(0, 0, 0);&amp;quot; | {{Featured}}&lt;br /&gt;
|-&lt;br /&gt;
! &amp;lt;div style=&amp;quot;border: 1px solid rgb(163, 191, 177); margin: 0pt; padding: 0.2em 0.4em; background: rgb(206, 223, 242) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; font-size: 120%; font-weight: bold; text-align: left; color: rgb(0, 0, 0);&amp;quot;&amp;gt;Recommended article&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;color: rgb(0, 0, 0);&amp;quot; | {{Tips}}&lt;br /&gt;
|-&lt;br /&gt;
! &amp;lt;div style=&amp;quot;border: 1px solid rgb(163, 191, 177); margin: 0pt; padding: 0.2em 0.4em; background: rgb(206, 223, 242) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; font-size: 120%; font-weight: bold; text-align: left; color: rgb(0, 0, 0);&amp;quot;&amp;gt;Drug related News&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;color: rgb(0, 0, 0);&amp;quot; | {{Aktuellt}}&lt;br /&gt;
|-&lt;br /&gt;
! &amp;lt;div style=&amp;quot;border: 1px solid rgb(163, 191, 177); margin: 0pt; padding: 0.2em 0.4em; background: rgb(206, 223, 242) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; font-size: 120%; font-weight: bold; text-align: left; color: rgb(0, 0, 0);&amp;quot;&amp;gt;Did you know that this drug...&amp;lt;/div&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;color: rgb(0, 0, 0);&amp;quot; | {{Visste du att}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Swedish_flag.gif‎|link=sv:Huvudsida]] på svenska&lt;br /&gt;
[[Image:Spanish.jpg‎|link=es:Página_Principal]] en español&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:TableTools&amp;diff=11272</id>
		<title>Module:TableTools</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:TableTools&amp;diff=11272"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;------------------------------------------------------------------------------------&lt;br /&gt;
--                                   TableTools                                   --&lt;br /&gt;
--                                                                                --&lt;br /&gt;
-- This module includes a number of functions for dealing with Lua tables.        --&lt;br /&gt;
-- It is a meta-module, meant to be called from other Lua modules, and should not --&lt;br /&gt;
-- be called directly from #invoke.                                               --&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local libraryUtil = require(&#039;libraryUtil&#039;)&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
-- Define often-used variables and functions.&lt;br /&gt;
local floor = math.floor&lt;br /&gt;
local infinity = math.huge&lt;br /&gt;
local checkType = libraryUtil.checkType&lt;br /&gt;
local checkTypeMulti = libraryUtil.checkTypeMulti&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- isPositiveInteger&lt;br /&gt;
--&lt;br /&gt;
-- This function returns true if the given value is a positive integer, and false&lt;br /&gt;
-- if not. Although it doesn&#039;t operate on tables, it is included here as it is&lt;br /&gt;
-- useful for determining whether a given table key is in the array part or the&lt;br /&gt;
-- hash part of a table.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.isPositiveInteger(v)&lt;br /&gt;
	return type(v) == &#039;number&#039; and v &amp;gt;= 1 and floor(v) == v and v &amp;lt; infinity&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- isNan&lt;br /&gt;
--&lt;br /&gt;
-- This function returns true if the given number is a NaN value, and false if&lt;br /&gt;
-- not. Although it doesn&#039;t operate on tables, it is included here as it is useful&lt;br /&gt;
-- for determining whether a value can be a valid table key. Lua will generate an&lt;br /&gt;
-- error if a NaN is used as a table key.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.isNan(v)&lt;br /&gt;
	return type(v) == &#039;number&#039; and v ~= v&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- shallowClone&lt;br /&gt;
--&lt;br /&gt;
-- This returns a clone of a table. The value returned is a new table, but all&lt;br /&gt;
-- subtables and functions are shared. Metamethods are respected, but the returned&lt;br /&gt;
-- table will have no metatable of its own.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.shallowClone(t)&lt;br /&gt;
	checkType(&#039;shallowClone&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
	local ret = {}&lt;br /&gt;
	for k, v in pairs(t) do&lt;br /&gt;
		ret[k] = v&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- removeDuplicates&lt;br /&gt;
--&lt;br /&gt;
-- This removes duplicate values from an array. Non-positive-integer keys are&lt;br /&gt;
-- ignored. The earliest value is kept, and all subsequent duplicate values are&lt;br /&gt;
-- removed, but otherwise the array order is unchanged.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.removeDuplicates(arr)&lt;br /&gt;
	checkType(&#039;removeDuplicates&#039;, 1, arr, &#039;table&#039;)&lt;br /&gt;
	local isNan = p.isNan&lt;br /&gt;
	local ret, exists = {}, {}&lt;br /&gt;
	for _, v in ipairs(arr) do&lt;br /&gt;
		if isNan(v) then&lt;br /&gt;
			-- NaNs can&#039;t be table keys, and they are also unique, so we don&#039;t need to check existence.&lt;br /&gt;
			ret[#ret + 1] = v&lt;br /&gt;
		elseif not exists[v] then&lt;br /&gt;
			ret[#ret + 1] = v&lt;br /&gt;
			exists[v] = true&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- numKeys&lt;br /&gt;
--&lt;br /&gt;
-- This takes a table and returns an array containing the numbers of any numerical&lt;br /&gt;
-- keys that have non-nil values, sorted in numerical order.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.numKeys(t)&lt;br /&gt;
	checkType(&#039;numKeys&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
	local isPositiveInteger = p.isPositiveInteger&lt;br /&gt;
	local nums = {}&lt;br /&gt;
	for k in pairs(t) do&lt;br /&gt;
		if isPositiveInteger(k) then&lt;br /&gt;
			nums[#nums + 1] = k&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	table.sort(nums)&lt;br /&gt;
	return nums&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- affixNums&lt;br /&gt;
--&lt;br /&gt;
-- This takes a table and returns an array containing the numbers of keys with the&lt;br /&gt;
-- specified prefix and suffix. For example, for the table&lt;br /&gt;
-- {a1 = &#039;foo&#039;, a3 = &#039;bar&#039;, a6 = &#039;baz&#039;} and the prefix &amp;quot;a&amp;quot;, affixNums will return&lt;br /&gt;
-- {1, 3, 6}.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.affixNums(t, prefix, suffix)&lt;br /&gt;
	checkType(&#039;affixNums&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
	checkType(&#039;affixNums&#039;, 2, prefix, &#039;string&#039;, true)&lt;br /&gt;
	checkType(&#039;affixNums&#039;, 3, suffix, &#039;string&#039;, true)&lt;br /&gt;
&lt;br /&gt;
	local function cleanPattern(s)&lt;br /&gt;
		-- Cleans a pattern so that the magic characters ()%.[]*+-?^$ are interpreted literally.&lt;br /&gt;
		return s:gsub(&#039;([%(%)%%%.%[%]%*%+%-%?%^%$])&#039;, &#039;%%%1&#039;)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	prefix = prefix or &#039;&#039;&lt;br /&gt;
	suffix = suffix or &#039;&#039;&lt;br /&gt;
	prefix = cleanPattern(prefix)&lt;br /&gt;
	suffix = cleanPattern(suffix)&lt;br /&gt;
	local pattern = &#039;^&#039; .. prefix .. &#039;([1-9]%d*)&#039; .. suffix .. &#039;$&#039;&lt;br /&gt;
&lt;br /&gt;
	local nums = {}&lt;br /&gt;
	for k in pairs(t) do&lt;br /&gt;
		if type(k) == &#039;string&#039; then&lt;br /&gt;
			local num = mw.ustring.match(k, pattern)&lt;br /&gt;
			if num then&lt;br /&gt;
				nums[#nums + 1] = tonumber(num)&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	table.sort(nums)&lt;br /&gt;
	return nums&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- numData&lt;br /&gt;
--&lt;br /&gt;
-- Given a table with keys like {&amp;quot;foo1&amp;quot;, &amp;quot;bar1&amp;quot;, &amp;quot;foo2&amp;quot;, &amp;quot;baz2&amp;quot;}, returns a table&lt;br /&gt;
-- of subtables in the format&lt;br /&gt;
-- {[1] = {foo = &#039;text&#039;, bar = &#039;text&#039;}, [2] = {foo = &#039;text&#039;, baz = &#039;text&#039;}}.&lt;br /&gt;
-- Keys that don&#039;t end with an integer are stored in a subtable named &amp;quot;other&amp;quot;. The&lt;br /&gt;
-- compress option compresses the table so that it can be iterated over with&lt;br /&gt;
-- ipairs.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.numData(t, compress)&lt;br /&gt;
	checkType(&#039;numData&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
	checkType(&#039;numData&#039;, 2, compress, &#039;boolean&#039;, true)&lt;br /&gt;
	local ret = {}&lt;br /&gt;
	for k, v in pairs(t) do&lt;br /&gt;
		local prefix, num = mw.ustring.match(tostring(k), &#039;^([^0-9]*)([1-9][0-9]*)$&#039;)&lt;br /&gt;
		if num then&lt;br /&gt;
			num = tonumber(num)&lt;br /&gt;
			local subtable = ret[num] or {}&lt;br /&gt;
			if prefix == &#039;&#039; then&lt;br /&gt;
				-- Positional parameters match the blank string; put them at the start of the subtable instead.&lt;br /&gt;
				prefix = 1&lt;br /&gt;
			end&lt;br /&gt;
			subtable[prefix] = v&lt;br /&gt;
			ret[num] = subtable&lt;br /&gt;
		else&lt;br /&gt;
			local subtable = ret.other or {}&lt;br /&gt;
			subtable[k] = v&lt;br /&gt;
			ret.other = subtable&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	if compress then&lt;br /&gt;
		local other = ret.other&lt;br /&gt;
		ret = p.compressSparseArray(ret)&lt;br /&gt;
		ret.other = other&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- compressSparseArray&lt;br /&gt;
--&lt;br /&gt;
-- This takes an array with one or more nil values, and removes the nil values&lt;br /&gt;
-- while preserving the order, so that the array can be safely traversed with&lt;br /&gt;
-- ipairs.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.compressSparseArray(t)&lt;br /&gt;
	checkType(&#039;compressSparseArray&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
	local ret = {}&lt;br /&gt;
	local nums = p.numKeys(t)&lt;br /&gt;
	for _, num in ipairs(nums) do&lt;br /&gt;
		ret[#ret + 1] = t[num]&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- sparseIpairs&lt;br /&gt;
--&lt;br /&gt;
-- This is an iterator for sparse arrays. It can be used like ipairs, but can&lt;br /&gt;
-- handle nil values.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.sparseIpairs(t)&lt;br /&gt;
	checkType(&#039;sparseIpairs&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
	local nums = p.numKeys(t)&lt;br /&gt;
	local i = 0&lt;br /&gt;
	local lim = #nums&lt;br /&gt;
	return function ()&lt;br /&gt;
		i = i + 1&lt;br /&gt;
		if i &amp;lt;= lim then&lt;br /&gt;
			local key = nums[i]&lt;br /&gt;
			return key, t[key]&lt;br /&gt;
		else&lt;br /&gt;
			return nil, nil&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- size&lt;br /&gt;
--&lt;br /&gt;
-- This returns the size of a key/value pair table. It will also work on arrays,&lt;br /&gt;
-- but for arrays it is more efficient to use the # operator.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.size(t)&lt;br /&gt;
	checkType(&#039;size&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
	local i = 0&lt;br /&gt;
	for _ in pairs(t) do&lt;br /&gt;
		i = i + 1&lt;br /&gt;
	end&lt;br /&gt;
	return i&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function defaultKeySort(item1, item2)&lt;br /&gt;
	-- &amp;quot;number&amp;quot; &amp;lt; &amp;quot;string&amp;quot;, so numbers will be sorted before strings.&lt;br /&gt;
	local type1, type2 = type(item1), type(item2)&lt;br /&gt;
	if type1 ~= type2 then&lt;br /&gt;
		return type1 &amp;lt; type2&lt;br /&gt;
	elseif type1 == &#039;table&#039; or type1 == &#039;boolean&#039; or type1 == &#039;function&#039; then&lt;br /&gt;
		return tostring(item1) &amp;lt; tostring(item2)&lt;br /&gt;
	else&lt;br /&gt;
		return item1 &amp;lt; item2&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- keysToList&lt;br /&gt;
--&lt;br /&gt;
-- Returns an array of the keys in a table, sorted using either a default&lt;br /&gt;
-- comparison function or a custom keySort function.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.keysToList(t, keySort, checked)&lt;br /&gt;
	if not checked then&lt;br /&gt;
		checkType(&#039;keysToList&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
		checkTypeMulti(&#039;keysToList&#039;, 2, keySort, {&#039;function&#039;, &#039;boolean&#039;, &#039;nil&#039;})&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local arr = {}&lt;br /&gt;
	local index = 1&lt;br /&gt;
	for k in pairs(t) do&lt;br /&gt;
		arr[index] = k&lt;br /&gt;
		index = index + 1&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if keySort ~= false then&lt;br /&gt;
		keySort = type(keySort) == &#039;function&#039; and keySort or defaultKeySort&lt;br /&gt;
		table.sort(arr, keySort)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return arr&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- sortedPairs&lt;br /&gt;
--&lt;br /&gt;
-- Iterates through a table, with the keys sorted using the keysToList function.&lt;br /&gt;
-- If there are only numerical keys, sparseIpairs is probably more efficient.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.sortedPairs(t, keySort)&lt;br /&gt;
	checkType(&#039;sortedPairs&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
	checkType(&#039;sortedPairs&#039;, 2, keySort, &#039;function&#039;, true)&lt;br /&gt;
&lt;br /&gt;
	local arr = p.keysToList(t, keySort, true)&lt;br /&gt;
&lt;br /&gt;
	local i = 0&lt;br /&gt;
	return function ()&lt;br /&gt;
		i = i + 1&lt;br /&gt;
		local key = arr[i]&lt;br /&gt;
		if key ~= nil then&lt;br /&gt;
			return key, t[key]&lt;br /&gt;
		else&lt;br /&gt;
			return nil, nil&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- isArray&lt;br /&gt;
--&lt;br /&gt;
-- Returns true if the given value is a table and all keys are consecutive&lt;br /&gt;
-- integers starting at 1.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.isArray(v)&lt;br /&gt;
	if type(v) ~= &#039;table&#039; then&lt;br /&gt;
		return false&lt;br /&gt;
	end&lt;br /&gt;
	local i = 0&lt;br /&gt;
	for _ in pairs(v) do&lt;br /&gt;
		i = i + 1&lt;br /&gt;
		if v[i] == nil then&lt;br /&gt;
			return false&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return true&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- isArrayLike&lt;br /&gt;
--&lt;br /&gt;
-- Returns true if the given value is iterable and all keys are consecutive&lt;br /&gt;
-- integers starting at 1.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.isArrayLike(v)&lt;br /&gt;
	if not pcall(pairs, v) then&lt;br /&gt;
		return false&lt;br /&gt;
	end&lt;br /&gt;
	local i = 0&lt;br /&gt;
	for _ in pairs(v) do&lt;br /&gt;
		i = i + 1&lt;br /&gt;
		if v[i] == nil then&lt;br /&gt;
			return false&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return true&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- invert&lt;br /&gt;
--&lt;br /&gt;
-- Transposes the keys and values in an array. For example, {&amp;quot;a&amp;quot;, &amp;quot;b&amp;quot;, &amp;quot;c&amp;quot;} -&amp;gt;&lt;br /&gt;
-- {a = 1, b = 2, c = 3}. Duplicates are not supported (result values refer to&lt;br /&gt;
-- the index of the last duplicate) and NaN values are ignored.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.invert(arr)&lt;br /&gt;
	checkType(&amp;quot;invert&amp;quot;, 1, arr, &amp;quot;table&amp;quot;)&lt;br /&gt;
	local isNan = p.isNan&lt;br /&gt;
	local map = {}&lt;br /&gt;
	for i, v in ipairs(arr) do&lt;br /&gt;
		if not isNan(v) then&lt;br /&gt;
			map[v] = i&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return map&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- listToSet&lt;br /&gt;
--&lt;br /&gt;
-- Creates a set from the array part of the table. Indexing the set by any of the&lt;br /&gt;
-- values of the array returns true. For example, {&amp;quot;a&amp;quot;, &amp;quot;b&amp;quot;, &amp;quot;c&amp;quot;} -&amp;gt;&lt;br /&gt;
-- {a = true, b = true, c = true}. NaN values are ignored as Lua considers them&lt;br /&gt;
-- never equal to any value (including other NaNs or even themselves).&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.listToSet(arr)&lt;br /&gt;
	checkType(&amp;quot;listToSet&amp;quot;, 1, arr, &amp;quot;table&amp;quot;)&lt;br /&gt;
	local isNan = p.isNan&lt;br /&gt;
	local set = {}&lt;br /&gt;
	for _, v in ipairs(arr) do&lt;br /&gt;
		if not isNan(v) then&lt;br /&gt;
			set[v] = true&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return set&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- deepCopy&lt;br /&gt;
--&lt;br /&gt;
-- Recursive deep copy function. Preserves identities of subtables.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
local function _deepCopy(orig, includeMetatable, already_seen)&lt;br /&gt;
	if type(orig) ~= &amp;quot;table&amp;quot; then&lt;br /&gt;
		return orig&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- already_seen stores copies of tables indexed by the original table.&lt;br /&gt;
	local copy = already_seen[orig]&lt;br /&gt;
	if copy ~= nil then&lt;br /&gt;
		return copy&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	copy = {}&lt;br /&gt;
	already_seen[orig] = copy -- memoize before any recursion, to avoid infinite loops&lt;br /&gt;
	&lt;br /&gt;
	for orig_key, orig_value in pairs(orig) do&lt;br /&gt;
		copy[_deepCopy(orig_key, includeMetatable, already_seen)] = _deepCopy(orig_value, includeMetatable, already_seen)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if includeMetatable then&lt;br /&gt;
		local mt = getmetatable(orig)&lt;br /&gt;
		if mt ~= nil then&lt;br /&gt;
			setmetatable(copy, _deepCopy(mt, true, already_seen))&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return copy&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.deepCopy(orig, noMetatable, already_seen)&lt;br /&gt;
	checkType(&amp;quot;deepCopy&amp;quot;, 3, already_seen, &amp;quot;table&amp;quot;, true)&lt;br /&gt;
	return _deepCopy(orig, not noMetatable, already_seen or {})&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- sparseConcat&lt;br /&gt;
--&lt;br /&gt;
-- Concatenates all values in the table that are indexed by a number, in order.&lt;br /&gt;
-- sparseConcat{a, nil, c, d}  =&amp;gt;  &amp;quot;acd&amp;quot;&lt;br /&gt;
-- sparseConcat{nil, b, c, d}  =&amp;gt;  &amp;quot;bcd&amp;quot;&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.sparseConcat(t, sep, i, j)&lt;br /&gt;
	local arr = {}&lt;br /&gt;
&lt;br /&gt;
	local arr_i = 0&lt;br /&gt;
	for _, v in p.sparseIpairs(t) do&lt;br /&gt;
		arr_i = arr_i + 1&lt;br /&gt;
		arr[arr_i] = v&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return table.concat(arr, sep, i, j)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- length&lt;br /&gt;
--&lt;br /&gt;
-- Finds the length of an array, or of a quasi-array with keys such as &amp;quot;data1&amp;quot;,&lt;br /&gt;
-- &amp;quot;data2&amp;quot;, etc., using an exponential search algorithm. It is similar to the&lt;br /&gt;
-- operator #, but may return a different value when there are gaps in the array&lt;br /&gt;
-- portion of the table. Intended to be used on data loaded with mw.loadData. For&lt;br /&gt;
-- other tables, use #.&lt;br /&gt;
-- Note: #frame.args in frame object always be set to 0, regardless of  the number&lt;br /&gt;
-- of unnamed template parameters, so use this function for frame.args.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.length(t, prefix)&lt;br /&gt;
	-- requiring module inline so that [[Module:Exponential search]] which is&lt;br /&gt;
	-- only needed by this one function doesn&#039;t get millions of transclusions&lt;br /&gt;
	local expSearch = require(&amp;quot;Module:Exponential search&amp;quot;)&lt;br /&gt;
	checkType(&#039;length&#039;, 1, t, &#039;table&#039;)&lt;br /&gt;
	checkType(&#039;length&#039;, 2, prefix, &#039;string&#039;, true)&lt;br /&gt;
	return expSearch(function (i)&lt;br /&gt;
		local key&lt;br /&gt;
		if prefix then&lt;br /&gt;
			key = prefix .. tostring(i)&lt;br /&gt;
		else&lt;br /&gt;
			key = i&lt;br /&gt;
		end&lt;br /&gt;
		return t[key] ~= nil&lt;br /&gt;
	end) or 0&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- inArray&lt;br /&gt;
--&lt;br /&gt;
-- Returns true if searchElement is a member of the array, and false otherwise.&lt;br /&gt;
-- Equivalent to JavaScript array.includes(searchElement) or&lt;br /&gt;
-- array.includes(searchElement, fromIndex), except fromIndex is 1 indexed&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.inArray(array, searchElement, fromIndex)&lt;br /&gt;
	checkType(&amp;quot;inArray&amp;quot;, 1, array, &amp;quot;table&amp;quot;)&lt;br /&gt;
	-- if searchElement is nil, error?&lt;br /&gt;
&lt;br /&gt;
	fromIndex = tonumber(fromIndex)&lt;br /&gt;
	if fromIndex then&lt;br /&gt;
		if (fromIndex &amp;lt; 0) then&lt;br /&gt;
			fromIndex = #array + fromIndex + 1&lt;br /&gt;
		end&lt;br /&gt;
		if fromIndex &amp;lt; 1 then fromIndex = 1 end&lt;br /&gt;
		for _, v in ipairs({unpack(array, fromIndex)}) do&lt;br /&gt;
			if v == searchElement then&lt;br /&gt;
				return true&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		for _, v in pairs(array) do&lt;br /&gt;
			if v == searchElement then&lt;br /&gt;
				return true&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return false&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- merge&lt;br /&gt;
--&lt;br /&gt;
-- Given the arrays, returns an array containing the elements of each input array&lt;br /&gt;
-- in sequence.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.merge(...)&lt;br /&gt;
	local arrays = {...}&lt;br /&gt;
	local ret = {}&lt;br /&gt;
	for i, arr in ipairs(arrays) do&lt;br /&gt;
		checkType(&#039;merge&#039;, i, arr, &#039;table&#039;)&lt;br /&gt;
		for _, v in ipairs(arr) do&lt;br /&gt;
			ret[#ret + 1] = v&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
-- extend&lt;br /&gt;
--&lt;br /&gt;
-- Extends the first array in place by appending all elements from the second&lt;br /&gt;
-- array.&lt;br /&gt;
------------------------------------------------------------------------------------&lt;br /&gt;
function p.extend(arr1, arr2)&lt;br /&gt;
	checkType(&#039;extend&#039;, 1, arr1, &#039;table&#039;)&lt;br /&gt;
	checkType(&#039;extend&#039;, 2, arr2, &#039;table&#039;)&lt;br /&gt;
&lt;br /&gt;
	for _, v in ipairs(arr2) do&lt;br /&gt;
		arr1[#arr1 + 1] = v&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Redirect_hatnote&amp;diff=11270</id>
		<title>Module:Redirect hatnote</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Redirect_hatnote&amp;diff=11270"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;--[[&lt;br /&gt;
-- This module produces a &amp;quot;redirect&amp;quot; hatnote. It looks like this:&lt;br /&gt;
-- &#039;&amp;quot;X&amp;quot; redirects here. For other uses, see Y.&#039;&lt;br /&gt;
-- It implements the {{redirect}} template.&lt;br /&gt;
--]]&lt;br /&gt;
&lt;br /&gt;
local mHatnote = require(&#039;Module:Hatnote&#039;)&lt;br /&gt;
local libraryUtil = require(&#039;libraryUtil&#039;)&lt;br /&gt;
local checkType = libraryUtil.checkType&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
local function getTitle(...)&lt;br /&gt;
	local success, titleObj = pcall(mw.title.new, ...)&lt;br /&gt;
	if success then&lt;br /&gt;
		return titleObj&lt;br /&gt;
	else&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.redirect(frame)&lt;br /&gt;
	-- Get the args table and work out the maximum arg key.&lt;br /&gt;
	local origArgs = frame:getParent().args&lt;br /&gt;
	local args = {}&lt;br /&gt;
	local maxArg = 0&lt;br /&gt;
	for k, v in pairs(origArgs) do&lt;br /&gt;
		if type(k) == &#039;number&#039; and k &amp;gt; maxArg then&lt;br /&gt;
			maxArg = k&lt;br /&gt;
		end&lt;br /&gt;
		v = v:match(&#039;^%s*(.-)%s*$&#039;) -- Trim whitespace&lt;br /&gt;
		if v ~= &#039;&#039; then&lt;br /&gt;
			args[k] = v&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Return an error if no redirect was specified.&lt;br /&gt;
	local redirect = args[1]&lt;br /&gt;
	if not redirect then&lt;br /&gt;
		return mHatnote.makeWikitextError(&lt;br /&gt;
			&#039;no redirect specified&#039;,&lt;br /&gt;
			&#039;Template:Redirect#Errors&#039;,&lt;br /&gt;
			args.category&lt;br /&gt;
		)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Create the data table.&lt;br /&gt;
	local data = {}&lt;br /&gt;
	local iArg = 0&lt;br /&gt;
	local iData = 1&lt;br /&gt;
	repeat&lt;br /&gt;
		iArg = iArg + 2&lt;br /&gt;
		local useTable = data[iData] or {}&lt;br /&gt;
		local pages = useTable.pages or {}&lt;br /&gt;
		local use = args[iArg]&lt;br /&gt;
		local page = args[iArg + 1]&lt;br /&gt;
		local nextUse = args[iArg + 2]&lt;br /&gt;
		pages[#pages + 1] = page&lt;br /&gt;
		useTable.pages = pages&lt;br /&gt;
		if use ~= &#039;and&#039; then&lt;br /&gt;
			useTable.use = use&lt;br /&gt;
		end&lt;br /&gt;
		data[iData] = useTable&lt;br /&gt;
		if nextUse ~= &#039;and&#039; then&lt;br /&gt;
			iData = iData + 1&lt;br /&gt;
		end&lt;br /&gt;
	until iArg &amp;gt;= maxArg - 1&lt;br /&gt;
&lt;br /&gt;
	-- Create the options table.&lt;br /&gt;
	local options = {}&lt;br /&gt;
	options.selfref = args.selfref&lt;br /&gt;
		&lt;br /&gt;
	return p._redirect(redirect, data, options)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function formatUseTable(useTable, isFirst, redirect)&lt;br /&gt;
	-- Formats one use table. Use tables are the tables inside the data array.&lt;br /&gt;
	-- Each one corresponds to one use. (A use might be the word &amp;quot;cats&amp;quot; in the&lt;br /&gt;
	-- phrase &amp;quot;For cats, see [[Felines]]&amp;quot;.)&lt;br /&gt;
	-- Returns a string, or nil if no use was specified.&lt;br /&gt;
	-- The isFirst parameter is used to apply special formatting for the first&lt;br /&gt;
	-- table in the data array. If isFirst is specified, the redirect parameter&lt;br /&gt;
	useTable = useTable or {}&lt;br /&gt;
	local use&lt;br /&gt;
	if isFirst then&lt;br /&gt;
		use = useTable.use or &#039;other uses&#039;&lt;br /&gt;
	elseif not useTable.use then&lt;br /&gt;
		return nil&lt;br /&gt;
	elseif tonumber(useTable.use) == 1 then&lt;br /&gt;
		use = &#039;other uses&#039;&lt;br /&gt;
	else&lt;br /&gt;
		use = useTable.use&lt;br /&gt;
	end&lt;br /&gt;
	local pages = useTable.pages or {}&lt;br /&gt;
	if isFirst then&lt;br /&gt;
		redirect = redirect or error(&lt;br /&gt;
			&#039;isFirst was set in formatUseTable, but no redirect was supplied&#039;,&lt;br /&gt;
			2&lt;br /&gt;
		)&lt;br /&gt;
		pages[1] = pages[1] or redirect .. &#039; (disambiguation)&#039;&lt;br /&gt;
	else&lt;br /&gt;
		pages[1] = pages[1] or useTable.use .. &#039; (disambiguation)&#039;&lt;br /&gt;
	end&lt;br /&gt;
	pages = mHatnote.formatPages(unpack(pages))&lt;br /&gt;
	pages = mw.text.listToText(pages)&lt;br /&gt;
	return string.format(&lt;br /&gt;
		&#039;For %s, see %s.&#039;,&lt;br /&gt;
		use,&lt;br /&gt;
		pages&lt;br /&gt;
	)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._redirect(redirect, data, options, currentTitle, redirectTitle, targetTitle)&lt;br /&gt;
	-- Validate the input. Don&#039;t bother checking currentTitle, redirectTitle or&lt;br /&gt;
	-- targetTitle, as they are only used in testing.&lt;br /&gt;
	checkType(&#039;_redirect&#039;, 1, redirect, &#039;string&#039;)&lt;br /&gt;
	checkType(&#039;_redirect&#039;, 2, data, &#039;table&#039;, true)&lt;br /&gt;
	checkType(&#039;_redirect&#039;, 3, options, &#039;table&#039;, true)&lt;br /&gt;
	data = data or {}&lt;br /&gt;
	options = options or {}&lt;br /&gt;
	currentTitle = currentTitle or mw.title.getCurrentTitle()&lt;br /&gt;
&lt;br /&gt;
	-- Generate the text.&lt;br /&gt;
	local text = {}&lt;br /&gt;
	text[#text + 1] = &#039;&amp;quot;&#039; .. redirect .. &#039;&amp;quot; redirects here.&#039;&lt;br /&gt;
	text[#text + 1] = formatUseTable(data[1] or {}, true, redirect)&lt;br /&gt;
	if data[1] and data[1].use and data[1].use ~= &#039;other uses&#039; then&lt;br /&gt;
		for i = 2, #data do&lt;br /&gt;
			text[#text + 1] = formatUseTable(data[i] or {}, false)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	text = table.concat(text, &#039; &#039;)&lt;br /&gt;
	&lt;br /&gt;
	-- Generate the tracking category.&lt;br /&gt;
	-- We don&#039;t need a tracking category if the template invocation has been&lt;br /&gt;
	-- copied directly from the docs, or if we aren&#039;t in mainspace.&lt;br /&gt;
	local category&lt;br /&gt;
	if not redirect:find(&#039;^REDIRECT%d*$&#039;) and redirect ~= &#039;TERM&#039; -- &lt;br /&gt;
		and currentTitle.namespace == 0&lt;br /&gt;
	then&lt;br /&gt;
		redirectTitle = redirectTitle or getTitle(redirect)&lt;br /&gt;
		if not redirectTitle or not redirectTitle.exists then&lt;br /&gt;
			category = &#039;Missing redirects&#039;&lt;br /&gt;
		elseif not redirectTitle.isRedirect then&lt;br /&gt;
			category = &#039;Invalid redirects&#039;&lt;br /&gt;
		else&lt;br /&gt;
			local mRedirect = require(&#039;Module:Redirect&#039;)&lt;br /&gt;
			local target = mRedirect.getTarget(redirectTitle)&lt;br /&gt;
			targetTitle = targetTitle or target and getTitle(target)&lt;br /&gt;
			if targetTitle and targetTitle ~= currentTitle then&lt;br /&gt;
				category = &#039;Invalid redirects&#039;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	category = category and string.format(&#039;[[Category:%s]]&#039;, category) or &#039;&#039;&lt;br /&gt;
&lt;br /&gt;
	-- Generate the options to pass to [[Module:Hatnote]].&lt;br /&gt;
	local mhOptions = {}&lt;br /&gt;
	if currentTitle.namespace == 0&lt;br /&gt;
		and redirectTitle and redirectTitle.namespace ~= 0&lt;br /&gt;
	then&lt;br /&gt;
		-- We are on a mainspace page, and the hatnote starts with something&lt;br /&gt;
		-- like &amp;quot;Wikipedia:Foo redirects here&amp;quot;, so automatically label it as a&lt;br /&gt;
		-- self-reference.&lt;br /&gt;
		mhOptions.selfref = true&lt;br /&gt;
	else&lt;br /&gt;
		mhOptions.selfref = options.selfref&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return mHatnote._hatnote(text, mhOptions) .. category&lt;br /&gt;
end&lt;br /&gt;
 &lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:No_globals&amp;diff=11268</id>
		<title>Module:No globals</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:No_globals&amp;diff=11268"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;local mt = getmetatable(_G) or {}&lt;br /&gt;
function mt.__index (t, k)&lt;br /&gt;
	if k ~= &#039;arg&#039; then&lt;br /&gt;
		error(&#039;Tried to read nil global &#039; .. tostring(k), 2)&lt;br /&gt;
	end&lt;br /&gt;
	return nil&lt;br /&gt;
end&lt;br /&gt;
function mt.__newindex(t, k, v)&lt;br /&gt;
	if k ~= &#039;arg&#039; then&lt;br /&gt;
		error(&#039;Tried to write global &#039; .. tostring(k), 2)&lt;br /&gt;
	end&lt;br /&gt;
	rawset(t, k, v)&lt;br /&gt;
end&lt;br /&gt;
setmetatable(_G, mt)&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Navbox&amp;diff=11266</id>
		<title>Module:Navbox</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Navbox&amp;diff=11266"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;require(&#039;strict&#039;)&lt;br /&gt;
local p = {}&lt;br /&gt;
local cfg = mw.loadData(&#039;Module:Navbox/configuration&#039;)&lt;br /&gt;
local inArray = require(&amp;quot;Module:TableTools&amp;quot;).inArray&lt;br /&gt;
local getArgs -- lazily initialized&lt;br /&gt;
local hiding_templatestyles = {} &lt;br /&gt;
&lt;br /&gt;
-- global passthrough variables&lt;br /&gt;
local passthrough = {&lt;br /&gt;
	[cfg.arg.above]=true,[cfg.arg.aboveclass]=true,[cfg.arg.abovestyle]=true,&lt;br /&gt;
	[cfg.arg.basestyle]=true,&lt;br /&gt;
	[cfg.arg.below]=true,[cfg.arg.belowclass]=true,[cfg.arg.belowstyle]=true,&lt;br /&gt;
	[cfg.arg.bodyclass]=true,&lt;br /&gt;
	[cfg.arg.groupclass]=true,&lt;br /&gt;
	[cfg.arg.image]=true,[cfg.arg.imageclass]=true,[cfg.arg.imagestyle]=true,&lt;br /&gt;
	[cfg.arg.imageleft]=true,[cfg.arg.imageleftstyle]=true,&lt;br /&gt;
	[cfg.arg.listclass]=true,&lt;br /&gt;
	[cfg.arg.name]=true,&lt;br /&gt;
	[cfg.arg.navbar]=true,&lt;br /&gt;
	[cfg.arg.state]=true,&lt;br /&gt;
	[cfg.arg.title]=true,[cfg.arg.titleclass]=true,[cfg.arg.titlestyle]=true,&lt;br /&gt;
	argHash=true&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
-- helper functions&lt;br /&gt;
local andnum = function(s, n) return string.format(cfg.arg[s .. &#039;_and_num&#039;], n) end&lt;br /&gt;
local isblank = function(v) return (v or &#039;&#039;) == &#039;&#039; end&lt;br /&gt;
&lt;br /&gt;
local function concatstrings(s)&lt;br /&gt;
	local r = table.concat(s, &#039;&#039;)&lt;br /&gt;
	if r:match(&#039;^%s*$&#039;) then return nil end&lt;br /&gt;
	return r&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function concatstyles(s)&lt;br /&gt;
	local r = &#039;&#039;&lt;br /&gt;
	for _, v in ipairs(s) do&lt;br /&gt;
		v = mw.text.trim(v, &amp;quot;%s;&amp;quot;)&lt;br /&gt;
		if not isblank(v) then r = r .. v .. &#039;;&#039; end&lt;br /&gt;
	end&lt;br /&gt;
	if isblank(r) then return nil end&lt;br /&gt;
	return r&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function getSubgroup(args, listnum, listText, prefix)&lt;br /&gt;
	local subArgs = {&lt;br /&gt;
		[cfg.arg.border] = cfg.keyword.border_subgroup,&lt;br /&gt;
		[cfg.arg.navbar] = cfg.keyword.navbar_plain,&lt;br /&gt;
		argHash = 0&lt;br /&gt;
	}&lt;br /&gt;
	local hasSubArgs = false&lt;br /&gt;
	local subgroups_and_num = prefix and {prefix} or cfg.arg.subgroups_and_num&lt;br /&gt;
	for k, v in pairs(args) do&lt;br /&gt;
		k = tostring(k)&lt;br /&gt;
		for _, w in ipairs(subgroups_and_num) do&lt;br /&gt;
			w = string.format(w, listnum) .. &amp;quot;_&amp;quot;&lt;br /&gt;
			if (#k &amp;gt; #w) and (k:sub(1, #w) == w) then&lt;br /&gt;
				subArgs[k:sub(#w + 1)] = v&lt;br /&gt;
				hasSubArgs = true&lt;br /&gt;
				subArgs.argHash = subArgs.argHash + (v and #v or 0)&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return hasSubArgs and p._navbox(subArgs) or listText&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Main functions&lt;br /&gt;
function p._navbox(args)&lt;br /&gt;
	if args.type == cfg.keyword.with_collapsible_groups then&lt;br /&gt;
		return p._withCollapsibleGroups(args)&lt;br /&gt;
	elseif args.type == cfg.keyword.with_columns then&lt;br /&gt;
		return p._withColumns(args)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function striped(wikitext, border)&lt;br /&gt;
		-- Return wikitext with markers replaced for odd/even striping.&lt;br /&gt;
		-- Child (subgroup) navboxes are flagged with a category that is removed&lt;br /&gt;
		-- by parent navboxes. The result is that the category shows all pages&lt;br /&gt;
		-- where a child navbox is not contained in a parent navbox.&lt;br /&gt;
		local orphanCat = cfg.category.orphan&lt;br /&gt;
		if border == cfg.keyword.border_subgroup and args[cfg.arg.orphan] ~= cfg.keyword.orphan_yes then&lt;br /&gt;
			-- No change; striping occurs in outermost navbox.&lt;br /&gt;
			return wikitext .. orphanCat&lt;br /&gt;
		end&lt;br /&gt;
		local first, second = cfg.class.navbox_odd_part, cfg.class.navbox_even_part&lt;br /&gt;
		if args[cfg.arg.evenodd] then&lt;br /&gt;
			if args[cfg.arg.evenodd] == cfg.keyword.evenodd_swap then&lt;br /&gt;
				first, second = second, first&lt;br /&gt;
			else&lt;br /&gt;
				first = args[cfg.arg.evenodd]&lt;br /&gt;
				second = first&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		local changer&lt;br /&gt;
		if first == second then&lt;br /&gt;
			changer = first&lt;br /&gt;
		else&lt;br /&gt;
			local index = 0&lt;br /&gt;
			changer = function (code)&lt;br /&gt;
				if code == &#039;0&#039; then&lt;br /&gt;
					-- Current occurrence is for a group before a nested table.&lt;br /&gt;
					-- Set it to first as a valid although pointless class.&lt;br /&gt;
					-- The next occurrence will be the first row after a title&lt;br /&gt;
					-- in a subgroup and will also be first.&lt;br /&gt;
					index = 0&lt;br /&gt;
					return first&lt;br /&gt;
				end&lt;br /&gt;
				index = index + 1&lt;br /&gt;
				return index % 2 == 1 and first or second&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		local regex = orphanCat:gsub(&#039;([%[%]])&#039;, &#039;%%%1&#039;)&lt;br /&gt;
		return (wikitext:gsub(regex, &#039;&#039;):gsub(cfg.marker.regex, changer)) -- () omits gsub count&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function processItem(item, nowrapitems)&lt;br /&gt;
		if item:sub(1, 2) == &#039;{|&#039; then&lt;br /&gt;
			-- Applying nowrap to lines in a table does not make sense.&lt;br /&gt;
			-- Add newlines to compensate for trim of x in |parm=x in a template.&lt;br /&gt;
			return &#039;\n&#039; .. item .. &#039;\n&#039;&lt;br /&gt;
		end&lt;br /&gt;
		if nowrapitems == cfg.keyword.nowrapitems_yes then&lt;br /&gt;
			local lines = {}&lt;br /&gt;
			for line in (item .. &#039;\n&#039;):gmatch(&#039;([^\n]*)\n&#039;) do&lt;br /&gt;
				local prefix, content = line:match(&#039;^([*:;#]+)%s*(.*)&#039;)&lt;br /&gt;
				if prefix and not content:match(cfg.pattern.nowrap) then&lt;br /&gt;
					line = string.format(cfg.nowrap_item, prefix, content)&lt;br /&gt;
				end&lt;br /&gt;
				table.insert(lines, line)&lt;br /&gt;
			end&lt;br /&gt;
			item = table.concat(lines, &#039;\n&#039;)&lt;br /&gt;
		end&lt;br /&gt;
		if item:match(&#039;^[*:;#]&#039;) then&lt;br /&gt;
			return &#039;\n&#039; .. item .. &#039;\n&#039;&lt;br /&gt;
		end&lt;br /&gt;
		return item&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function has_navbar()&lt;br /&gt;
		return args[cfg.arg.navbar] ~= cfg.keyword.navbar_off&lt;br /&gt;
			and args[cfg.arg.navbar] ~= cfg.keyword.navbar_plain&lt;br /&gt;
			and (&lt;br /&gt;
				args[cfg.arg.name]&lt;br /&gt;
				or mw.getCurrentFrame():getParent():getTitle():gsub(cfg.pattern.sandbox, &#039;&#039;)&lt;br /&gt;
					~= cfg.pattern.navbox&lt;br /&gt;
			)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- extract text color from css, which is the only permitted inline CSS for the navbar&lt;br /&gt;
	local function extract_color(css_str)&lt;br /&gt;
		-- return nil because navbar takes its argument into mw.html which handles&lt;br /&gt;
		-- nil gracefully, removing the associated style attribute&lt;br /&gt;
		return mw.ustring.match(&#039;;&#039; .. css_str .. &#039;;&#039;, &#039;.*;%s*([Cc][Oo][Ll][Oo][Rr]%s*:%s*.-)%s*;&#039;) or nil&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function renderNavBar(titleCell)&lt;br /&gt;
		if has_navbar() then&lt;br /&gt;
			local navbar = require(&#039;Module:Navbar&#039;)._navbar&lt;br /&gt;
			titleCell:wikitext(navbar{&lt;br /&gt;
				[cfg.navbar.name] = args[cfg.arg.name],&lt;br /&gt;
				[cfg.navbar.mini] = 1,&lt;br /&gt;
				[cfg.navbar.fontstyle] = extract_color(&lt;br /&gt;
					(args[cfg.arg.basestyle] or &#039;&#039;) .. &#039;;&#039; .. (args[cfg.arg.titlestyle] or &#039;&#039;)&lt;br /&gt;
				)&lt;br /&gt;
			})&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function renderTitleRow(tbl)&lt;br /&gt;
		if not args[cfg.arg.title] then return end&lt;br /&gt;
&lt;br /&gt;
		local titleRow = tbl:tag(&#039;tr&#039;)&lt;br /&gt;
&lt;br /&gt;
		local titleCell = titleRow:tag(&#039;th&#039;):attr(&#039;scope&#039;, &#039;col&#039;)&lt;br /&gt;
&lt;br /&gt;
		local titleColspan = 2&lt;br /&gt;
		if args[cfg.arg.imageleft] then titleColspan = titleColspan + 1 end&lt;br /&gt;
		if args[cfg.arg.image] then titleColspan = titleColspan + 1 end&lt;br /&gt;
&lt;br /&gt;
		titleCell&lt;br /&gt;
			:cssText(args[cfg.arg.basestyle])&lt;br /&gt;
			:cssText(args[cfg.arg.titlestyle])&lt;br /&gt;
			:addClass(cfg.class.navbox_title)&lt;br /&gt;
			:attr(&#039;colspan&#039;, titleColspan)&lt;br /&gt;
&lt;br /&gt;
		renderNavBar(titleCell)&lt;br /&gt;
&lt;br /&gt;
		titleCell&lt;br /&gt;
			:tag(&#039;div&#039;)&lt;br /&gt;
				-- id for aria-labelledby attribute&lt;br /&gt;
				:attr(&#039;id&#039;, mw.uri.anchorEncode(args[cfg.arg.title]) .. args.argHash)&lt;br /&gt;
				:addClass(args[cfg.arg.titleclass])&lt;br /&gt;
				:css(&#039;font-size&#039;, &#039;114%&#039;)&lt;br /&gt;
				:css(&#039;margin&#039;, &#039;0 4em&#039;)&lt;br /&gt;
				:wikitext(processItem(args[cfg.arg.title]))&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function getAboveBelowColspan()&lt;br /&gt;
		local ret = 2&lt;br /&gt;
		if args[cfg.arg.imageleft] then ret = ret + 1 end&lt;br /&gt;
		if args[cfg.arg.image] then ret = ret + 1 end&lt;br /&gt;
		return ret&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function renderAboveRow(tbl)&lt;br /&gt;
		if not args[cfg.arg.above] then return end&lt;br /&gt;
&lt;br /&gt;
		tbl:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:addClass(cfg.class.navbox_abovebelow)&lt;br /&gt;
				:addClass(args[cfg.arg.aboveclass])&lt;br /&gt;
				:cssText(args[cfg.arg.basestyle])&lt;br /&gt;
				:cssText(args[cfg.arg.abovestyle])&lt;br /&gt;
				:attr(&#039;colspan&#039;, getAboveBelowColspan())&lt;br /&gt;
				:tag(&#039;div&#039;)&lt;br /&gt;
					-- id for aria-labelledby attribute, if no title&lt;br /&gt;
					:attr(&#039;id&#039;, (not args[cfg.arg.title]) and &lt;br /&gt;
						(mw.uri.anchorEncode(args[cfg.arg.above]) .. args.argHash)&lt;br /&gt;
						or nil)&lt;br /&gt;
					:wikitext(processItem(args[cfg.arg.above], args[cfg.arg.nowrapitems]))&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function renderBelowRow(tbl)&lt;br /&gt;
		if not args[cfg.arg.below] then return end&lt;br /&gt;
&lt;br /&gt;
		tbl:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:addClass(cfg.class.navbox_abovebelow)&lt;br /&gt;
				:addClass(args[cfg.arg.belowclass])&lt;br /&gt;
				:cssText(args[cfg.arg.basestyle])&lt;br /&gt;
				:cssText(args[cfg.arg.belowstyle])&lt;br /&gt;
				:attr(&#039;colspan&#039;, getAboveBelowColspan())&lt;br /&gt;
				:tag(&#039;div&#039;)&lt;br /&gt;
					:wikitext(processItem(args[cfg.arg.below], args[cfg.arg.nowrapitems]))&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function renderListRow(tbl, index, listnum, listnums_size)&lt;br /&gt;
		local row = tbl:tag(&#039;tr&#039;)&lt;br /&gt;
&lt;br /&gt;
		if index == 1 and args[cfg.arg.imageleft] then&lt;br /&gt;
			row&lt;br /&gt;
				:tag(&#039;td&#039;)&lt;br /&gt;
					:addClass(cfg.class.noviewer)&lt;br /&gt;
					:addClass(cfg.class.navbox_image)&lt;br /&gt;
					:addClass(args[cfg.arg.imageclass])&lt;br /&gt;
					:css(&#039;width&#039;, &#039;1px&#039;)               -- Minimize width&lt;br /&gt;
					:css(&#039;padding&#039;, &#039;0 2px 0 0&#039;)&lt;br /&gt;
					:cssText(args[cfg.arg.imageleftstyle])&lt;br /&gt;
					:attr(&#039;rowspan&#039;, listnums_size)&lt;br /&gt;
					:tag(&#039;div&#039;)&lt;br /&gt;
						:wikitext(processItem(args[cfg.arg.imageleft]))&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		local group_and_num = andnum(&#039;group&#039;, listnum)&lt;br /&gt;
		local groupstyle_and_num = andnum(&#039;groupstyle&#039;, listnum)&lt;br /&gt;
		if args[group_and_num] then&lt;br /&gt;
			local groupCell = row:tag(&#039;th&#039;)&lt;br /&gt;
&lt;br /&gt;
			-- id for aria-labelledby attribute, if lone group with no title or above&lt;br /&gt;
			if listnum == 1 and not (args[cfg.arg.title] or args[cfg.arg.above] or args[cfg.arg.group2]) then&lt;br /&gt;
				groupCell&lt;br /&gt;
					:attr(&#039;id&#039;, mw.uri.anchorEncode(args[cfg.arg.group1]) .. args.argHash)&lt;br /&gt;
			end&lt;br /&gt;
&lt;br /&gt;
			groupCell&lt;br /&gt;
				:attr(&#039;scope&#039;, &#039;row&#039;)&lt;br /&gt;
				:addClass(cfg.class.navbox_group)&lt;br /&gt;
				:addClass(args[cfg.arg.groupclass])&lt;br /&gt;
				:cssText(args[cfg.arg.basestyle])&lt;br /&gt;
				-- If groupwidth not specified, minimize width&lt;br /&gt;
				:css(&#039;width&#039;, args[cfg.arg.groupwidth] or &#039;1%&#039;)&lt;br /&gt;
&lt;br /&gt;
			groupCell&lt;br /&gt;
				:cssText(args[cfg.arg.groupstyle])&lt;br /&gt;
				:cssText(args[groupstyle_and_num])&lt;br /&gt;
				:wikitext(args[group_and_num])&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		local listCell = row:tag(&#039;td&#039;)&lt;br /&gt;
&lt;br /&gt;
		if args[group_and_num] then&lt;br /&gt;
			listCell&lt;br /&gt;
				:addClass(cfg.class.navbox_list_with_group)&lt;br /&gt;
		else&lt;br /&gt;
			listCell:attr(&#039;colspan&#039;, 2)&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		if not args[cfg.arg.groupwidth] then&lt;br /&gt;
			listCell:css(&#039;width&#039;, &#039;100%&#039;)&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		local rowstyle  -- usually nil so cssText(rowstyle) usually adds nothing&lt;br /&gt;
		if index % 2 == 1 then&lt;br /&gt;
			rowstyle = args[cfg.arg.oddstyle]&lt;br /&gt;
		else&lt;br /&gt;
			rowstyle = args[cfg.arg.evenstyle]&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		local list_and_num = andnum(&#039;list&#039;, listnum)&lt;br /&gt;
		local listText = inArray(cfg.keyword.subgroups, args[list_and_num])&lt;br /&gt;
			and getSubgroup(args, listnum, args[list_and_num]) or args[list_and_num]&lt;br /&gt;
&lt;br /&gt;
		local oddEven = cfg.marker.oddeven&lt;br /&gt;
		if listText:sub(1, 12) == &#039;&amp;lt;/div&amp;gt;&amp;lt;table&#039; then&lt;br /&gt;
			-- Assume list text is for a subgroup navbox so no automatic striping for this row.&lt;br /&gt;
			oddEven = listText:find(cfg.pattern.navbox_title) and cfg.marker.restart or cfg.class.navbox_odd_part&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		local liststyle_and_num = andnum(&#039;liststyle&#039;, listnum)&lt;br /&gt;
		local listclass_and_num = andnum(&#039;listclass&#039;, listnum)&lt;br /&gt;
		listCell&lt;br /&gt;
			:css(&#039;padding&#039;, &#039;0&#039;)&lt;br /&gt;
			:cssText(args[cfg.arg.liststyle])&lt;br /&gt;
			:cssText(rowstyle)&lt;br /&gt;
			:cssText(args[liststyle_and_num])&lt;br /&gt;
			:addClass(cfg.class.navbox_list)&lt;br /&gt;
			:addClass(cfg.class.navbox_part .. oddEven)&lt;br /&gt;
			:addClass(args[cfg.arg.listclass])&lt;br /&gt;
			:addClass(args[listclass_and_num])&lt;br /&gt;
			:tag(&#039;div&#039;)&lt;br /&gt;
				:css(&#039;padding&#039;,&lt;br /&gt;
					(index == 1 and args[cfg.arg.list1padding]) or args[cfg.arg.listpadding] or &#039;0 0.25em&#039;&lt;br /&gt;
				)&lt;br /&gt;
				:wikitext(processItem(listText, args[cfg.arg.nowrapitems]))&lt;br /&gt;
&lt;br /&gt;
		if index == 1 and args[cfg.arg.image] then&lt;br /&gt;
			row&lt;br /&gt;
				:tag(&#039;td&#039;)&lt;br /&gt;
					:addClass(cfg.class.noviewer)&lt;br /&gt;
					:addClass(cfg.class.navbox_image)&lt;br /&gt;
					:addClass(args[cfg.arg.imageclass])&lt;br /&gt;
					:css(&#039;width&#039;, &#039;1px&#039;)               -- Minimize width&lt;br /&gt;
					:css(&#039;padding&#039;, &#039;0 0 0 2px&#039;)&lt;br /&gt;
					:cssText(args[cfg.arg.imagestyle])&lt;br /&gt;
					:attr(&#039;rowspan&#039;, listnums_size)&lt;br /&gt;
					:tag(&#039;div&#039;)&lt;br /&gt;
						:wikitext(processItem(args[cfg.arg.image]))&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function has_list_class(htmlclass)&lt;br /&gt;
		local patterns = {&lt;br /&gt;
			&#039;^&#039; .. htmlclass .. &#039;$&#039;,&lt;br /&gt;
			&#039;%s&#039; .. htmlclass .. &#039;$&#039;,&lt;br /&gt;
			&#039;^&#039; .. htmlclass .. &#039;%s&#039;,&lt;br /&gt;
			&#039;%s&#039; .. htmlclass .. &#039;%s&#039;&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		for arg, _ in pairs(args) do&lt;br /&gt;
			if type(arg) == &#039;string&#039; and mw.ustring.find(arg, cfg.pattern.class) then&lt;br /&gt;
				for _, pattern in ipairs(patterns) do&lt;br /&gt;
					if mw.ustring.find(args[arg] or &#039;&#039;, pattern) then&lt;br /&gt;
						return true&lt;br /&gt;
					end&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		return false&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- there are a lot of list classes in the wild, so we add their TemplateStyles&lt;br /&gt;
	local function add_list_styles()&lt;br /&gt;
		local frame = mw.getCurrentFrame()&lt;br /&gt;
		local function add_list_templatestyles(htmlclass, templatestyles)&lt;br /&gt;
			if has_list_class(htmlclass) then&lt;br /&gt;
				return frame:extensionTag{&lt;br /&gt;
					name = &#039;templatestyles&#039;, args = { src = templatestyles }&lt;br /&gt;
				}&lt;br /&gt;
			else&lt;br /&gt;
				return &#039;&#039;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		local hlist_styles = add_list_templatestyles(&#039;hlist&#039;, cfg.hlist_templatestyles)&lt;br /&gt;
		local plainlist_styles = add_list_templatestyles(&#039;plainlist&#039;, cfg.plainlist_templatestyles)&lt;br /&gt;
&lt;br /&gt;
		-- a second workaround for [[phab:T303378]]&lt;br /&gt;
		-- when that issue is fixed, we can actually use has_navbar not to emit the&lt;br /&gt;
		-- tag here if we want&lt;br /&gt;
		if has_navbar() and hlist_styles == &#039;&#039; then&lt;br /&gt;
			hlist_styles = frame:extensionTag{&lt;br /&gt;
				name = &#039;templatestyles&#039;, args = { src = cfg.hlist_templatestyles }&lt;br /&gt;
			}&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- hlist -&amp;gt; plainlist is best-effort to preserve old Common.css ordering.&lt;br /&gt;
		-- this ordering is not a guarantee because most navboxes will emit only&lt;br /&gt;
		-- one of these classes [hlist_note]&lt;br /&gt;
		return hlist_styles .. plainlist_styles&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function needsHorizontalLists(border)&lt;br /&gt;
		if border == cfg.keyword.border_subgroup or args[cfg.arg.tracking] == cfg.keyword.tracking_no then&lt;br /&gt;
			return false&lt;br /&gt;
		end&lt;br /&gt;
		return not has_list_class(cfg.pattern.hlist) and not has_list_class(cfg.pattern.plainlist)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function hasBackgroundColors()&lt;br /&gt;
		for _, key in ipairs({cfg.arg.titlestyle, cfg.arg.groupstyle,&lt;br /&gt;
			cfg.arg.basestyle, cfg.arg.abovestyle, cfg.arg.belowstyle}) do&lt;br /&gt;
			if tostring(args[key]):find(&#039;background&#039;, 1, true) then&lt;br /&gt;
				return true&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		return false&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function hasBorders()&lt;br /&gt;
		for _, key in ipairs({cfg.arg.groupstyle, cfg.arg.basestyle,&lt;br /&gt;
			cfg.arg.abovestyle, cfg.arg.belowstyle}) do&lt;br /&gt;
			if tostring(args[key]):find(&#039;border&#039;, 1, true) then&lt;br /&gt;
				return true&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		return false&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function isIllegible()&lt;br /&gt;
		local styleratio = require(&#039;Module:Color contrast&#039;)._styleratio&lt;br /&gt;
		for key, style in pairs(args) do&lt;br /&gt;
			if tostring(key):match(cfg.pattern.style) then&lt;br /&gt;
				if styleratio{mw.text.unstripNoWiki(style)} &amp;lt; 4.5 then&lt;br /&gt;
					return true&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		return false&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function getTrackingCategories(border)&lt;br /&gt;
		local cats = {}&lt;br /&gt;
		if needsHorizontalLists(border) then table.insert(cats, cfg.category.horizontal_lists) end&lt;br /&gt;
		if hasBackgroundColors() then table.insert(cats, cfg.category.background_colors) end&lt;br /&gt;
		if isIllegible() then table.insert(cats, cfg.category.illegible) end&lt;br /&gt;
		if hasBorders() then table.insert(cats, cfg.category.borders) end&lt;br /&gt;
		return cats&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function renderTrackingCategories(builder, border)&lt;br /&gt;
		local title = mw.title.getCurrentTitle()&lt;br /&gt;
		if title.namespace ~= 10 then return end -- not in template space&lt;br /&gt;
		local subpage = title.subpageText&lt;br /&gt;
		if subpage == cfg.keyword.subpage_doc or subpage == cfg.keyword.subpage_sandbox&lt;br /&gt;
			or subpage == cfg.keyword.subpage_testcases then return end&lt;br /&gt;
&lt;br /&gt;
		for _, cat in ipairs(getTrackingCategories(border)) do&lt;br /&gt;
			builder:wikitext(&#039;[[Category:&#039; .. cat .. &#039;]]&#039;)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function renderMainTable(border, listnums)&lt;br /&gt;
		local tbl = mw.html.create(&#039;table&#039;)&lt;br /&gt;
			:addClass(cfg.class.nowraplinks)&lt;br /&gt;
			:addClass(args[cfg.arg.bodyclass])&lt;br /&gt;
&lt;br /&gt;
		local state = args[cfg.arg.state]&lt;br /&gt;
		if args[cfg.arg.title] and state ~= cfg.keyword.state_plain and state ~= cfg.keyword.state_off then&lt;br /&gt;
			if state == cfg.keyword.state_collapsed then&lt;br /&gt;
				state = cfg.class.collapsed&lt;br /&gt;
			end&lt;br /&gt;
			tbl&lt;br /&gt;
				:addClass(cfg.class.collapsible)&lt;br /&gt;
				:addClass(state or cfg.class.autocollapse)&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		tbl:css(&#039;border-spacing&#039;, 0)&lt;br /&gt;
		if border == cfg.keyword.border_subgroup or border == cfg.keyword.border_none then&lt;br /&gt;
			tbl&lt;br /&gt;
				:addClass(cfg.class.navbox_subgroup)&lt;br /&gt;
				:cssText(args[cfg.arg.bodystyle])&lt;br /&gt;
				:cssText(args[cfg.arg.style])&lt;br /&gt;
		else  -- regular navbox - bodystyle and style will be applied to the wrapper table&lt;br /&gt;
			tbl&lt;br /&gt;
				:addClass(cfg.class.navbox_inner)&lt;br /&gt;
				:css(&#039;background&#039;, &#039;transparent&#039;)&lt;br /&gt;
				:css(&#039;color&#039;, &#039;inherit&#039;)&lt;br /&gt;
		end&lt;br /&gt;
		tbl:cssText(args[cfg.arg.innerstyle])&lt;br /&gt;
&lt;br /&gt;
		renderTitleRow(tbl)&lt;br /&gt;
		renderAboveRow(tbl)&lt;br /&gt;
		local listnums_size = #listnums&lt;br /&gt;
		for i, listnum in ipairs(listnums) do&lt;br /&gt;
			renderListRow(tbl, i, listnum, listnums_size)&lt;br /&gt;
		end&lt;br /&gt;
		renderBelowRow(tbl)&lt;br /&gt;
&lt;br /&gt;
		return tbl&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local function add_navbox_styles(hiding_templatestyles)&lt;br /&gt;
		local frame = mw.getCurrentFrame()&lt;br /&gt;
		-- This is a lambda so that it doesn&#039;t need the frame as a parameter&lt;br /&gt;
		local function add_user_styles(templatestyles)&lt;br /&gt;
			if not isblank(templatestyles) then&lt;br /&gt;
				return frame:extensionTag{&lt;br /&gt;
					name = &#039;templatestyles&#039;, args = { src = templatestyles }&lt;br /&gt;
				}&lt;br /&gt;
			end&lt;br /&gt;
			return &#039;&#039;&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- get templatestyles. load base from config so that Lua only needs to do&lt;br /&gt;
		-- the work once of parser tag expansion&lt;br /&gt;
		local base_templatestyles = cfg.templatestyles&lt;br /&gt;
		local templatestyles = add_user_styles(args[cfg.arg.templatestyles])&lt;br /&gt;
		local child_templatestyles = add_user_styles(args[cfg.arg.child_templatestyles])&lt;br /&gt;
&lt;br /&gt;
		-- The &#039;navbox-styles&#039; div exists to wrap the styles to work around T200206&lt;br /&gt;
		-- more elegantly. Instead of combinatorial rules, this ends up being linear&lt;br /&gt;
		-- number of CSS rules.&lt;br /&gt;
		return mw.html.create(&#039;div&#039;)&lt;br /&gt;
			:addClass(cfg.class.navbox_styles)&lt;br /&gt;
			:wikitext(&lt;br /&gt;
				add_list_styles() .. -- see [hlist_note] applied to &#039;before base_templatestyles&#039;&lt;br /&gt;
				base_templatestyles ..&lt;br /&gt;
				templatestyles ..&lt;br /&gt;
				child_templatestyles ..&lt;br /&gt;
				table.concat(hiding_templatestyles)&lt;br /&gt;
			)&lt;br /&gt;
			:done()&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- work around [[phab:T303378]]&lt;br /&gt;
	-- for each arg: find all the templatestyles strip markers, insert them into a&lt;br /&gt;
	-- table. then remove all templatestyles markers from the arg&lt;br /&gt;
	local strip_marker_pattern = &#039;(\127[^\127]*UNIQ%-%-templatestyles%-%x+%-QINU[^\127]*\127)&#039;&lt;br /&gt;
	local argHash = 0&lt;br /&gt;
	for k, arg in pairs(args) do&lt;br /&gt;
		if type(arg) == &#039;string&#039; then&lt;br /&gt;
			for marker in string.gfind(arg, strip_marker_pattern) do&lt;br /&gt;
				table.insert(hiding_templatestyles, marker)&lt;br /&gt;
			end&lt;br /&gt;
			argHash = argHash + #arg&lt;br /&gt;
			args[k] = string.gsub(arg, strip_marker_pattern, &#039;&#039;)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	if not args.argHash then args.argHash = argHash end&lt;br /&gt;
&lt;br /&gt;
	local listnums = {}&lt;br /&gt;
&lt;br /&gt;
	for k, _ in pairs(args) do&lt;br /&gt;
		if type(k) == &#039;string&#039; then&lt;br /&gt;
			local listnum = k:match(cfg.pattern.listnum)&lt;br /&gt;
			if listnum and args[andnum(&#039;list&#039;, tonumber(listnum))] then&lt;br /&gt;
				table.insert(listnums, tonumber(listnum))&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	table.sort(listnums)&lt;br /&gt;
&lt;br /&gt;
	local border = mw.text.trim(args[cfg.arg.border] or args[1] or &#039;&#039;)&lt;br /&gt;
	if border == cfg.keyword.border_child then&lt;br /&gt;
		border = cfg.keyword.border_subgroup&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- render the main body of the navbox&lt;br /&gt;
	local tbl = renderMainTable(border, listnums)&lt;br /&gt;
&lt;br /&gt;
	local res = mw.html.create()&lt;br /&gt;
	-- render the appropriate wrapper for the navbox, based on the border param&lt;br /&gt;
&lt;br /&gt;
	if border == cfg.keyword.border_none then&lt;br /&gt;
		res:node(add_navbox_styles(hiding_templatestyles))&lt;br /&gt;
		local nav = res:tag(&#039;div&#039;)&lt;br /&gt;
			:attr(&#039;role&#039;, &#039;navigation&#039;)&lt;br /&gt;
			:node(tbl)&lt;br /&gt;
		-- aria-labelledby title, otherwise above, otherwise lone group&lt;br /&gt;
		if args[cfg.arg.title] or args[cfg.arg.above] or (args[cfg.arg.group1]&lt;br /&gt;
			and not args[cfg.arg.group2]) then&lt;br /&gt;
			nav:attr(&lt;br /&gt;
				&#039;aria-labelledby&#039;,&lt;br /&gt;
				mw.uri.anchorEncode(&lt;br /&gt;
					args[cfg.arg.title] or args[cfg.arg.above] or args[cfg.arg.group1]&lt;br /&gt;
				) .. args.argHash&lt;br /&gt;
			)&lt;br /&gt;
		else&lt;br /&gt;
			nav:attr(&#039;aria-label&#039;, cfg.aria_label .. args.argHash)&lt;br /&gt;
		end&lt;br /&gt;
	elseif border == cfg.keyword.border_subgroup then&lt;br /&gt;
		-- We assume that this navbox is being rendered in a list cell of a&lt;br /&gt;
		-- parent navbox, and is therefore inside a div with padding:0em 0.25em.&lt;br /&gt;
		-- We start with a &amp;lt;/div&amp;gt; to avoid the padding being applied, and at the&lt;br /&gt;
		-- end add a &amp;lt;div&amp;gt; to balance out the parent&#039;s &amp;lt;/div&amp;gt;&lt;br /&gt;
		res&lt;br /&gt;
			:wikitext(&#039;&amp;lt;/div&amp;gt;&#039;)&lt;br /&gt;
			:node(tbl)&lt;br /&gt;
			:wikitext(&#039;&amp;lt;div&amp;gt;&#039;)&lt;br /&gt;
	else&lt;br /&gt;
		res:node(add_navbox_styles(hiding_templatestyles))&lt;br /&gt;
		local nav = res:tag(&#039;div&#039;)&lt;br /&gt;
			:attr(&#039;role&#039;, &#039;navigation&#039;)&lt;br /&gt;
			:addClass(cfg.class.navbox)&lt;br /&gt;
			:addClass(args[cfg.arg.navboxclass])&lt;br /&gt;
			:cssText(args[cfg.arg.bodystyle])&lt;br /&gt;
			:cssText(args[cfg.arg.style])&lt;br /&gt;
			:css(&#039;padding&#039;, &#039;3px&#039;)&lt;br /&gt;
			:node(tbl)&lt;br /&gt;
		-- aria-labelledby title, otherwise above, otherwise lone group&lt;br /&gt;
		if args[cfg.arg.title] or args[cfg.arg.above]&lt;br /&gt;
			or (args[cfg.arg.group1] and not args[cfg.arg.group2]) then&lt;br /&gt;
			nav:attr(&lt;br /&gt;
				&#039;aria-labelledby&#039;,&lt;br /&gt;
				mw.uri.anchorEncode(&lt;br /&gt;
					args[cfg.arg.title] or args[cfg.arg.above] or args[cfg.arg.group1]&lt;br /&gt;
				) .. args.argHash&lt;br /&gt;
			)&lt;br /&gt;
		else&lt;br /&gt;
			nav:attr(&#039;aria-label&#039;, cfg.aria_label .. args.argHash)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if (args[cfg.arg.nocat] or cfg.keyword.nocat_false):lower() == cfg.keyword.nocat_false then&lt;br /&gt;
		renderTrackingCategories(res, border)&lt;br /&gt;
	end&lt;br /&gt;
	return striped(tostring(res), border)&lt;br /&gt;
end --p._navbox&lt;br /&gt;
&lt;br /&gt;
function p._withCollapsibleGroups(pargs)&lt;br /&gt;
	-- table for args passed to navbox&lt;br /&gt;
	local targs = {}&lt;br /&gt;
&lt;br /&gt;
	-- process args&lt;br /&gt;
	local passthroughLocal = {&lt;br /&gt;
		[cfg.arg.bodystyle] = true,&lt;br /&gt;
		[cfg.arg.border] = true,&lt;br /&gt;
		[cfg.arg.style] = true,&lt;br /&gt;
	}&lt;br /&gt;
	for k,v in pairs(pargs) do&lt;br /&gt;
		if k and type(k) == &#039;string&#039; then&lt;br /&gt;
			if passthrough[k] or passthroughLocal[k] then&lt;br /&gt;
				targs[k] = v&lt;br /&gt;
			elseif (k:match(cfg.pattern.num)) then&lt;br /&gt;
				local n = k:match(cfg.pattern.num)&lt;br /&gt;
				local list_and_num = andnum(&#039;list&#039;, n)&lt;br /&gt;
				if ((k:match(cfg.pattern.listnum) or k:match(cfg.pattern.contentnum))&lt;br /&gt;
						and targs[list_and_num] == nil&lt;br /&gt;
						and pargs[andnum(&#039;group&#039;, n)] == nil&lt;br /&gt;
						and pargs[andnum(&#039;sect&#039;, n)] == nil&lt;br /&gt;
						and pargs[andnum(&#039;section&#039;, n)] == nil) then&lt;br /&gt;
					targs[list_and_num] = concatstrings({&lt;br /&gt;
						pargs[list_and_num] or &#039;&#039;,&lt;br /&gt;
						pargs[andnum(&#039;content&#039;, n)] or &#039;&#039;&lt;br /&gt;
					})&lt;br /&gt;
					if (targs[list_and_num] and inArray(cfg.keyword.subgroups, targs[list_and_num])) then&lt;br /&gt;
						targs[list_and_num] = getSubgroup(pargs, n, targs[list_and_num])&lt;br /&gt;
					end&lt;br /&gt;
				elseif ((k:match(cfg.pattern.groupnum) or k:match(cfg.pattern.sectnum) or k:match(cfg.pattern.sectionnum))&lt;br /&gt;
						and targs[list_and_num] == nil) then&lt;br /&gt;
					local titlestyle = concatstyles({&lt;br /&gt;
						pargs[cfg.arg.groupstyle] or &#039;&#039;,&lt;br /&gt;
						pargs[cfg.arg.secttitlestyle] or &#039;&#039;, &lt;br /&gt;
						pargs[andnum(&#039;groupstyle&#039;, n)] or &#039;&#039;, &lt;br /&gt;
						pargs[andnum(&#039;sectiontitlestyle&#039;, n)] or &#039;&#039;&lt;br /&gt;
					})&lt;br /&gt;
					local liststyle = concatstyles({&lt;br /&gt;
						pargs[cfg.arg.liststyle] or &#039;&#039;,&lt;br /&gt;
						pargs[cfg.arg.contentstyle] or &#039;&#039;, &lt;br /&gt;
						pargs[andnum(&#039;liststyle&#039;, n)] or &#039;&#039;, &lt;br /&gt;
						pargs[andnum(&#039;contentstyle&#039;, n)] or &#039;&#039;&lt;br /&gt;
					})&lt;br /&gt;
					local title = concatstrings({&lt;br /&gt;
						pargs[andnum(&#039;group&#039;, n)] or &#039;&#039;,&lt;br /&gt;
						pargs[andnum(&#039;sect&#039;, n)] or &#039;&#039;,&lt;br /&gt;
						pargs[andnum(&#039;section&#039;, n)] or &#039;&#039;&lt;br /&gt;
					})&lt;br /&gt;
					local list = concatstrings({&lt;br /&gt;
						pargs[list_and_num] or &#039;&#039;, &lt;br /&gt;
						pargs[andnum(&#039;content&#039;, n)] or &#039;&#039;&lt;br /&gt;
					})&lt;br /&gt;
					if list and inArray(cfg.keyword.subgroups, list) then&lt;br /&gt;
						list = getSubgroup(pargs, n, list)&lt;br /&gt;
					end&lt;br /&gt;
					local abbr_and_num = andnum(&#039;abbr&#039;, n)&lt;br /&gt;
					local state = (pargs[abbr_and_num] and pargs[abbr_and_num] == pargs[cfg.arg.selected]) &lt;br /&gt;
						and cfg.keyword.state_uncollapsed&lt;br /&gt;
						or (pargs[andnum(&#039;state&#039;, n)] or cfg.keyword.state_collapsed)&lt;br /&gt;
					&lt;br /&gt;
					targs[list_and_num] =p._navbox({&lt;br /&gt;
						cfg.keyword.border_child,&lt;br /&gt;
						[cfg.arg.navbar] = cfg.keyword.navbar_plain,&lt;br /&gt;
						[cfg.arg.state] = state,&lt;br /&gt;
						[cfg.arg.basestyle] = pargs[cfg.arg.basestyle],&lt;br /&gt;
						[cfg.arg.title] = title,&lt;br /&gt;
						[cfg.arg.titlestyle] = titlestyle,&lt;br /&gt;
						[andnum(&#039;list&#039;, 1)] = list,&lt;br /&gt;
						[cfg.arg.liststyle] = liststyle,&lt;br /&gt;
						[cfg.arg.listclass] = pargs[andnum(&#039;listclass&#039;, n)],&lt;br /&gt;
						[cfg.arg.image] = pargs[andnum(&#039;image&#039;, n)],&lt;br /&gt;
						[cfg.arg.imageleft] = pargs[andnum(&#039;imageleft&#039;, n)],&lt;br /&gt;
						[cfg.arg.listpadding] = pargs[cfg.arg.listpadding],&lt;br /&gt;
						argHash = pargs.argHash&lt;br /&gt;
					})&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	-- ordering of style and bodystyle&lt;br /&gt;
	targs[cfg.arg.style] = concatstyles({targs[cfg.arg.style] or &#039;&#039;, targs[cfg.arg.bodystyle] or &#039;&#039;})&lt;br /&gt;
	targs[cfg.arg.bodystyle] = nil&lt;br /&gt;
&lt;br /&gt;
	-- child or subgroup&lt;br /&gt;
	if targs[cfg.arg.border] == nil then targs[cfg.arg.border] = pargs[1] end&lt;br /&gt;
&lt;br /&gt;
	return p._navbox(targs)&lt;br /&gt;
end --p._withCollapsibleGroups&lt;br /&gt;
&lt;br /&gt;
function p._withColumns(pargs)&lt;br /&gt;
	-- table for args passed to navbox&lt;br /&gt;
	local targs = {}&lt;br /&gt;
&lt;br /&gt;
	-- tables of column numbers&lt;br /&gt;
	local colheadernums = {}&lt;br /&gt;
	local colnums = {}&lt;br /&gt;
	local colfooternums = {}&lt;br /&gt;
&lt;br /&gt;
	-- process args&lt;br /&gt;
	local passthroughLocal = {&lt;br /&gt;
		[cfg.arg.evenstyle]=true,&lt;br /&gt;
		[cfg.arg.groupstyle]=true,&lt;br /&gt;
		[cfg.arg.liststyle]=true,&lt;br /&gt;
		[cfg.arg.oddstyle]=true,&lt;br /&gt;
		[cfg.arg.state]=true,&lt;br /&gt;
	}&lt;br /&gt;
	for k,v in pairs(pargs) do&lt;br /&gt;
		if passthrough[k] or passthroughLocal[k] then&lt;br /&gt;
			targs[k] = v&lt;br /&gt;
		elseif type(k) == &#039;string&#039; then&lt;br /&gt;
			if k:match(cfg.pattern.listnum) then&lt;br /&gt;
				local n = k:match(cfg.pattern.listnum)&lt;br /&gt;
				targs[andnum(&#039;liststyle&#039;, n + 2)] = pargs[andnum(&#039;liststyle&#039;, n)]&lt;br /&gt;
				targs[andnum(&#039;group&#039;, n + 2)] = pargs[andnum(&#039;group&#039;, n)]&lt;br /&gt;
				targs[andnum(&#039;groupstyle&#039;, n + 2)] = pargs[andnum(&#039;groupstyle&#039;, n)]&lt;br /&gt;
				if v and inArray(cfg.keyword.subgroups, v) then&lt;br /&gt;
					targs[andnum(&#039;list&#039;, n + 2)] = getSubgroup(pargs, n, v)&lt;br /&gt;
				else&lt;br /&gt;
					targs[andnum(&#039;list&#039;, n + 2)] = v&lt;br /&gt;
				end&lt;br /&gt;
			elseif (k:match(cfg.pattern.colheadernum) and v ~= &#039;&#039;) then&lt;br /&gt;
				table.insert(colheadernums, tonumber(k:match(cfg.pattern.colheadernum)))&lt;br /&gt;
			elseif (k:match(cfg.pattern.colnum) and v ~= &#039;&#039;) then&lt;br /&gt;
				table.insert(colnums, tonumber(k:match(cfg.pattern.colnum)))&lt;br /&gt;
			elseif (k:match(cfg.pattern.colfooternum) and v ~= &#039;&#039;) then&lt;br /&gt;
				table.insert(colfooternums, tonumber(k:match(cfg.pattern.colfooternum)))&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	table.sort(colheadernums)&lt;br /&gt;
	table.sort(colnums)&lt;br /&gt;
	table.sort(colfooternums)&lt;br /&gt;
&lt;br /&gt;
	-- HTML table for list1&lt;br /&gt;
	local coltable = mw.html.create( &#039;table&#039; ):addClass(&#039;navbox-columns-table&#039;)&lt;br /&gt;
	local row, col&lt;br /&gt;
&lt;br /&gt;
	local tablestyle = ( (#colheadernums &amp;gt; 0) or (not isblank(pargs[cfg.arg.fullwidth])) )&lt;br /&gt;
		and &#039;width:100%&#039;&lt;br /&gt;
		or &#039;width:auto; margin-left:auto; margin-right:auto&#039;&lt;br /&gt;
&lt;br /&gt;
	coltable:cssText(concatstyles({&lt;br /&gt;
		&#039;border-spacing: 0px; text-align:left&#039;,&lt;br /&gt;
		tablestyle,&lt;br /&gt;
		pargs[cfg.arg.coltablestyle] or &#039;&#039;&lt;br /&gt;
	}))&lt;br /&gt;
&lt;br /&gt;
	--- Header row ---&lt;br /&gt;
	if (#colheadernums &amp;gt; 0) then&lt;br /&gt;
		row = coltable:tag(&#039;tr&#039;)&lt;br /&gt;
		for k, n in ipairs(colheadernums) do&lt;br /&gt;
			col = row:tag(&#039;td&#039;):addClass(&#039;navbox-abovebelow&#039;)&lt;br /&gt;
			col:cssText(concatstyles({&lt;br /&gt;
				(k &amp;gt; 1) and &#039;border-left:2px solid #fdfdfd&#039; or &#039;&#039;,&lt;br /&gt;
				&#039;font-weight:bold&#039;,&lt;br /&gt;
				pargs[cfg.arg.colheaderstyle] or &#039;&#039;,&lt;br /&gt;
				pargs[andnum(&#039;colheaderstyle&#039;, n)] or &#039;&#039;&lt;br /&gt;
			}))&lt;br /&gt;
			col:attr(&#039;colspan&#039;, tonumber(pargs[andnum(&#039;colheadercolspan&#039;, n)]))&lt;br /&gt;
			col:wikitext(pargs[andnum(&#039;colheader&#039;, n)])&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	--- Main columns ---&lt;br /&gt;
	row = coltable:tag(&#039;tr&#039;):css(&#039;vertical-align&#039;, &#039;top&#039;)&lt;br /&gt;
	for k, n in ipairs(colnums) do&lt;br /&gt;
		if k == 1 and isblank(pargs[andnum(&#039;colheader&#039;, 1)])&lt;br /&gt;
				and isblank(pargs[andnum(&#039;colfooter&#039;, 1)])&lt;br /&gt;
				and isblank(pargs[cfg.arg.fullwidth]) then&lt;br /&gt;
			local nopad = inArray(&lt;br /&gt;
				{&#039;off&#039;, &#039;0&#039;, &#039;0em&#039;, &#039;0px&#039;},&lt;br /&gt;
				mw.ustring.gsub(pargs[cfg.arg.padding] or &#039;&#039;, &#039;[;%%]&#039;, &#039;&#039;))&lt;br /&gt;
			if not nopad then&lt;br /&gt;
				row:tag(&#039;td&#039;):wikitext(&#039;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&#039;)&lt;br /&gt;
					:css(&#039;width&#039;, (pargs[cfg.arg.padding] or &#039;5em&#039;))&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		col = row:tag(&#039;td&#039;):addClass(&#039;navbox-list&#039;)&lt;br /&gt;
		col:cssText(concatstyles({&lt;br /&gt;
			(k &amp;gt; 1) and &#039;border-left:2px solid #fdfdfd&#039; or &#039;&#039;,&lt;br /&gt;
			&#039;padding:0px&#039;,&lt;br /&gt;
			pargs[cfg.arg.colstyle] or &#039;&#039;,&lt;br /&gt;
			((n%2 == 0) and pargs[cfg.arg.evencolstyle] or pargs[cfg.arg.oddcolstyle]) or &#039;&#039;,&lt;br /&gt;
			pargs[andnum(&#039;colstyle&#039;, n)] or &#039;&#039;,&lt;br /&gt;
			&#039;width:&#039; .. (pargs[andnum(&#039;colwidth&#039;, n)] or pargs[cfg.arg.colwidth] or &#039;10em&#039;)&lt;br /&gt;
		}))&lt;br /&gt;
		local wt = pargs[andnum(&#039;col&#039;, n)]&lt;br /&gt;
		if wt and inArray(cfg.keyword.subgroups, wt) then&lt;br /&gt;
			wt = getSubgroup(pargs, n, wt, cfg.arg.col_and_num)&lt;br /&gt;
		end&lt;br /&gt;
		col:tag(&#039;div&#039;):newline():wikitext(wt):newline()&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	--- Footer row ---&lt;br /&gt;
	if (#colfooternums &amp;gt; 0) then&lt;br /&gt;
		row = coltable:tag(&#039;tr&#039;)&lt;br /&gt;
		for k, n in ipairs(colfooternums) do&lt;br /&gt;
			col = row:tag(&#039;td&#039;):addClass(&#039;navbox-abovebelow&#039;)&lt;br /&gt;
			col:cssText(concatstyles({&lt;br /&gt;
				(k &amp;gt; 1) and &#039;border-left:2px solid #fdfdfd&#039; or &#039;&#039;,&lt;br /&gt;
				&#039;font-weight:bold&#039;,&lt;br /&gt;
				pargs[cfg.arg.colfooterstyle] or &#039;&#039;,&lt;br /&gt;
				pargs[andnum(&#039;colfooterstyle&#039;, n)] or &#039;&#039;&lt;br /&gt;
			}))&lt;br /&gt;
			col:attr(&#039;colspan&#039;, tonumber(pargs[andnum(&#039;colfootercolspan&#039;, n)]))&lt;br /&gt;
			col:wikitext(pargs[andnum(&#039;colfooter&#039;, n)])&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- assign table to list1&lt;br /&gt;
	targs[andnum(&#039;list&#039;, 1)] = tostring(coltable)&lt;br /&gt;
	if isblank(pargs[andnum(&#039;colheader&#039;, 1)]) &lt;br /&gt;
			and isblank(pargs[andnum(&#039;col&#039;, 1)])&lt;br /&gt;
			and isblank(pargs[andnum(&#039;colfooter&#039;, 1)]) then&lt;br /&gt;
		targs[andnum(&#039;list&#039;, 1)] = targs[andnum(&#039;list&#039;, 1)] ..&lt;br /&gt;
			cfg.category.without_first_col&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Other parameters&lt;br /&gt;
	targs[cfg.arg.border] = pargs[cfg.arg.border] or pargs[1]&lt;br /&gt;
	targs[cfg.arg.evenodd] = (not isblank(pargs[cfg.arg.evenodd])) and pargs[cfg.arg.evenodd] or nil&lt;br /&gt;
	targs[cfg.arg.list1padding] = &#039;0px&#039;&lt;br /&gt;
	targs[andnum(&#039;liststyle&#039;, 1)] = &#039;background:transparent;color:inherit;&#039;&lt;br /&gt;
	targs[cfg.arg.style] = concatstyles({pargs[cfg.arg.style], pargs[cfg.arg.bodystyle]})&lt;br /&gt;
	targs[cfg.arg.tracking] = &#039;no&#039;&lt;br /&gt;
	&lt;br /&gt;
	return p._navbox(targs)&lt;br /&gt;
end --p._withColumns&lt;br /&gt;
&lt;br /&gt;
-- Template entry points&lt;br /&gt;
function p.navbox (frame, boxtype)&lt;br /&gt;
	local function readArgs(args, prefix)&lt;br /&gt;
		-- Read the arguments in the order they&#039;ll be output in, to make references&lt;br /&gt;
		-- number in the right order.&lt;br /&gt;
		local _&lt;br /&gt;
		_ = args[prefix .. cfg.arg.title]&lt;br /&gt;
		_ = args[prefix .. cfg.arg.above]&lt;br /&gt;
		-- Limit this to 20 as covering &#039;most&#039; cases (that&#039;s a SWAG) and because&lt;br /&gt;
		-- iterator approach won&#039;t work here&lt;br /&gt;
		for i = 1, 20 do&lt;br /&gt;
			_ = args[prefix .. andnum(&#039;group&#039;, i)]&lt;br /&gt;
			if inArray(cfg.keyword.subgroups, args[prefix .. andnum(&#039;list&#039;, i)]) then&lt;br /&gt;
				for _, v in ipairs(cfg.arg.subgroups_and_num) do&lt;br /&gt;
					readArgs(args, prefix .. string.format(v, i) .. &amp;quot;_&amp;quot;)&lt;br /&gt;
				end&lt;br /&gt;
				readArgs(args, prefix .. andnum(&#039;col&#039;, i) .. &amp;quot;_&amp;quot;)&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		_ = args[prefix .. cfg.arg.below]&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	if not getArgs then&lt;br /&gt;
		getArgs = require(&#039;Module:Arguments&#039;).getArgs&lt;br /&gt;
	end&lt;br /&gt;
	local args = getArgs(frame, {wrappers = {cfg.pattern[boxtype or &#039;navbox&#039;]}})&lt;br /&gt;
	readArgs(args, &amp;quot;&amp;quot;)&lt;br /&gt;
	args.argHash = nil -- we shouldn&#039;t accept argHash passed from a template&lt;br /&gt;
	args.type = args.type or cfg.keyword[boxtype]&lt;br /&gt;
	return p[&#039;_navbox&#039;](args)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
p[cfg.keyword.with_collapsible_groups] = function (frame)&lt;br /&gt;
	return p.navbox(frame, &#039;with_collapsible_groups&#039;)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
p[cfg.keyword.with_columns] = function (frame)&lt;br /&gt;
	return p.navbox(frame, &#039;with_columns&#039;)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Navbar&amp;diff=11264</id>
		<title>Module:Navbar</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Navbar&amp;diff=11264"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;local p = {}&lt;br /&gt;
local cfg = mw.loadData(&#039;Module:Navbar/configuration&#039;)&lt;br /&gt;
&lt;br /&gt;
local function get_title_arg(is_collapsible, template)&lt;br /&gt;
	local title_arg = 1&lt;br /&gt;
	if is_collapsible then title_arg = 2 end&lt;br /&gt;
	if template then title_arg = &#039;template&#039; end&lt;br /&gt;
	return title_arg&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function choose_links(template, args)&lt;br /&gt;
	-- The show table indicates the default displayed items.&lt;br /&gt;
	-- view, talk, edit, hist, move, watch&lt;br /&gt;
	-- TODO: Move to configuration.&lt;br /&gt;
	local show = {true, true, true, false, false, false}&lt;br /&gt;
	if template then&lt;br /&gt;
		show[2] = false&lt;br /&gt;
		show[3] = false&lt;br /&gt;
		local index = {t = 2, d = 2, e = 3, h = 4, m = 5, w = 6,&lt;br /&gt;
			talk = 2, edit = 3, hist = 4, move = 5, watch = 6}&lt;br /&gt;
		-- TODO: Consider removing TableTools dependency.&lt;br /&gt;
		for _, v in ipairs(require (&#039;Module:TableTools&#039;).compressSparseArray(args)) do&lt;br /&gt;
			local num = index[v]&lt;br /&gt;
			if num then show[num] = true end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local remove_edit_link = args.noedit&lt;br /&gt;
	if remove_edit_link then show[3] = false end&lt;br /&gt;
	&lt;br /&gt;
	return show&lt;br /&gt;
	&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function add_link(link_description, ul, is_mini, font_style)&lt;br /&gt;
	local l&lt;br /&gt;
	if link_description.url then&lt;br /&gt;
		l = {&#039;[&#039;, &#039;&#039;, &#039;]&#039;}&lt;br /&gt;
	else&lt;br /&gt;
		l = {&#039;[[&#039;, &#039;|&#039;, &#039;]]&#039;}&lt;br /&gt;
	end&lt;br /&gt;
	ul:tag(&#039;li&#039;)&lt;br /&gt;
		:addClass(&#039;nv-&#039; .. link_description.full)&lt;br /&gt;
		:wikitext(l[1] .. link_description.link .. l[2])&lt;br /&gt;
		:tag(is_mini and &#039;abbr&#039; or &#039;span&#039;)&lt;br /&gt;
			:attr(&#039;title&#039;, link_description.html_title)&lt;br /&gt;
			:cssText(font_style)&lt;br /&gt;
			:wikitext(is_mini and link_description.mini or link_description.full)&lt;br /&gt;
			:done()&lt;br /&gt;
		:wikitext(l[3])&lt;br /&gt;
		:done()&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function make_list(title_text, has_brackets, displayed_links, is_mini, font_style)&lt;br /&gt;
	&lt;br /&gt;
	local title = mw.title.new(mw.text.trim(title_text), cfg.title_namespace)&lt;br /&gt;
	if not title then&lt;br /&gt;
		error(cfg.invalid_title .. title_text)&lt;br /&gt;
	end&lt;br /&gt;
	local talkpage = title.talkPageTitle and title.talkPageTitle.fullText or &#039;&#039;&lt;br /&gt;
	&lt;br /&gt;
	-- TODO: Get link_descriptions and show into the configuration module.&lt;br /&gt;
	-- link_descriptions should be easier...&lt;br /&gt;
	local link_descriptions = {&lt;br /&gt;
		{ [&#039;mini&#039;] = &#039;v&#039;, [&#039;full&#039;] = &#039;view&#039;, [&#039;html_title&#039;] = &#039;View this template&#039;,&lt;br /&gt;
			[&#039;link&#039;] = title.fullText, [&#039;url&#039;] = false },&lt;br /&gt;
		{ [&#039;mini&#039;] = &#039;t&#039;, [&#039;full&#039;] = &#039;talk&#039;, [&#039;html_title&#039;] = &#039;Discuss this template&#039;,&lt;br /&gt;
			[&#039;link&#039;] = talkpage, [&#039;url&#039;] = false },&lt;br /&gt;
		{ [&#039;mini&#039;] = &#039;e&#039;, [&#039;full&#039;] = &#039;edit&#039;, [&#039;html_title&#039;] = &#039;Edit this template&#039;,&lt;br /&gt;
			[&#039;link&#039;] = &#039;Special:EditPage/&#039; .. title.fullText, [&#039;url&#039;] = false },&lt;br /&gt;
		{ [&#039;mini&#039;] = &#039;h&#039;, [&#039;full&#039;] = &#039;hist&#039;, [&#039;html_title&#039;] = &#039;History of this template&#039;,&lt;br /&gt;
			[&#039;link&#039;] = &#039;Special:PageHistory/&#039; .. title.fullText, [&#039;url&#039;] = false },&lt;br /&gt;
		{ [&#039;mini&#039;] = &#039;m&#039;, [&#039;full&#039;] = &#039;move&#039;, [&#039;html_title&#039;] = &#039;Move this template&#039;,&lt;br /&gt;
			[&#039;link&#039;] = mw.title.new(&#039;Special:Movepage&#039;):fullUrl(&#039;target=&#039;..title.fullText), [&#039;url&#039;] = true },&lt;br /&gt;
		{ [&#039;mini&#039;] = &#039;w&#039;, [&#039;full&#039;] = &#039;watch&#039;, [&#039;html_title&#039;] = &#039;Watch this template&#039;, &lt;br /&gt;
			[&#039;link&#039;] = title:fullUrl(&#039;action=watch&#039;), [&#039;url&#039;] = true }&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	local ul = mw.html.create(&#039;ul&#039;)&lt;br /&gt;
	if has_brackets then&lt;br /&gt;
		ul:addClass(cfg.classes.brackets)&lt;br /&gt;
			:cssText(font_style)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	for i, _ in ipairs(displayed_links) do&lt;br /&gt;
		if displayed_links[i] then add_link(link_descriptions[i], ul, is_mini, font_style) end&lt;br /&gt;
	end&lt;br /&gt;
	return ul:done()&lt;br /&gt;
	&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._navbar(args)&lt;br /&gt;
	&lt;br /&gt;
	-- TODO: We probably don&#039;t need both fontstyle and fontcolor...&lt;br /&gt;
	local font_style = args.fontstyle&lt;br /&gt;
	local font_color = args.fontcolor&lt;br /&gt;
	local is_collapsible = args.collapsible&lt;br /&gt;
	local is_mini = args.mini&lt;br /&gt;
	local is_plain = args.plain&lt;br /&gt;
	&lt;br /&gt;
	local collapsible_class = nil&lt;br /&gt;
	if is_collapsible then&lt;br /&gt;
		collapsible_class = cfg.classes.collapsible&lt;br /&gt;
		if not is_plain then is_mini = 1 end&lt;br /&gt;
		if font_color then&lt;br /&gt;
			font_style = (font_style or &#039;&#039;) .. &#039;; color: &#039; .. font_color .. &#039;;&#039;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local navbar_style = args.style&lt;br /&gt;
	local div = mw.html.create():tag(&#039;div&#039;)&lt;br /&gt;
	div&lt;br /&gt;
		:addClass(cfg.classes.navbar)&lt;br /&gt;
		:addClass(cfg.classes.plainlinks)&lt;br /&gt;
		:addClass(cfg.classes.horizontal_list)&lt;br /&gt;
		:addClass(collapsible_class) -- we made the determination earlier&lt;br /&gt;
		:cssText(navbar_style)&lt;br /&gt;
&lt;br /&gt;
	if is_mini then div:addClass(cfg.classes.mini) end&lt;br /&gt;
&lt;br /&gt;
	local box_text = (args.text or cfg.box_text) .. &#039; &#039;&lt;br /&gt;
	 -- the concatenated space guarantees the box text is separated&lt;br /&gt;
	if not (is_mini or is_plain) then&lt;br /&gt;
		div&lt;br /&gt;
			:tag(&#039;span&#039;)&lt;br /&gt;
				:addClass(cfg.classes.box_text)&lt;br /&gt;
				:cssText(font_style)&lt;br /&gt;
				:wikitext(box_text)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local template = args.template&lt;br /&gt;
	local displayed_links = choose_links(template, args)&lt;br /&gt;
	local has_brackets = args.brackets&lt;br /&gt;
	local title_arg = get_title_arg(is_collapsible, template)&lt;br /&gt;
	local title_text = args[title_arg] or (&#039;:&#039; .. mw.getCurrentFrame():getParent():getTitle())&lt;br /&gt;
	local list = make_list(title_text, has_brackets, displayed_links, is_mini, font_style)&lt;br /&gt;
	div:node(list)&lt;br /&gt;
&lt;br /&gt;
	if is_collapsible then&lt;br /&gt;
		local title_text_class&lt;br /&gt;
		if is_mini then&lt;br /&gt;
			title_text_class = cfg.classes.collapsible_title_mini&lt;br /&gt;
		else&lt;br /&gt;
			title_text_class = cfg.classes.collapsible_title_full&lt;br /&gt;
		end&lt;br /&gt;
		div:done()&lt;br /&gt;
			:tag(&#039;div&#039;)&lt;br /&gt;
			:addClass(title_text_class)&lt;br /&gt;
			:cssText(font_style)&lt;br /&gt;
			:wikitext(args[1])&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local frame = mw.getCurrentFrame()&lt;br /&gt;
	-- hlist -&amp;gt; navbar is best-effort to preserve old Common.css ordering.&lt;br /&gt;
	return frame:extensionTag{&lt;br /&gt;
		name = &#039;templatestyles&#039;, args = { src = cfg.hlist_templatestyles }&lt;br /&gt;
	} .. frame:extensionTag{&lt;br /&gt;
		name = &#039;templatestyles&#039;, args = { src = cfg.templatestyles }&lt;br /&gt;
	} .. tostring(div:done())&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.navbar(frame)&lt;br /&gt;
	return p._navbar(require(&#039;Module:Arguments&#039;).getArgs(frame))&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Namespace_detect&amp;diff=11262</id>
		<title>Module:Namespace detect</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Namespace_detect&amp;diff=11262"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;--[[&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
--                                                                            --&lt;br /&gt;
--                            NAMESPACE DETECT                                --&lt;br /&gt;
--                                                                            --&lt;br /&gt;
-- This module implements the {{namespace detect}} template in Lua, with a    --&lt;br /&gt;
-- few improvements: all namespaces and all namespace aliases are supported,  --&lt;br /&gt;
-- and namespace names are detected automatically for the local wiki. The     --&lt;br /&gt;
-- module can also use the corresponding subject namespace value if it is     --&lt;br /&gt;
-- used on a talk page. Parameter names can be configured for different wikis --&lt;br /&gt;
-- by altering the values in the &amp;quot;cfg&amp;quot; table in                               --&lt;br /&gt;
-- Module:Namespace detect/config.                                            --&lt;br /&gt;
--                                                                            --&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
--]]&lt;br /&gt;
&lt;br /&gt;
local data = mw.loadData(&#039;Module:Namespace detect/data&#039;)&lt;br /&gt;
local argKeys = data.argKeys&lt;br /&gt;
local cfg = data.cfg&lt;br /&gt;
local mappings = data.mappings&lt;br /&gt;
&lt;br /&gt;
local yesno = require(&#039;Module:Yesno&#039;)&lt;br /&gt;
local mArguments -- Lazily initialise Module:Arguments&lt;br /&gt;
local mTableTools -- Lazily initilalise Module:TableTools&lt;br /&gt;
local ustringLower = mw.ustring.lower&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
local function fetchValue(t1, t2)&lt;br /&gt;
	-- Fetches a value from the table t1 for the first key in array t2 where&lt;br /&gt;
	-- a non-nil value of t1 exists.&lt;br /&gt;
	for i, key in ipairs(t2) do&lt;br /&gt;
		local value = t1[key]&lt;br /&gt;
		if value ~= nil then&lt;br /&gt;
			return value&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return nil&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function equalsArrayValue(t, value)&lt;br /&gt;
	-- Returns true if value equals a value in the array t. Otherwise&lt;br /&gt;
	-- returns false.&lt;br /&gt;
	for i, arrayValue in ipairs(t) do&lt;br /&gt;
		if value == arrayValue then&lt;br /&gt;
			return true&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return false&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.getPageObject(page)&lt;br /&gt;
	-- Get the page object, passing the function through pcall in case of&lt;br /&gt;
	-- errors, e.g. being over the expensive function count limit.&lt;br /&gt;
	if page then&lt;br /&gt;
		local success, pageObject = pcall(mw.title.new, page)&lt;br /&gt;
		if success then&lt;br /&gt;
			return pageObject&lt;br /&gt;
		else&lt;br /&gt;
			return nil&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		return mw.title.getCurrentTitle()&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Provided for backward compatibility with other modules&lt;br /&gt;
function p.getParamMappings()&lt;br /&gt;
	return mappings&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function getNamespace(args)&lt;br /&gt;
	-- This function gets the namespace name from the page object.&lt;br /&gt;
	local page = fetchValue(args, argKeys.demopage)&lt;br /&gt;
	if page == &#039;&#039; then&lt;br /&gt;
		page = nil&lt;br /&gt;
	end&lt;br /&gt;
	local demospace = fetchValue(args, argKeys.demospace)&lt;br /&gt;
	if demospace == &#039;&#039; then&lt;br /&gt;
		demospace = nil&lt;br /&gt;
	end&lt;br /&gt;
	local subjectns = fetchValue(args, argKeys.subjectns)&lt;br /&gt;
	local ret&lt;br /&gt;
	if demospace then&lt;br /&gt;
		-- Handle &amp;quot;demospace = main&amp;quot; properly.&lt;br /&gt;
		if equalsArrayValue(argKeys.main, ustringLower(demospace)) then&lt;br /&gt;
			ret = mw.site.namespaces[0].name&lt;br /&gt;
		else&lt;br /&gt;
			ret = demospace&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		local pageObject = p.getPageObject(page)&lt;br /&gt;
		if pageObject then&lt;br /&gt;
			if pageObject.isTalkPage then&lt;br /&gt;
				-- Get the subject namespace if the option is set,&lt;br /&gt;
				-- otherwise use &amp;quot;talk&amp;quot;.&lt;br /&gt;
				if yesno(subjectns) then&lt;br /&gt;
					ret = mw.site.namespaces[pageObject.namespace].subject.name&lt;br /&gt;
				else&lt;br /&gt;
					ret = &#039;talk&#039;&lt;br /&gt;
				end&lt;br /&gt;
			else&lt;br /&gt;
				ret = pageObject.nsText&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			return nil -- return nil if the page object doesn&#039;t exist.&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	ret = ret:gsub(&#039;_&#039;, &#039; &#039;)&lt;br /&gt;
	return ustringLower(ret)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._main(args)&lt;br /&gt;
	-- Check the parameters stored in the mappings table for any matches.&lt;br /&gt;
	local namespace = getNamespace(args) or &#039;other&#039; -- &amp;quot;other&amp;quot; avoids nil table keys&lt;br /&gt;
	local params = mappings[namespace] or {}&lt;br /&gt;
	local ret = fetchValue(args, params)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- If there were no matches, return parameters for other namespaces.&lt;br /&gt;
	-- This happens if there was no text specified for the namespace that&lt;br /&gt;
	-- was detected or if the demospace parameter is not a valid&lt;br /&gt;
	-- namespace. Note that the parameter for the detected namespace must be&lt;br /&gt;
	-- completely absent for this to happen, not merely blank.&lt;br /&gt;
	--]]&lt;br /&gt;
	if ret == nil then&lt;br /&gt;
		ret = fetchValue(args, argKeys.other)&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	mArguments = require(&#039;Module:Arguments&#039;)&lt;br /&gt;
	local args = mArguments.getArgs(frame, {removeBlanks = false})&lt;br /&gt;
	local ret = p._main(args)&lt;br /&gt;
	return ret or &#039;&#039;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.table(frame)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Create a wikitable of all subject namespace parameters, for&lt;br /&gt;
	-- documentation purposes. The talk parameter is optional, in case it&lt;br /&gt;
	-- needs to be excluded in the documentation.&lt;br /&gt;
	--]]&lt;br /&gt;
	&lt;br /&gt;
	-- Load modules and initialise variables.&lt;br /&gt;
	mTableTools = require(&#039;Module:TableTools&#039;)&lt;br /&gt;
	local namespaces = mw.site.namespaces&lt;br /&gt;
	local cfg = data.cfg&lt;br /&gt;
	local useTalk = type(frame) == &#039;table&#039; &lt;br /&gt;
		and type(frame.args) == &#039;table&#039; &lt;br /&gt;
		and yesno(frame.args.talk) -- Whether to use the talk parameter.&lt;br /&gt;
	&lt;br /&gt;
	-- Get the header names.&lt;br /&gt;
	local function checkValue(value, default)&lt;br /&gt;
		if type(value) == &#039;string&#039; then&lt;br /&gt;
			return value&lt;br /&gt;
		else&lt;br /&gt;
			return default&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	local nsHeader = checkValue(cfg.wikitableNamespaceHeader, &#039;Namespace&#039;)&lt;br /&gt;
	local aliasesHeader = checkValue(cfg.wikitableAliasesHeader, &#039;Aliases&#039;)&lt;br /&gt;
&lt;br /&gt;
	-- Put the namespaces in order.&lt;br /&gt;
	local mappingsOrdered = {}&lt;br /&gt;
	for nsname, params in pairs(mappings) do&lt;br /&gt;
		if useTalk or nsname ~= &#039;talk&#039; then&lt;br /&gt;
			local nsid = namespaces[nsname].id&lt;br /&gt;
			-- Add 1, as the array must start with 1; nsid 0 would be lost otherwise.&lt;br /&gt;
			nsid = nsid + 1 &lt;br /&gt;
			mappingsOrdered[nsid] = params&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	mappingsOrdered = mTableTools.compressSparseArray(mappingsOrdered)&lt;br /&gt;
&lt;br /&gt;
	-- Build the table.&lt;br /&gt;
	local ret = &#039;{| class=&amp;quot;wikitable&amp;quot;&#039;&lt;br /&gt;
		.. &#039;\n|-&#039;&lt;br /&gt;
		.. &#039;\n! &#039; .. nsHeader&lt;br /&gt;
		.. &#039;\n! &#039; .. aliasesHeader&lt;br /&gt;
	for i, params in ipairs(mappingsOrdered) do&lt;br /&gt;
		for j, param in ipairs(params) do&lt;br /&gt;
			if j == 1 then&lt;br /&gt;
				ret = ret .. &#039;\n|-&#039;&lt;br /&gt;
					.. &#039;\n| &amp;lt;code&amp;gt;&#039; .. param .. &#039;&amp;lt;/code&amp;gt;&#039;&lt;br /&gt;
					.. &#039;\n| &#039;&lt;br /&gt;
			elseif j == 2 then&lt;br /&gt;
				ret = ret .. &#039;&amp;lt;code&amp;gt;&#039; .. param .. &#039;&amp;lt;/code&amp;gt;&#039;&lt;br /&gt;
			else&lt;br /&gt;
				ret = ret .. &#039;, &amp;lt;code&amp;gt;&#039; .. param .. &#039;&amp;lt;/code&amp;gt;&#039;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	ret = ret .. &#039;\n|-&#039;&lt;br /&gt;
		.. &#039;\n|}&#039;&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Message_box/configuration&amp;diff=11260</id>
		<title>Module:Message box/configuration</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Message_box/configuration&amp;diff=11260"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;--------------------------------------------------------------------------------&lt;br /&gt;
--                          Message box configuration                         --&lt;br /&gt;
--                                                                            --&lt;br /&gt;
-- This module contains configuration data for [[Module:Message box]].        --&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
return {&lt;br /&gt;
	ambox = {&lt;br /&gt;
		types = {&lt;br /&gt;
			speedy = {&lt;br /&gt;
				class = &#039;ambox-speedy&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			delete = {&lt;br /&gt;
				class = &#039;ambox-delete&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			content = {&lt;br /&gt;
				class = &#039;ambox-content&#039;,&lt;br /&gt;
				image = &#039;Ambox important.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			style = {&lt;br /&gt;
				class = &#039;ambox-style&#039;,&lt;br /&gt;
				image = &#039;Edit-clear.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			move = {&lt;br /&gt;
				class = &#039;ambox-move&#039;,&lt;br /&gt;
				image = &#039;Merge-split-transwiki default.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			protection = {&lt;br /&gt;
				class = &#039;ambox-protection&#039;,&lt;br /&gt;
				image = &#039;Semi-protection-shackle-keyhole.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			notice = {&lt;br /&gt;
				class = &#039;ambox-notice&#039;,&lt;br /&gt;
				image = &#039;Information icon4.svg&#039;&lt;br /&gt;
			}&lt;br /&gt;
		},&lt;br /&gt;
		default                     = &#039;notice&#039;,&lt;br /&gt;
		allowBlankParams            = {&#039;talk&#039;, &#039;sect&#039;, &#039;date&#039;, &#039;issue&#039;, &#039;fix&#039;, &#039;subst&#039;, &#039;hidden&#039;},&lt;br /&gt;
		allowSmall                  = true,&lt;br /&gt;
		smallParam                  = &#039;left&#039;,&lt;br /&gt;
		smallClass                  = &#039;mbox-small-left&#039;,&lt;br /&gt;
		substCheck                  = true,&lt;br /&gt;
		classes                     = {&#039;metadata&#039;, &#039;ambox&#039;},&lt;br /&gt;
		imageEmptyCell              = true,&lt;br /&gt;
		imageCheckBlank             = true,&lt;br /&gt;
		imageSmallSize              = &#039;20x20px&#039;,&lt;br /&gt;
		imageCellDiv                = true,&lt;br /&gt;
		useCollapsibleTextFields    = true,&lt;br /&gt;
		imageRightNone              = true,&lt;br /&gt;
		sectionDefault              = &#039;article&#039;,&lt;br /&gt;
		allowMainspaceCategories    = true,&lt;br /&gt;
		templateCategory            = &#039;Article message templates&#039;,&lt;br /&gt;
	        templateCategoryRequireName = true,&lt;br /&gt;
		templateErrorCategory       = &#039;Article message templates with missing parameters&#039;,&lt;br /&gt;
		templateErrorParamsToCheck  = {&#039;issue&#039;, &#039;fix&#039;, &#039;subst&#039;},&lt;br /&gt;
		removalNotice               = &#039;&amp;lt;small&amp;gt;[[Help:Maintenance template removal|Learn how and when to remove this message]]&amp;lt;/small&amp;gt;&#039;,&lt;br /&gt;
		templatestyles              = &#039;Module:Message box/ambox.css&#039;&lt;br /&gt;
	},&lt;br /&gt;
	&lt;br /&gt;
	cmbox = {&lt;br /&gt;
		types = {&lt;br /&gt;
			speedy = {&lt;br /&gt;
				class = &#039;cmbox-speedy&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			delete = {&lt;br /&gt;
				class = &#039;cmbox-delete&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			content = {&lt;br /&gt;
				class = &#039;cmbox-content&#039;,&lt;br /&gt;
				image = &#039;Ambox important.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			style = {&lt;br /&gt;
				class = &#039;cmbox-style&#039;,&lt;br /&gt;
				image = &#039;Edit-clear.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			move = {&lt;br /&gt;
				class = &#039;cmbox-move&#039;,&lt;br /&gt;
				image = &#039;Merge-split-transwiki default.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			protection = {&lt;br /&gt;
				class = &#039;cmbox-protection&#039;,&lt;br /&gt;
				image = &#039;Semi-protection-shackle-keyhole.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			notice = {&lt;br /&gt;
				class = &#039;cmbox-notice&#039;,&lt;br /&gt;
				image = &#039;Information icon4.svg&#039;&lt;br /&gt;
			}&lt;br /&gt;
		},&lt;br /&gt;
		default              = &#039;notice&#039;,&lt;br /&gt;
		showInvalidTypeError = true,&lt;br /&gt;
		classes              = {&#039;cmbox&#039;},&lt;br /&gt;
		imageEmptyCell       = true,&lt;br /&gt;
		templatestyles       = &#039;Module:Message box/cmbox.css&#039;,&lt;br /&gt;
		div_structure        = true,&lt;br /&gt;
	},&lt;br /&gt;
	&lt;br /&gt;
	fmbox = {&lt;br /&gt;
		types = {&lt;br /&gt;
			warning = {&lt;br /&gt;
				class = &#039;fmbox-warning&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			editnotice = {&lt;br /&gt;
				class = &#039;fmbox-editnotice&#039;,&lt;br /&gt;
				image = &#039;Information icon4.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			system = {&lt;br /&gt;
				class = &#039;fmbox-system&#039;,&lt;br /&gt;
				image = &#039;Information icon4.svg&#039;&lt;br /&gt;
			}&lt;br /&gt;
		},&lt;br /&gt;
		default              = &#039;system&#039;,&lt;br /&gt;
		showInvalidTypeError = true,&lt;br /&gt;
		classes              = {&#039;fmbox&#039;},&lt;br /&gt;
		imageEmptyCell       = false,&lt;br /&gt;
		imageRightNone       = false,&lt;br /&gt;
		templatestyles       = &#039;Module:Message box/fmbox.css&#039;,&lt;br /&gt;
		div_structure        = true,&lt;br /&gt;
	},&lt;br /&gt;
	&lt;br /&gt;
	imbox = {&lt;br /&gt;
		types = {&lt;br /&gt;
			speedy = {&lt;br /&gt;
				class = &#039;imbox-speedy&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			delete = {&lt;br /&gt;
				class = &#039;imbox-delete&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			content = {&lt;br /&gt;
				class = &#039;imbox-content&#039;,&lt;br /&gt;
				image = &#039;Ambox important.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			style = {&lt;br /&gt;
				class = &#039;imbox-style&#039;,&lt;br /&gt;
				image = &#039;Edit-clear.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			move = {&lt;br /&gt;
				class = &#039;imbox-move&#039;,&lt;br /&gt;
				image = &#039;Merge-split-transwiki default.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			protection = {&lt;br /&gt;
				class = &#039;imbox-protection&#039;,&lt;br /&gt;
				image = &#039;Semi-protection-shackle-keyhole.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			license = {&lt;br /&gt;
				class = &#039;imbox-license licensetpl&#039;,&lt;br /&gt;
				image = &#039;Imbox-license.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			[&amp;quot;license-related&amp;quot;] = {&lt;br /&gt;
				class = &#039;imbox-license&#039;,&lt;br /&gt;
				image = &#039;Imbox-license.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			featured = {&lt;br /&gt;
				class = &#039;imbox-featured&#039;,&lt;br /&gt;
				image = &#039;Cscr-featured.svg&#039;,&lt;br /&gt;
				imageNeedsLink = true&lt;br /&gt;
			},&lt;br /&gt;
			notice = {&lt;br /&gt;
				class = &#039;imbox-notice&#039;,&lt;br /&gt;
				image = &#039;Information icon4.svg&#039;&lt;br /&gt;
			}&lt;br /&gt;
		},&lt;br /&gt;
		default              = &#039;notice&#039;,&lt;br /&gt;
		showInvalidTypeError = true,&lt;br /&gt;
		classes              = {&#039;imbox&#039;},&lt;br /&gt;
		imageEmptyCell       = true,&lt;br /&gt;
		below                = true,&lt;br /&gt;
		templateCategory     = &#039;File message boxes&#039;,&lt;br /&gt;
		templatestyles       = &#039;Module:Message box/imbox.css&#039;,&lt;br /&gt;
		div_structure        = true,&lt;br /&gt;
	},&lt;br /&gt;
	&lt;br /&gt;
	ombox = {&lt;br /&gt;
		types = {&lt;br /&gt;
			speedy = {&lt;br /&gt;
				class = &#039;ombox-speedy&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			delete = {&lt;br /&gt;
				class = &#039;ombox-delete&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			content = {&lt;br /&gt;
				class = &#039;ombox-content&#039;,&lt;br /&gt;
				image = &#039;Ambox important.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			style = {&lt;br /&gt;
				class = &#039;ombox-style&#039;,&lt;br /&gt;
				image = &#039;Edit-clear.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			move = {&lt;br /&gt;
				class = &#039;ombox-move&#039;,&lt;br /&gt;
				image = &#039;Merge-split-transwiki default.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			protection = {&lt;br /&gt;
				class = &#039;ombox-protection&#039;,&lt;br /&gt;
				image = &#039;Semi-protection-shackle-keyhole.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			notice = {&lt;br /&gt;
				class = &#039;ombox-notice&#039;,&lt;br /&gt;
				image = &#039;Information icon4.svg&#039;&lt;br /&gt;
			}&lt;br /&gt;
		},&lt;br /&gt;
		default              = &#039;notice&#039;,&lt;br /&gt;
		showInvalidTypeError = true,&lt;br /&gt;
		classes              = {&#039;ombox&#039;},&lt;br /&gt;
		allowSmall           = true,&lt;br /&gt;
		imageEmptyCell       = true,&lt;br /&gt;
		imageRightNone       = true,&lt;br /&gt;
		templatestyles       = &#039;Module:Message box/ombox.css&#039;&lt;br /&gt;
	},&lt;br /&gt;
	&lt;br /&gt;
	tmbox = {&lt;br /&gt;
		types = {&lt;br /&gt;
			speedy = {&lt;br /&gt;
				class = &#039;tmbox-speedy&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			delete = {&lt;br /&gt;
				class = &#039;tmbox-delete&#039;,&lt;br /&gt;
				image = &#039;Ambox warning pn.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			content = {&lt;br /&gt;
				class = &#039;tmbox-content&#039;,&lt;br /&gt;
				image = &#039;Ambox important.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			style = {&lt;br /&gt;
				class = &#039;tmbox-style&#039;,&lt;br /&gt;
				image = &#039;Edit-clear.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			move = {&lt;br /&gt;
				class = &#039;tmbox-move&#039;,&lt;br /&gt;
				image = &#039;Merge-split-transwiki default.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			protection = {&lt;br /&gt;
				class = &#039;tmbox-protection&#039;,&lt;br /&gt;
				image = &#039;Semi-protection-shackle-keyhole.svg&#039;&lt;br /&gt;
			},&lt;br /&gt;
			notice = {&lt;br /&gt;
				class = &#039;tmbox-notice&#039;,&lt;br /&gt;
				image = &#039;Information icon4.svg&#039;&lt;br /&gt;
			}&lt;br /&gt;
		},&lt;br /&gt;
		default              = &#039;notice&#039;,&lt;br /&gt;
		showInvalidTypeError = true,&lt;br /&gt;
		classes              = {&#039;tmbox&#039;},&lt;br /&gt;
		allowSmall           = true,&lt;br /&gt;
		imageRightNone       = true,&lt;br /&gt;
		imageEmptyCell       = true,&lt;br /&gt;
		templateCategory     = &#039;Talk message boxes&#039;,&lt;br /&gt;
		templatestyles       = &#039;Module:Message box/tmbox.css&#039;&lt;br /&gt;
	}&lt;br /&gt;
}&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Message_box&amp;diff=11258</id>
		<title>Module:Message box</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Message_box&amp;diff=11258"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;require(&#039;strict&#039;)&lt;br /&gt;
local getArgs&lt;br /&gt;
local yesno = require(&#039;Module:Yesno&#039;)&lt;br /&gt;
local lang = mw.language.getContentLanguage()&lt;br /&gt;
&lt;br /&gt;
local CONFIG_MODULE = &#039;Module:Message box/configuration&#039;&lt;br /&gt;
local DEMOSPACES = {talk = &#039;tmbox&#039;, image = &#039;imbox&#039;, file = &#039;imbox&#039;, category = &#039;cmbox&#039;, article = &#039;ambox&#039;, main = &#039;ambox&#039;}&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
-- Helper functions&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local function getTitleObject(...)&lt;br /&gt;
	-- Get the title object, passing the function through pcall&lt;br /&gt;
	-- in case we are over the expensive function count limit.&lt;br /&gt;
	local success, title = pcall(mw.title.new, ...)&lt;br /&gt;
	if success then&lt;br /&gt;
		return title&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function union(t1, t2)&lt;br /&gt;
	-- Returns the union of two arrays.&lt;br /&gt;
	local vals = {}&lt;br /&gt;
	for i, v in ipairs(t1) do&lt;br /&gt;
		vals[v] = true&lt;br /&gt;
	end&lt;br /&gt;
	for i, v in ipairs(t2) do&lt;br /&gt;
		vals[v] = true&lt;br /&gt;
	end&lt;br /&gt;
	local ret = {}&lt;br /&gt;
	for k in pairs(vals) do&lt;br /&gt;
		table.insert(ret, k)&lt;br /&gt;
	end&lt;br /&gt;
	table.sort(ret)&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function getArgNums(args, prefix)&lt;br /&gt;
	local nums = {}&lt;br /&gt;
	for k, v in pairs(args) do&lt;br /&gt;
		local num = mw.ustring.match(tostring(k), &#039;^&#039; .. prefix .. &#039;([1-9]%d*)$&#039;)&lt;br /&gt;
		if num then&lt;br /&gt;
			table.insert(nums, tonumber(num))&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	table.sort(nums)&lt;br /&gt;
	return nums&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
-- Box class definition&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local MessageBox = {}&lt;br /&gt;
MessageBox.__index = MessageBox&lt;br /&gt;
&lt;br /&gt;
function MessageBox.new(boxType, args, cfg)&lt;br /&gt;
	args = args or {}&lt;br /&gt;
	local obj = {}&lt;br /&gt;
&lt;br /&gt;
	-- Set the title object and the namespace.&lt;br /&gt;
	obj.title = getTitleObject(args.page) or mw.title.getCurrentTitle()&lt;br /&gt;
&lt;br /&gt;
	-- Set the config for our box type.&lt;br /&gt;
	obj.cfg = cfg[boxType]&lt;br /&gt;
	if not obj.cfg then&lt;br /&gt;
		local ns = obj.title.namespace&lt;br /&gt;
		-- boxType is &amp;quot;mbox&amp;quot; or invalid input&lt;br /&gt;
		if args.demospace and args.demospace ~= &#039;&#039; then&lt;br /&gt;
			-- implement demospace parameter of mbox&lt;br /&gt;
			local demospace = string.lower(args.demospace)&lt;br /&gt;
			if DEMOSPACES[demospace] then&lt;br /&gt;
				-- use template from DEMOSPACES&lt;br /&gt;
				obj.cfg = cfg[DEMOSPACES[demospace]]&lt;br /&gt;
			elseif string.find( demospace, &#039;talk&#039; ) then&lt;br /&gt;
				-- demo as a talk page&lt;br /&gt;
				obj.cfg = cfg.tmbox&lt;br /&gt;
			else&lt;br /&gt;
				-- default to ombox&lt;br /&gt;
				obj.cfg = cfg.ombox&lt;br /&gt;
			end&lt;br /&gt;
		elseif ns == 0 then&lt;br /&gt;
			obj.cfg = cfg.ambox -- main namespace&lt;br /&gt;
		elseif ns == 6 then&lt;br /&gt;
			obj.cfg = cfg.imbox -- file namespace&lt;br /&gt;
		elseif ns == 14 then&lt;br /&gt;
			obj.cfg = cfg.cmbox -- category namespace&lt;br /&gt;
		else&lt;br /&gt;
			local nsTable = mw.site.namespaces[ns]&lt;br /&gt;
			if nsTable and nsTable.isTalk then&lt;br /&gt;
				obj.cfg = cfg.tmbox -- any talk namespace&lt;br /&gt;
			else&lt;br /&gt;
				obj.cfg = cfg.ombox -- other namespaces or invalid input&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Set the arguments, and remove all blank arguments except for the ones&lt;br /&gt;
	-- listed in cfg.allowBlankParams.&lt;br /&gt;
	do&lt;br /&gt;
		local newArgs = {}&lt;br /&gt;
		for k, v in pairs(args) do&lt;br /&gt;
			if v ~= &#039;&#039; then&lt;br /&gt;
				newArgs[k] = v&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		for i, param in ipairs(obj.cfg.allowBlankParams or {}) do&lt;br /&gt;
			newArgs[param] = args[param]&lt;br /&gt;
		end&lt;br /&gt;
		obj.args = newArgs&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Define internal data structure.&lt;br /&gt;
	obj.categories = {}&lt;br /&gt;
	obj.classes = {}&lt;br /&gt;
	-- For lazy loading of [[Module:Category handler]].&lt;br /&gt;
	obj.hasCategories = false&lt;br /&gt;
&lt;br /&gt;
	return setmetatable(obj, MessageBox)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:addCat(ns, cat, sort)&lt;br /&gt;
	if not cat then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	if sort then&lt;br /&gt;
		cat = string.format(&#039;[[Category:%s|%s]]&#039;, cat, sort)&lt;br /&gt;
	else&lt;br /&gt;
		cat = string.format(&#039;[[Category:%s]]&#039;, cat)&lt;br /&gt;
	end&lt;br /&gt;
	self.hasCategories = true&lt;br /&gt;
	self.categories[ns] = self.categories[ns] or {}&lt;br /&gt;
	table.insert(self.categories[ns], cat)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:addClass(class)&lt;br /&gt;
	if not class then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
	table.insert(self.classes, class)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:setParameters()&lt;br /&gt;
	local args = self.args&lt;br /&gt;
	local cfg = self.cfg&lt;br /&gt;
&lt;br /&gt;
	-- Get type data.&lt;br /&gt;
	self.type = args.type&lt;br /&gt;
	local typeData = cfg.types[self.type]&lt;br /&gt;
	self.invalidTypeError = cfg.showInvalidTypeError&lt;br /&gt;
		and self.type&lt;br /&gt;
		and not typeData&lt;br /&gt;
	typeData = typeData or cfg.types[cfg.default]&lt;br /&gt;
	self.typeClass = typeData.class&lt;br /&gt;
	self.typeImage = typeData.image&lt;br /&gt;
	self.typeImageNeedsLink = typeData.imageNeedsLink&lt;br /&gt;
&lt;br /&gt;
	-- Find if the box has been wrongly substituted.&lt;br /&gt;
	self.isSubstituted = cfg.substCheck and args.subst == &#039;SUBST&#039;&lt;br /&gt;
&lt;br /&gt;
	-- Find whether we are using a small message box.&lt;br /&gt;
	self.isSmall = cfg.allowSmall and (&lt;br /&gt;
		cfg.smallParam and args.small == cfg.smallParam&lt;br /&gt;
		or not cfg.smallParam and yesno(args.small)&lt;br /&gt;
	)&lt;br /&gt;
&lt;br /&gt;
	-- Set the below row.&lt;br /&gt;
	self.below = cfg.below and args.below&lt;br /&gt;
	&lt;br /&gt;
	-- Add attributes, classes and styles.&lt;br /&gt;
	self.id = args.id&lt;br /&gt;
	self.name = args.name&lt;br /&gt;
	if self.name then&lt;br /&gt;
		self:addClass(&#039;box-&#039; .. string.gsub(self.name,&#039; &#039;,&#039;_&#039;))&lt;br /&gt;
	end&lt;br /&gt;
	if yesno(args.plainlinks) ~= false then&lt;br /&gt;
		self:addClass(&#039;plainlinks&#039;)&lt;br /&gt;
	end&lt;br /&gt;
	if self.below then&lt;br /&gt;
		self:addClass(&#039;mbox-with-below&#039;)&lt;br /&gt;
	end&lt;br /&gt;
	for _, class in ipairs(cfg.classes or {}) do&lt;br /&gt;
		self:addClass(class)&lt;br /&gt;
	end&lt;br /&gt;
	if self.isSmall then&lt;br /&gt;
		self:addClass(cfg.smallClass or &#039;mbox-small&#039;)&lt;br /&gt;
	end&lt;br /&gt;
	self:addClass(self.typeClass)&lt;br /&gt;
	self:addClass(args.class)&lt;br /&gt;
	self.style = args.style&lt;br /&gt;
	self.attrs = args.attrs&lt;br /&gt;
&lt;br /&gt;
	-- Set text style.&lt;br /&gt;
	self.textstyle = args.textstyle&lt;br /&gt;
&lt;br /&gt;
	-- Set image classes.&lt;br /&gt;
	self.imageRightClass = args.imagerightclass or args.imageclass&lt;br /&gt;
	self.imageLeftClass = args.imageleftclass or args.imageclass&lt;br /&gt;
&lt;br /&gt;
	-- Find if we are on the template page or not. This functionality is only&lt;br /&gt;
	-- used if useCollapsibleTextFields is set, or if both cfg.templateCategory&lt;br /&gt;
	-- and cfg.templateCategoryRequireName are set.&lt;br /&gt;
	self.useCollapsibleTextFields = cfg.useCollapsibleTextFields&lt;br /&gt;
	if self.useCollapsibleTextFields&lt;br /&gt;
		or cfg.templateCategory&lt;br /&gt;
		and cfg.templateCategoryRequireName&lt;br /&gt;
	then&lt;br /&gt;
		if self.name then&lt;br /&gt;
			local templateName = mw.ustring.match(&lt;br /&gt;
				self.name,&lt;br /&gt;
				&#039;^[tT][eE][mM][pP][lL][aA][tT][eE][%s_]*:[%s_]*(.*)$&#039;&lt;br /&gt;
			) or self.name&lt;br /&gt;
			templateName = &#039;Template:&#039; .. templateName&lt;br /&gt;
			self.templateTitle = getTitleObject(templateName)&lt;br /&gt;
		end&lt;br /&gt;
		self.isTemplatePage = self.templateTitle&lt;br /&gt;
			and mw.title.equals(self.title, self.templateTitle)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Process data for collapsible text fields. At the moment these are only&lt;br /&gt;
	-- used in {{ambox}}.&lt;br /&gt;
	if self.useCollapsibleTextFields then&lt;br /&gt;
		-- Get the self.issue value.&lt;br /&gt;
		if self.isSmall and args.smalltext then&lt;br /&gt;
			self.issue = args.smalltext&lt;br /&gt;
		else&lt;br /&gt;
			local sect&lt;br /&gt;
			if args.sect == &#039;&#039; then&lt;br /&gt;
				sect = &#039;This &#039; .. (cfg.sectionDefault or &#039;page&#039;)&lt;br /&gt;
			elseif type(args.sect) == &#039;string&#039; then&lt;br /&gt;
				sect = &#039;This &#039; .. args.sect&lt;br /&gt;
			end&lt;br /&gt;
			local issue = args.issue&lt;br /&gt;
			issue = type(issue) == &#039;string&#039; and issue ~= &#039;&#039; and issue or nil&lt;br /&gt;
			local text = args.text&lt;br /&gt;
			text = type(text) == &#039;string&#039; and text or nil&lt;br /&gt;
			local issues = {}&lt;br /&gt;
			table.insert(issues, sect)&lt;br /&gt;
			table.insert(issues, issue)&lt;br /&gt;
			table.insert(issues, text)&lt;br /&gt;
			self.issue = table.concat(issues, &#039; &#039;)&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- Get the self.talk value.&lt;br /&gt;
		local talk = args.talk&lt;br /&gt;
		-- Show talk links on the template page or template subpages if the talk&lt;br /&gt;
		-- parameter is blank.&lt;br /&gt;
		if talk == &#039;&#039;&lt;br /&gt;
			and self.templateTitle&lt;br /&gt;
			and (&lt;br /&gt;
				mw.title.equals(self.templateTitle, self.title)&lt;br /&gt;
				or self.title:isSubpageOf(self.templateTitle)&lt;br /&gt;
			)&lt;br /&gt;
		then&lt;br /&gt;
			talk = &#039;#&#039;&lt;br /&gt;
		elseif talk == &#039;&#039; then&lt;br /&gt;
			talk = nil&lt;br /&gt;
		end&lt;br /&gt;
		if talk then&lt;br /&gt;
			-- If the talk value is a talk page, make a link to that page. Else&lt;br /&gt;
			-- assume that it&#039;s a section heading, and make a link to the talk&lt;br /&gt;
			-- page of the current page with that section heading.&lt;br /&gt;
			local talkTitle = getTitleObject(talk)&lt;br /&gt;
			local talkArgIsTalkPage = true&lt;br /&gt;
			if not talkTitle or not talkTitle.isTalkPage then&lt;br /&gt;
				talkArgIsTalkPage = false&lt;br /&gt;
				talkTitle = getTitleObject(&lt;br /&gt;
					self.title.text,&lt;br /&gt;
					mw.site.namespaces[self.title.namespace].talk.id&lt;br /&gt;
				)&lt;br /&gt;
			end&lt;br /&gt;
			if talkTitle and talkTitle.exists then&lt;br /&gt;
                local talkText&lt;br /&gt;
                if self.isSmall then&lt;br /&gt;
                    local talkLink = talkArgIsTalkPage and talk or (talkTitle.prefixedText .. (talk == &#039;#&#039; and &#039;&#039; or &#039;#&#039;) .. talk)&lt;br /&gt;
                    talkText = string.format(&#039;([[%s|talk]])&#039;, talkLink)&lt;br /&gt;
                else&lt;br /&gt;
                    talkText = &#039;Relevant discussion may be found on&#039;&lt;br /&gt;
                    if talkArgIsTalkPage then&lt;br /&gt;
                        talkText = string.format(&lt;br /&gt;
                            &#039;%s [[%s|%s]].&#039;,&lt;br /&gt;
                            talkText,&lt;br /&gt;
                            talk,&lt;br /&gt;
                            talkTitle.prefixedText&lt;br /&gt;
                        )&lt;br /&gt;
                    else&lt;br /&gt;
                        talkText = string.format(&lt;br /&gt;
                            &#039;%s the [[%s&#039; .. (talk == &#039;#&#039; and &#039;&#039; or &#039;#&#039;) .. &#039;%s|talk page]].&#039;,&lt;br /&gt;
                            talkText,&lt;br /&gt;
                            talkTitle.prefixedText,&lt;br /&gt;
                            talk&lt;br /&gt;
                        )&lt;br /&gt;
                    end&lt;br /&gt;
                end&lt;br /&gt;
				self.talk = talkText&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
&lt;br /&gt;
		-- Get other values.&lt;br /&gt;
		self.fix = args.fix ~= &#039;&#039; and args.fix or nil&lt;br /&gt;
		local date&lt;br /&gt;
		if args.date and args.date ~= &#039;&#039; then&lt;br /&gt;
			date = args.date&lt;br /&gt;
		elseif args.date == &#039;&#039; and self.isTemplatePage then&lt;br /&gt;
			date = lang:formatDate(&#039;F Y&#039;)&lt;br /&gt;
		end&lt;br /&gt;
		if date then&lt;br /&gt;
			self.date = string.format(&amp;quot; &amp;lt;span class=&#039;date-container&#039;&amp;gt;&amp;lt;i&amp;gt;(&amp;lt;span class=&#039;date&#039;&amp;gt;%s&amp;lt;/span&amp;gt;)&amp;lt;/i&amp;gt;&amp;lt;/span&amp;gt;&amp;quot;, date)&lt;br /&gt;
		end&lt;br /&gt;
		self.info = args.info&lt;br /&gt;
		if yesno(args.removalnotice) then&lt;br /&gt;
			self.removalNotice = cfg.removalNotice&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Set the non-collapsible text field. At the moment this is used by all box&lt;br /&gt;
	-- types other than ambox, and also by ambox when small=yes.&lt;br /&gt;
	if self.isSmall then&lt;br /&gt;
		self.text = args.smalltext or args.text&lt;br /&gt;
	else&lt;br /&gt;
		self.text = args.text&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- General image settings.&lt;br /&gt;
	self.imageCellDiv = not self.isSmall and cfg.imageCellDiv&lt;br /&gt;
	self.imageEmptyCell = cfg.imageEmptyCell&lt;br /&gt;
&lt;br /&gt;
	-- Left image settings.&lt;br /&gt;
	local imageLeft = self.isSmall and args.smallimage or args.image&lt;br /&gt;
	if cfg.imageCheckBlank and imageLeft ~= &#039;blank&#039; and imageLeft ~= &#039;none&#039;&lt;br /&gt;
		or not cfg.imageCheckBlank and imageLeft ~= &#039;none&#039;&lt;br /&gt;
	then&lt;br /&gt;
		self.imageLeft = imageLeft&lt;br /&gt;
		if not imageLeft then&lt;br /&gt;
			local imageSize = self.isSmall&lt;br /&gt;
				and (cfg.imageSmallSize or &#039;30x30px&#039;)&lt;br /&gt;
				or &#039;40x40px&#039;&lt;br /&gt;
			self.imageLeft = string.format(&#039;[[File:%s|%s%s|alt=]]&#039;, self.typeImage&lt;br /&gt;
				or &#039;Information icon4.svg&#039;, imageSize, self.typeImageNeedsLink and &amp;quot;&amp;quot; or &amp;quot;|link=&amp;quot; )&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Right image settings.&lt;br /&gt;
	local imageRight = self.isSmall and args.smallimageright or args.imageright&lt;br /&gt;
	if not (cfg.imageRightNone and imageRight == &#039;none&#039;) then&lt;br /&gt;
		self.imageRight = imageRight&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- set templatestyles&lt;br /&gt;
	self.base_templatestyles = cfg.templatestyles&lt;br /&gt;
	self.templatestyles = args.templatestyles&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:setMainspaceCategories()&lt;br /&gt;
	local args = self.args&lt;br /&gt;
	local cfg = self.cfg&lt;br /&gt;
&lt;br /&gt;
	if not cfg.allowMainspaceCategories then&lt;br /&gt;
		return nil&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local nums = {}&lt;br /&gt;
	for _, prefix in ipairs{&#039;cat&#039;, &#039;category&#039;, &#039;all&#039;} do&lt;br /&gt;
		args[prefix .. &#039;1&#039;] = args[prefix]&lt;br /&gt;
		nums = union(nums, getArgNums(args, prefix))&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- The following is roughly equivalent to the old {{Ambox/category}}.&lt;br /&gt;
	local date = args.date&lt;br /&gt;
	date = type(date) == &#039;string&#039; and date&lt;br /&gt;
	local preposition = &#039;from&#039;&lt;br /&gt;
	for _, num in ipairs(nums) do&lt;br /&gt;
		local mainCat = args[&#039;cat&#039; .. tostring(num)]&lt;br /&gt;
			or args[&#039;category&#039; .. tostring(num)]&lt;br /&gt;
		local allCat = args[&#039;all&#039; .. tostring(num)]&lt;br /&gt;
		mainCat = type(mainCat) == &#039;string&#039; and mainCat&lt;br /&gt;
		allCat = type(allCat) == &#039;string&#039; and allCat&lt;br /&gt;
		if mainCat and date and date ~= &#039;&#039; then&lt;br /&gt;
			local catTitle = string.format(&#039;%s %s %s&#039;, mainCat, preposition, date)&lt;br /&gt;
			self:addCat(0, catTitle)&lt;br /&gt;
			catTitle = getTitleObject(&#039;Category:&#039; .. catTitle)&lt;br /&gt;
			if not catTitle or not catTitle.exists then&lt;br /&gt;
				self:addCat(0, &#039;Articles with invalid date parameter in template&#039;)&lt;br /&gt;
			end&lt;br /&gt;
		elseif mainCat and (not date or date == &#039;&#039;) then&lt;br /&gt;
			self:addCat(0, mainCat)&lt;br /&gt;
		end&lt;br /&gt;
		if allCat then&lt;br /&gt;
			self:addCat(0, allCat)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:setTemplateCategories()&lt;br /&gt;
	local args = self.args&lt;br /&gt;
	local cfg = self.cfg&lt;br /&gt;
&lt;br /&gt;
	-- Add template categories.&lt;br /&gt;
	if cfg.templateCategory then&lt;br /&gt;
		if cfg.templateCategoryRequireName then&lt;br /&gt;
			if self.isTemplatePage then&lt;br /&gt;
				self:addCat(10, cfg.templateCategory)&lt;br /&gt;
			end&lt;br /&gt;
		elseif not self.title.isSubpage then&lt;br /&gt;
			self:addCat(10, cfg.templateCategory)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add template error categories.&lt;br /&gt;
	if cfg.templateErrorCategory then&lt;br /&gt;
		local templateErrorCategory = cfg.templateErrorCategory&lt;br /&gt;
		local templateCat, templateSort&lt;br /&gt;
		if not self.name and not self.title.isSubpage then&lt;br /&gt;
			templateCat = templateErrorCategory&lt;br /&gt;
		elseif self.isTemplatePage then&lt;br /&gt;
			local paramsToCheck = cfg.templateErrorParamsToCheck or {}&lt;br /&gt;
			local count = 0&lt;br /&gt;
			for i, param in ipairs(paramsToCheck) do&lt;br /&gt;
				if not args[param] then&lt;br /&gt;
					count = count + 1&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
			if count &amp;gt; 0 then&lt;br /&gt;
				templateCat = templateErrorCategory&lt;br /&gt;
				templateSort = tostring(count)&lt;br /&gt;
			end&lt;br /&gt;
			if self.categoryNums and #self.categoryNums &amp;gt; 0 then&lt;br /&gt;
				templateCat = templateErrorCategory&lt;br /&gt;
				templateSort = &#039;C&#039;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		self:addCat(10, templateCat, templateSort)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:setAllNamespaceCategories()&lt;br /&gt;
	-- Set categories for all namespaces.&lt;br /&gt;
	if self.invalidTypeError then&lt;br /&gt;
		local allSort = (self.title.namespace == 0 and &#039;Main:&#039; or &#039;&#039;) .. self.title.prefixedText&lt;br /&gt;
		self:addCat(&#039;all&#039;, &#039;Wikipedia message box parameter needs fixing&#039;, allSort)&lt;br /&gt;
	end&lt;br /&gt;
	if self.isSubstituted then&lt;br /&gt;
		self:addCat(&#039;all&#039;, &#039;Pages with incorrectly substituted templates&#039;)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:setCategories()&lt;br /&gt;
	if self.title.namespace == 0 then&lt;br /&gt;
		self:setMainspaceCategories()&lt;br /&gt;
	elseif self.title.namespace == 10 then&lt;br /&gt;
		self:setTemplateCategories()&lt;br /&gt;
	end&lt;br /&gt;
	self:setAllNamespaceCategories()&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:renderCategories()&lt;br /&gt;
	if not self.hasCategories then&lt;br /&gt;
		-- No categories added, no need to pass them to Category handler so,&lt;br /&gt;
		-- if it was invoked, it would return the empty string.&lt;br /&gt;
		-- So we shortcut and return the empty string.&lt;br /&gt;
		return &amp;quot;&amp;quot;&lt;br /&gt;
	end&lt;br /&gt;
	-- Convert category tables to strings and pass them through&lt;br /&gt;
	-- [[Module:Category handler]].&lt;br /&gt;
	return require(&#039;Module:Category handler&#039;)._main{&lt;br /&gt;
		main = table.concat(self.categories[0] or {}),&lt;br /&gt;
		template = table.concat(self.categories[10] or {}),&lt;br /&gt;
		all = table.concat(self.categories.all or {}),&lt;br /&gt;
		nocat = self.args.nocat,&lt;br /&gt;
		page = self.args.page&lt;br /&gt;
	}&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:exportDiv()&lt;br /&gt;
	local root = mw.html.create()&lt;br /&gt;
&lt;br /&gt;
	-- Add the subst check error.&lt;br /&gt;
	if self.isSubstituted and self.name then&lt;br /&gt;
		root:tag(&#039;b&#039;)&lt;br /&gt;
			:addClass(&#039;error&#039;)&lt;br /&gt;
			:wikitext(string.format(&lt;br /&gt;
				&#039;Template &amp;lt;code&amp;gt;%s[[Template:%s|%s]]%s&amp;lt;/code&amp;gt; has been incorrectly substituted.&#039;,&lt;br /&gt;
				mw.text.nowiki(&#039;{{&#039;), self.name, self.name, mw.text.nowiki(&#039;}}&#039;)&lt;br /&gt;
			))&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local frame = mw.getCurrentFrame()&lt;br /&gt;
	root:wikitext(frame:extensionTag{&lt;br /&gt;
		name = &#039;templatestyles&#039;,&lt;br /&gt;
		args = { src = self.base_templatestyles },&lt;br /&gt;
	})&lt;br /&gt;
	-- Add support for a single custom templatestyles sheet. Undocumented as&lt;br /&gt;
	-- need should be limited and many templates using mbox are substed; we&lt;br /&gt;
	-- don&#039;t want to spread templatestyles sheets around to arbitrary places&lt;br /&gt;
	if self.templatestyles then&lt;br /&gt;
		root:wikitext(frame:extensionTag{&lt;br /&gt;
			name = &#039;templatestyles&#039;,&lt;br /&gt;
			args = { src = self.templatestyles },&lt;br /&gt;
		})&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Create the box.&lt;br /&gt;
	local mbox = root:tag(&#039;div&#039;)&lt;br /&gt;
	mbox:attr(&#039;id&#039;, self.id or nil)&lt;br /&gt;
	for i, class in ipairs(self.classes or {}) do&lt;br /&gt;
		mbox:addClass(class or nil)&lt;br /&gt;
	end&lt;br /&gt;
	mbox&lt;br /&gt;
		:cssText(self.style or nil)&lt;br /&gt;
&lt;br /&gt;
	if self.attrs then&lt;br /&gt;
		mbox:attr(self.attrs)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local flex_container&lt;br /&gt;
	if self.below then&lt;br /&gt;
		-- we need to wrap the flex components (`image(right)` and `text`) in their&lt;br /&gt;
		-- own container div to support the `below` parameter&lt;br /&gt;
		flex_container = mw.html.create(&#039;div&#039;)&lt;br /&gt;
		flex_container:addClass(&#039;mbox-flex&#039;)&lt;br /&gt;
	else&lt;br /&gt;
		-- the mbox itself is the parent, so we need no HTML flex_container&lt;br /&gt;
		flex_container = mw.html.create()&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add the left-hand image.&lt;br /&gt;
	if self.imageLeft then&lt;br /&gt;
		local imageLeftCell = flex_container:tag(&#039;div&#039;):addClass(&#039;mbox-image&#039;)&lt;br /&gt;
		imageLeftCell&lt;br /&gt;
			:addClass(self.imageLeftClass)&lt;br /&gt;
			:wikitext(self.imageLeft or nil)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add the text.&lt;br /&gt;
	local textCell = flex_container:tag(&#039;div&#039;):addClass(&#039;mbox-text&#039;)&lt;br /&gt;
	if self.useCollapsibleTextFields then&lt;br /&gt;
		-- The message box uses advanced text parameters that allow things to be&lt;br /&gt;
		-- collapsible. At the moment, only ambox uses this.&lt;br /&gt;
		textCell:cssText(self.textstyle or nil)&lt;br /&gt;
		local textCellDiv = textCell:tag(&#039;div&#039;)&lt;br /&gt;
		textCellDiv&lt;br /&gt;
			:addClass(&#039;mbox-text-span&#039;)&lt;br /&gt;
			:wikitext(self.issue or nil)&lt;br /&gt;
		if (self.talk or self.fix) then&lt;br /&gt;
			textCellDiv:tag(&#039;span&#039;)&lt;br /&gt;
				:addClass(&#039;hide-when-compact&#039;)&lt;br /&gt;
				:wikitext(self.talk and (&#039; &#039; .. self.talk) or nil)&lt;br /&gt;
				:wikitext(self.fix and (&#039; &#039; .. self.fix) or nil)&lt;br /&gt;
		end&lt;br /&gt;
		textCellDiv:wikitext(self.date and (&#039; &#039; .. self.date) or nil)&lt;br /&gt;
		if self.info and not self.isSmall then&lt;br /&gt;
			textCellDiv&lt;br /&gt;
				:tag(&#039;span&#039;)&lt;br /&gt;
				:addClass(&#039;hide-when-compact&#039;)&lt;br /&gt;
				:wikitext(self.info and (&#039; &#039; .. self.info) or nil)&lt;br /&gt;
		end&lt;br /&gt;
		if self.removalNotice then&lt;br /&gt;
			textCellDiv:tag(&#039;span&#039;)&lt;br /&gt;
				:addClass(&#039;hide-when-compact&#039;)&lt;br /&gt;
				:tag(&#039;i&#039;)&lt;br /&gt;
					:wikitext(string.format(&amp;quot; (%s)&amp;quot;, self.removalNotice))&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		-- Default text formatting - anything goes.&lt;br /&gt;
		textCell&lt;br /&gt;
			:cssText(self.textstyle or nil)&lt;br /&gt;
			:wikitext(self.text or nil)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add the right-hand image.&lt;br /&gt;
	if self.imageRight then&lt;br /&gt;
		local imageRightCell = flex_container:tag(&#039;div&#039;):addClass(&#039;mbox-imageright&#039;)&lt;br /&gt;
		imageRightCell&lt;br /&gt;
			:addClass(self.imageRightClass)&lt;br /&gt;
			:wikitext(self.imageRight or nil)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	mbox:node(flex_container)&lt;br /&gt;
&lt;br /&gt;
	-- Add the below row.&lt;br /&gt;
	if self.below then&lt;br /&gt;
		mbox:tag(&#039;div&#039;)&lt;br /&gt;
			:addClass(&#039;mbox-text mbox-below&#039;)&lt;br /&gt;
			:cssText(self.textstyle or nil)&lt;br /&gt;
			:wikitext(self.below or nil)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add error message for invalid type parameters.&lt;br /&gt;
	if self.invalidTypeError then&lt;br /&gt;
		root:tag(&#039;div&#039;)&lt;br /&gt;
			:addClass(&#039;mbox-invalid-type&#039;)&lt;br /&gt;
			:wikitext(string.format(&lt;br /&gt;
				&#039;This message box is using an invalid &amp;quot;type=%s&amp;quot; parameter and needs fixing.&#039;,&lt;br /&gt;
				self.type or &#039;&#039;&lt;br /&gt;
			))&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add categories.&lt;br /&gt;
	root:wikitext(self:renderCategories() or nil)&lt;br /&gt;
&lt;br /&gt;
	return tostring(root)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function MessageBox:export()&lt;br /&gt;
&lt;br /&gt;
	local root = mw.html.create()&lt;br /&gt;
&lt;br /&gt;
	-- Add the subst check error.&lt;br /&gt;
	if self.isSubstituted and self.name then&lt;br /&gt;
		root:tag(&#039;b&#039;)&lt;br /&gt;
			:addClass(&#039;error&#039;)&lt;br /&gt;
			:wikitext(string.format(&lt;br /&gt;
				&#039;Template &amp;lt;code&amp;gt;%s[[Template:%s|%s]]%s&amp;lt;/code&amp;gt; has been incorrectly substituted.&#039;,&lt;br /&gt;
				mw.text.nowiki(&#039;{{&#039;), self.name, self.name, mw.text.nowiki(&#039;}}&#039;)&lt;br /&gt;
			))&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local frame = mw.getCurrentFrame()&lt;br /&gt;
	root:wikitext(frame:extensionTag{&lt;br /&gt;
		name = &#039;templatestyles&#039;,&lt;br /&gt;
		args = { src = self.base_templatestyles },&lt;br /&gt;
	})&lt;br /&gt;
	-- Add support for a single custom templatestyles sheet. Undocumented as&lt;br /&gt;
	-- need should be limited and many templates using mbox are substed; we&lt;br /&gt;
	-- don&#039;t want to spread templatestyles sheets around to arbitrary places&lt;br /&gt;
	if self.templatestyles then&lt;br /&gt;
		root:wikitext(frame:extensionTag{&lt;br /&gt;
			name = &#039;templatestyles&#039;,&lt;br /&gt;
			args = { src = self.templatestyles },&lt;br /&gt;
		})&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Create the box table.&lt;br /&gt;
	local boxTable = root:tag(&#039;table&#039;)&lt;br /&gt;
	boxTable:attr(&#039;id&#039;, self.id or nil)&lt;br /&gt;
	for i, class in ipairs(self.classes or {}) do&lt;br /&gt;
		boxTable:addClass(class or nil)&lt;br /&gt;
	end&lt;br /&gt;
	boxTable&lt;br /&gt;
		:cssText(self.style or nil)&lt;br /&gt;
		:attr(&#039;role&#039;, &#039;presentation&#039;)&lt;br /&gt;
&lt;br /&gt;
	if self.attrs then&lt;br /&gt;
		boxTable:attr(self.attrs)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add the left-hand image.&lt;br /&gt;
	local row = boxTable:tag(&#039;tr&#039;)&lt;br /&gt;
	if self.imageLeft then&lt;br /&gt;
		local imageLeftCell = row:tag(&#039;td&#039;):addClass(&#039;mbox-image&#039;)&lt;br /&gt;
		if self.imageCellDiv then&lt;br /&gt;
			-- If we are using a div, redefine imageLeftCell so that the image&lt;br /&gt;
			-- is inside it. Divs use style=&amp;quot;width: 52px;&amp;quot;, which limits the&lt;br /&gt;
			-- image width to 52px. If any images in a div are wider than that,&lt;br /&gt;
			-- they may overlap with the text or cause other display problems.&lt;br /&gt;
			imageLeftCell = imageLeftCell:tag(&#039;div&#039;):addClass(&#039;mbox-image-div&#039;)&lt;br /&gt;
		end&lt;br /&gt;
		imageLeftCell&lt;br /&gt;
			:addClass(self.imageLeftClass)&lt;br /&gt;
			:wikitext(self.imageLeft or nil)&lt;br /&gt;
	elseif self.imageEmptyCell then&lt;br /&gt;
		-- Some message boxes define an empty cell if no image is specified, and&lt;br /&gt;
		-- some don&#039;t. The old template code in templates where empty cells are&lt;br /&gt;
		-- specified gives the following hint: &amp;quot;No image. Cell with some width&lt;br /&gt;
		-- or padding necessary for text cell to have 100% width.&amp;quot;&lt;br /&gt;
		row:tag(&#039;td&#039;)&lt;br /&gt;
			:addClass(&#039;mbox-empty-cell&#039;)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add the text.&lt;br /&gt;
	local textCell = row:tag(&#039;td&#039;):addClass(&#039;mbox-text&#039;)&lt;br /&gt;
	if self.useCollapsibleTextFields then&lt;br /&gt;
		-- The message box uses advanced text parameters that allow things to be&lt;br /&gt;
		-- collapsible. At the moment, only ambox uses this.&lt;br /&gt;
		textCell:cssText(self.textstyle or nil)&lt;br /&gt;
		local textCellDiv = textCell:tag(&#039;div&#039;)&lt;br /&gt;
		textCellDiv&lt;br /&gt;
			:addClass(&#039;mbox-text-span&#039;)&lt;br /&gt;
			:wikitext(self.issue or nil)&lt;br /&gt;
		if (self.talk or self.fix) then&lt;br /&gt;
			textCellDiv:tag(&#039;span&#039;)&lt;br /&gt;
				:addClass(&#039;hide-when-compact&#039;)&lt;br /&gt;
				:wikitext(self.talk and (&#039; &#039; .. self.talk) or nil)&lt;br /&gt;
				:wikitext(self.fix and (&#039; &#039; .. self.fix) or nil)&lt;br /&gt;
		end&lt;br /&gt;
		textCellDiv:wikitext(self.date and (&#039; &#039; .. self.date) or nil)&lt;br /&gt;
		if self.info and not self.isSmall then&lt;br /&gt;
			textCellDiv&lt;br /&gt;
				:tag(&#039;span&#039;)&lt;br /&gt;
				:addClass(&#039;hide-when-compact&#039;)&lt;br /&gt;
				:wikitext(self.info and (&#039; &#039; .. self.info) or nil)&lt;br /&gt;
		end&lt;br /&gt;
		if self.removalNotice then&lt;br /&gt;
			textCellDiv:tag(&#039;span&#039;)&lt;br /&gt;
				:addClass(&#039;hide-when-compact&#039;)&lt;br /&gt;
				:tag(&#039;i&#039;)&lt;br /&gt;
					:wikitext(string.format(&amp;quot; (%s)&amp;quot;, self.removalNotice))&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		-- Default text formatting - anything goes.&lt;br /&gt;
		textCell&lt;br /&gt;
			:cssText(self.textstyle or nil)&lt;br /&gt;
			:wikitext(self.text or nil)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add the right-hand image.&lt;br /&gt;
	if self.imageRight then&lt;br /&gt;
		local imageRightCell = row:tag(&#039;td&#039;):addClass(&#039;mbox-imageright&#039;)&lt;br /&gt;
		if self.imageCellDiv then&lt;br /&gt;
			-- If we are using a div, redefine imageRightCell so that the image&lt;br /&gt;
			-- is inside it.&lt;br /&gt;
			imageRightCell = imageRightCell:tag(&#039;div&#039;):addClass(&#039;mbox-image-div&#039;)&lt;br /&gt;
		end&lt;br /&gt;
		imageRightCell&lt;br /&gt;
			:addClass(self.imageRightClass)&lt;br /&gt;
			:wikitext(self.imageRight or nil)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add the below row.&lt;br /&gt;
	if self.below then&lt;br /&gt;
		boxTable:tag(&#039;tr&#039;)&lt;br /&gt;
			:tag(&#039;td&#039;)&lt;br /&gt;
				:attr(&#039;colspan&#039;, self.imageRight and &#039;3&#039; or &#039;2&#039;)&lt;br /&gt;
				:addClass(&#039;mbox-text&#039;)&lt;br /&gt;
				:cssText(self.textstyle or nil)&lt;br /&gt;
				:wikitext(self.below or nil)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add error message for invalid type parameters.&lt;br /&gt;
	if self.invalidTypeError then&lt;br /&gt;
		root:tag(&#039;div&#039;)&lt;br /&gt;
			:addClass(&#039;mbox-invalid-type&#039;)&lt;br /&gt;
			:wikitext(string.format(&lt;br /&gt;
				&#039;This message box is using an invalid &amp;quot;type=%s&amp;quot; parameter and needs fixing.&#039;,&lt;br /&gt;
				self.type or &#039;&#039;&lt;br /&gt;
			))&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Add categories.&lt;br /&gt;
	root:wikitext(self:renderCategories() or nil)&lt;br /&gt;
&lt;br /&gt;
	return tostring(root)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
-- Exports&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local p, mt = {}, {}&lt;br /&gt;
&lt;br /&gt;
function p._exportClasses()&lt;br /&gt;
	-- For testing.&lt;br /&gt;
	return {&lt;br /&gt;
		MessageBox = MessageBox&lt;br /&gt;
	}&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.main(boxType, args, cfgTables)&lt;br /&gt;
	local box = MessageBox.new(boxType, args, cfgTables or mw.loadData(CONFIG_MODULE))&lt;br /&gt;
	box:setParameters()&lt;br /&gt;
	box:setCategories()&lt;br /&gt;
	-- DIV MIGRATION CONDITIONAL&lt;br /&gt;
	if box.cfg.div_structure then&lt;br /&gt;
		return box:exportDiv()&lt;br /&gt;
	end&lt;br /&gt;
	-- END DIV MIGRATION CONDITIONAL&lt;br /&gt;
	return box:export()&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function mt.__index(t, k)&lt;br /&gt;
	return function (frame)&lt;br /&gt;
		if not getArgs then&lt;br /&gt;
			getArgs = require(&#039;Module:Arguments&#039;).getArgs&lt;br /&gt;
		end&lt;br /&gt;
		return t.main(k, getArgs(frame, {trim = false, removeBlanks = false}))&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return setmetatable(p, mt)&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Main&amp;diff=11256</id>
		<title>Module:Main</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Main&amp;diff=11256"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;--[[&lt;br /&gt;
-- This module produces a link to a main article or articles. It implements the&lt;br /&gt;
-- template {{main}}.&lt;br /&gt;
-- &lt;br /&gt;
-- If the module is used in category or category talk space, it produces &amp;quot;The&lt;br /&gt;
-- main article for this category is xxx&amp;quot;. Otherwise, it produces&lt;br /&gt;
-- &amp;quot;Main article: xxx&amp;quot;.&lt;br /&gt;
--]]&lt;br /&gt;
&lt;br /&gt;
local mHatnote = require(&#039;Module:Hatnote&#039;)&lt;br /&gt;
local mTableTools -- lazily initialise&lt;br /&gt;
local mArguments -- lazily initialise&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	mTableTools = require(&#039;Module:TableTools&#039;)&lt;br /&gt;
	mArguments = require(&#039;Module:Arguments&#039;)&lt;br /&gt;
	local args = mArguments.getArgs(frame, {parentOnly = true})&lt;br /&gt;
	local pages = {}&lt;br /&gt;
	for k, v in pairs(args) do&lt;br /&gt;
		if type(k) == &#039;number&#039; then&lt;br /&gt;
			local display = args[&#039;l&#039; .. tostring(k)]&lt;br /&gt;
			local page = {v, display}&lt;br /&gt;
			pages[k] = page&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	pages = mTableTools.compressSparseArray(pages)&lt;br /&gt;
	local options = {&lt;br /&gt;
		selfref = args.selfref&lt;br /&gt;
	}&lt;br /&gt;
	return p._main(options, unpack(pages))&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._main(options, ...)&lt;br /&gt;
	-- Get the list of pages. If no first page was specified we use the current&lt;br /&gt;
	-- page name.&lt;br /&gt;
	local pages = {...}&lt;br /&gt;
	local currentTitle = mw.title.getCurrentTitle()&lt;br /&gt;
	local firstPageTable = pages[1]&lt;br /&gt;
	local firstPage&lt;br /&gt;
	if firstPageTable then&lt;br /&gt;
		firstPage = firstPageTable[1]&lt;br /&gt;
	else&lt;br /&gt;
		firstPage = currentTitle.text&lt;br /&gt;
		firstPageTable = {firstPage}&lt;br /&gt;
		pages[1] = firstPageTable&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Find the pagetype.&lt;br /&gt;
	local firstPageNs = mHatnote.findNamespaceId(firstPage)&lt;br /&gt;
	local pagetype = firstPageNs == 0 and &#039;article&#039; or &#039;page&#039;&lt;br /&gt;
&lt;br /&gt;
	-- Make the formatted link text&lt;br /&gt;
	local links = mHatnote.formatPageTables(unpack(pages))&lt;br /&gt;
	links = mw.text.listToText(links)&lt;br /&gt;
&lt;br /&gt;
	-- Build the text.&lt;br /&gt;
	local isPlural = #pages &amp;gt; 1&lt;br /&gt;
	local currentNs = currentTitle.namespace&lt;br /&gt;
	local isCategoryNamespace = currentNs - currentNs % 2 == 14&lt;br /&gt;
	local stringToFormat&lt;br /&gt;
	if isCategoryNamespace then&lt;br /&gt;
		if isPlural then&lt;br /&gt;
			stringToFormat = &#039;The main %ss for this&#039;&lt;br /&gt;
				.. &#039; [[Wikipedia:Categorization|category]] are %s&#039;&lt;br /&gt;
		else&lt;br /&gt;
			stringToFormat = &#039;The main %s for this&#039;&lt;br /&gt;
				.. &#039; [[Wikipedia:Categorization|category]] is %s&#039;&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		if isPlural then&lt;br /&gt;
			stringToFormat = &#039;Main %ss: %s&#039;&lt;br /&gt;
		else&lt;br /&gt;
			stringToFormat = &#039;Main %s: %s&#039;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	local text = string.format(stringToFormat, pagetype, links)&lt;br /&gt;
&lt;br /&gt;
	-- Process the options and pass the text to the _rellink function in&lt;br /&gt;
	-- [[Module:Hatnote]].&lt;br /&gt;
	options = options or {}&lt;br /&gt;
	local hnOptions = {&lt;br /&gt;
		extraclasses = &#039;relarticle mainarticle&#039;,&lt;br /&gt;
		selfref = options.selfref&lt;br /&gt;
	}&lt;br /&gt;
	return mHatnote._hatnote(text, hnOptions)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Lua_banner&amp;diff=11254</id>
		<title>Module:Lua banner</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Lua_banner&amp;diff=11254"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;-- This module implements the {{lua}} template.&lt;br /&gt;
local yesno = require(&#039;Module:Yesno&#039;)&lt;br /&gt;
local mList = require(&#039;Module:List&#039;)&lt;br /&gt;
local mTableTools = require(&#039;Module:TableTools&#039;)&lt;br /&gt;
local mMessageBox = require(&#039;Module:Message box&#039;)&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	local origArgs = frame:getParent().args&lt;br /&gt;
	local args = {}&lt;br /&gt;
	for k, v in pairs(origArgs) do&lt;br /&gt;
		v = v:match(&#039;^%s*(.-)%s*$&#039;)&lt;br /&gt;
		if v ~= &#039;&#039; then&lt;br /&gt;
			args[k] = v&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return p._main(args)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._main(args)&lt;br /&gt;
	local modules = mTableTools.compressSparseArray(args)&lt;br /&gt;
	local box = p.renderBox(modules)&lt;br /&gt;
	local trackingCategories = p.renderTrackingCategories(args, modules)&lt;br /&gt;
	return box .. trackingCategories&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.renderBox(modules)&lt;br /&gt;
	local boxArgs = {}&lt;br /&gt;
	if #modules &amp;lt; 1 then&lt;br /&gt;
		boxArgs.text = &#039;&amp;lt;strong class=&amp;quot;error&amp;quot;&amp;gt;Error: no modules specified&amp;lt;/strong&amp;gt;&#039;&lt;br /&gt;
	else&lt;br /&gt;
		local moduleLinks = {}&lt;br /&gt;
		for i, module in ipairs(modules) do&lt;br /&gt;
			moduleLinks[i] = string.format(&#039;[[:%s]]&#039;, module)&lt;br /&gt;
			local maybeSandbox = mw.title.new(module .. &#039;/sandbox&#039;)&lt;br /&gt;
			if maybeSandbox and maybeSandbox.exists then&lt;br /&gt;
				moduleLinks[i] = moduleLinks[i] .. string.format(&#039; ([[:%s|sandbox]])&#039;, maybeSandbox.fullText)&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		local moduleList = mList.makeList(&#039;bulleted&#039;, moduleLinks)&lt;br /&gt;
		local title = mw.title.getCurrentTitle()&lt;br /&gt;
		if title.subpageText == &amp;quot;doc&amp;quot; then&lt;br /&gt;
			title = title.basePageTitle&lt;br /&gt;
		end&lt;br /&gt;
		if title.contentModel == &amp;quot;Scribunto&amp;quot; then&lt;br /&gt;
			boxArgs.text = &#039;This module depends on the following other modules:&#039; .. moduleList&lt;br /&gt;
		else&lt;br /&gt;
			boxArgs.text = &#039;This template  uses [[Wikipedia:Lua|Lua]]:\n&#039; .. moduleList&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	boxArgs.type = &#039;notice&#039;&lt;br /&gt;
	boxArgs.small = true&lt;br /&gt;
	boxArgs.image = &#039;[[File:Lua-Logo.svg|30px|alt=|link=]]&#039;&lt;br /&gt;
	return mMessageBox.main(&#039;mbox&#039;, boxArgs)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.renderTrackingCategories(args, modules, titleObj)&lt;br /&gt;
	if yesno(args.nocat) then&lt;br /&gt;
		return &#039;&#039;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	local cats = {}&lt;br /&gt;
&lt;br /&gt;
	-- Error category&lt;br /&gt;
	if #modules &amp;lt; 1 then&lt;br /&gt;
		cats[#cats + 1] = &#039;Lua templates with errors&#039;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Lua templates category&lt;br /&gt;
	titleObj = titleObj or mw.title.getCurrentTitle()&lt;br /&gt;
	local subpageBlacklist = {&lt;br /&gt;
		doc = true,&lt;br /&gt;
		sandbox = true,&lt;br /&gt;
		sandbox2 = true,&lt;br /&gt;
		testcases = true&lt;br /&gt;
	}&lt;br /&gt;
	if not subpageBlacklist[titleObj.subpageText] then&lt;br /&gt;
		local protCatName&lt;br /&gt;
		if titleObj.namespace == 10 then&lt;br /&gt;
			local category = args.category&lt;br /&gt;
			if not category then&lt;br /&gt;
				local categories = {&lt;br /&gt;
					[&#039;Module:String&#039;] = &#039;Templates based on the String Lua module&#039;,&lt;br /&gt;
					[&#039;Module:Math&#039;] = &#039;Templates based on the Math Lua module&#039;,&lt;br /&gt;
					[&#039;Module:BaseConvert&#039;] = &#039;Templates based on the BaseConvert Lua module&#039;,&lt;br /&gt;
					[&#039;Module:Citation/CS1&#039;] = &#039;Templates based on the Citation/CS1 Lua module&#039;&lt;br /&gt;
				}&lt;br /&gt;
				category = modules[1] and categories[modules[1]]&lt;br /&gt;
				category = category or &#039;Lua-based templates&#039;&lt;br /&gt;
			end	&lt;br /&gt;
			cats[#cats + 1] = category&lt;br /&gt;
			protCatName = &amp;quot;Templates using under-protected Lua modules&amp;quot;&lt;br /&gt;
		elseif titleObj.namespace == 828 then&lt;br /&gt;
			protCatName = &amp;quot;Modules depending on under-protected modules&amp;quot;&lt;br /&gt;
		end&lt;br /&gt;
		if not args.noprotcat and protCatName then&lt;br /&gt;
			local protLevels = {&lt;br /&gt;
				autoconfirmed = 1,&lt;br /&gt;
				extendedconfirmed = 2,&lt;br /&gt;
				templateeditor = 3,&lt;br /&gt;
				sysop = 4&lt;br /&gt;
			}&lt;br /&gt;
			local currentProt&lt;br /&gt;
			if titleObj.id ~= 0 then&lt;br /&gt;
				-- id is 0 (page does not exist) if am previewing before creating a template.&lt;br /&gt;
				currentProt = titleObj.protectionLevels[&amp;quot;edit&amp;quot;][1]&lt;br /&gt;
			end&lt;br /&gt;
			if currentProt == nil then currentProt = 0 else currentProt = protLevels[currentProt] end&lt;br /&gt;
			for i, module in ipairs(modules) do&lt;br /&gt;
				if module ~= &amp;quot;WP:libraryUtil&amp;quot; then&lt;br /&gt;
					local moduleTitle = mw.title.new(module)&lt;br /&gt;
					local moduleProt = moduleTitle and moduleTitle.protectionLevels[&amp;quot;edit&amp;quot;][1]&lt;br /&gt;
					if moduleProt == nil then moduleProt = 0 else moduleProt = protLevels[moduleProt] end&lt;br /&gt;
					if moduleProt &amp;lt; currentProt then&lt;br /&gt;
						cats[#cats + 1] = protCatName&lt;br /&gt;
						break&lt;br /&gt;
					end&lt;br /&gt;
				end&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	for i, cat in ipairs(cats) do&lt;br /&gt;
		cats[i] = string.format(&#039;[[Category:%s]]&#039;, cat)&lt;br /&gt;
	end&lt;br /&gt;
	return table.concat(cats)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:List&amp;diff=11252</id>
		<title>Module:List</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:List&amp;diff=11252"/>
		<updated>2025-11-30T07:02:05Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;local libUtil = require(&#039;libraryUtil&#039;)&lt;br /&gt;
local checkType = libUtil.checkType&lt;br /&gt;
local mTableTools = require(&#039;Module:TableTools&#039;)&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
local listTypes = {&lt;br /&gt;
	[&#039;bulleted&#039;] = true,&lt;br /&gt;
	[&#039;unbulleted&#039;] = true,&lt;br /&gt;
	[&#039;horizontal&#039;] = true,&lt;br /&gt;
	[&#039;ordered&#039;] = true,&lt;br /&gt;
	[&#039;horizontal_ordered&#039;] = true&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function p.makeListData(listType, args)&lt;br /&gt;
	-- Constructs a data table to be passed to p.renderList.&lt;br /&gt;
	local data = {}&lt;br /&gt;
&lt;br /&gt;
	-- Classes and TemplateStyles&lt;br /&gt;
	data.classes = {}&lt;br /&gt;
	data.templatestyles = &#039;&#039;&lt;br /&gt;
	if listType == &#039;horizontal&#039; or listType == &#039;horizontal_ordered&#039; then&lt;br /&gt;
		table.insert(data.classes, &#039;hlist&#039;)&lt;br /&gt;
		data.templatestyles = mw.getCurrentFrame():extensionTag{&lt;br /&gt;
			name = &#039;templatestyles&#039;, args = { src = &#039;Hlist/styles.css&#039; }&lt;br /&gt;
		}&lt;br /&gt;
	elseif listType == &#039;unbulleted&#039; then&lt;br /&gt;
		table.insert(data.classes, &#039;plainlist&#039;)&lt;br /&gt;
		data.templatestyles = mw.getCurrentFrame():extensionTag{&lt;br /&gt;
			name = &#039;templatestyles&#039;, args = { src = &#039;Plainlist/styles.css&#039; }&lt;br /&gt;
		}&lt;br /&gt;
	end&lt;br /&gt;
	table.insert(data.classes, args.class)&lt;br /&gt;
&lt;br /&gt;
	-- Main div style&lt;br /&gt;
	data.style = args.style&lt;br /&gt;
&lt;br /&gt;
	-- Indent for horizontal lists&lt;br /&gt;
	if listType == &#039;horizontal&#039; or listType == &#039;horizontal_ordered&#039; then&lt;br /&gt;
		local indent = tonumber(args.indent)&lt;br /&gt;
		indent = indent and indent * 1.6 or 0&lt;br /&gt;
		if indent &amp;gt; 0 then&lt;br /&gt;
			data.marginLeft = indent .. &#039;em&#039;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- List style types for ordered lists&lt;br /&gt;
	-- This could be &amp;quot;1, 2, 3&amp;quot;, &amp;quot;a, b, c&amp;quot;, or a number of others. The list style&lt;br /&gt;
	-- type is either set by the &amp;quot;type&amp;quot; attribute or the &amp;quot;list-style-type&amp;quot; CSS&lt;br /&gt;
	-- property.&lt;br /&gt;
	if listType == &#039;ordered&#039; or listType == &#039;horizontal_ordered&#039; then &lt;br /&gt;
		data.listStyleType = args.list_style_type or args[&#039;list-style-type&#039;]&lt;br /&gt;
		data.type = args[&#039;type&#039;]&lt;br /&gt;
&lt;br /&gt;
		-- Detect invalid type attributes and attempt to convert them to&lt;br /&gt;
		-- list-style-type CSS properties.&lt;br /&gt;
		if data.type &lt;br /&gt;
			and not data.listStyleType&lt;br /&gt;
			and not tostring(data.type):find(&#039;^%s*[1AaIi]%s*$&#039;)&lt;br /&gt;
		then&lt;br /&gt;
			data.listStyleType = data.type&lt;br /&gt;
			data.type = nil&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- List tag type&lt;br /&gt;
	if listType == &#039;ordered&#039; or listType == &#039;horizontal_ordered&#039; then&lt;br /&gt;
		data.listTag = &#039;ol&#039;&lt;br /&gt;
	else&lt;br /&gt;
		data.listTag = &#039;ul&#039;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Start number for ordered lists&lt;br /&gt;
	data.start = args.start&lt;br /&gt;
	if listType == &#039;horizontal_ordered&#039; then&lt;br /&gt;
		-- Apply fix to get start numbers working with horizontal ordered lists.&lt;br /&gt;
		local startNum = tonumber(data.start)&lt;br /&gt;
		if startNum then&lt;br /&gt;
			data.counterReset = &#039;listitem &#039; .. tostring(startNum - 1)&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- List style&lt;br /&gt;
	 -- ul_style and ol_style are included for backwards compatibility. No&lt;br /&gt;
	 -- distinction is made for ordered or unordered lists.&lt;br /&gt;
	data.listStyle = args.list_style&lt;br /&gt;
&lt;br /&gt;
	-- List items&lt;br /&gt;
	-- li_style is included for backwards compatibility. item_style was included&lt;br /&gt;
	-- to be easier to understand for non-coders.&lt;br /&gt;
	data.itemStyle = args.item_style or args.li_style&lt;br /&gt;
	data.items = {}&lt;br /&gt;
	for _, num in ipairs(mTableTools.numKeys(args)) do&lt;br /&gt;
		local item = {}&lt;br /&gt;
		item.content = args[num]&lt;br /&gt;
		item.style = args[&#039;item&#039; .. tostring(num) .. &#039;_style&#039;]&lt;br /&gt;
			or args[&#039;item_style&#039; .. tostring(num)]&lt;br /&gt;
		item.value = args[&#039;item&#039; .. tostring(num) .. &#039;_value&#039;]&lt;br /&gt;
			or args[&#039;item_value&#039; .. tostring(num)]&lt;br /&gt;
		table.insert(data.items, item)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return data&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.renderList(data)&lt;br /&gt;
	-- Renders the list HTML.&lt;br /&gt;
	&lt;br /&gt;
	-- Return the blank string if there are no list items.&lt;br /&gt;
	if type(data.items) ~= &#039;table&#039; or #data.items &amp;lt; 1 then&lt;br /&gt;
		return &#039;&#039;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Render the main div tag.&lt;br /&gt;
	local root = mw.html.create(&#039;div&#039;)&lt;br /&gt;
	for _, class in ipairs(data.classes or {}) do&lt;br /&gt;
		root:addClass(class)&lt;br /&gt;
	end&lt;br /&gt;
	root:css{[&#039;margin-left&#039;] = data.marginLeft}&lt;br /&gt;
	if data.style then&lt;br /&gt;
		root:cssText(data.style)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Render the list tag.&lt;br /&gt;
	local list = root:tag(data.listTag or &#039;ul&#039;)&lt;br /&gt;
	list&lt;br /&gt;
		:attr{start = data.start, type = data.type}&lt;br /&gt;
		:css{&lt;br /&gt;
			[&#039;counter-reset&#039;] = data.counterReset,&lt;br /&gt;
			[&#039;list-style-type&#039;] = data.listStyleType&lt;br /&gt;
		}&lt;br /&gt;
	if data.listStyle then&lt;br /&gt;
		list:cssText(data.listStyle)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Render the list items&lt;br /&gt;
	for _, t in ipairs(data.items or {}) do&lt;br /&gt;
		local item = list:tag(&#039;li&#039;)&lt;br /&gt;
		if data.itemStyle then&lt;br /&gt;
			item:cssText(data.itemStyle)&lt;br /&gt;
		end&lt;br /&gt;
		if t.style then&lt;br /&gt;
			item:cssText(t.style)&lt;br /&gt;
		end&lt;br /&gt;
		item&lt;br /&gt;
			:attr{value = t.value}&lt;br /&gt;
			:wikitext(t.content)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	return data.templatestyles .. tostring(root)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.renderTrackingCategories(args)&lt;br /&gt;
	local isDeprecated = false -- Tracks deprecated parameters.&lt;br /&gt;
	for k, v in pairs(args) do&lt;br /&gt;
		k = tostring(k)&lt;br /&gt;
		if k:find(&#039;^item_style%d+$&#039;) or k:find(&#039;^item_value%d+$&#039;) then&lt;br /&gt;
			isDeprecated = true&lt;br /&gt;
			break&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	local ret = &#039;&#039;&lt;br /&gt;
	if isDeprecated then&lt;br /&gt;
		ret = ret .. &#039;[[Category:List templates with deprecated parameters]]&#039;&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.makeList(listType, args)&lt;br /&gt;
	if not listType or not listTypes[listType] then&lt;br /&gt;
		error(string.format(&lt;br /&gt;
			&amp;quot;bad argument #1 to &#039;makeList&#039; (&#039;%s&#039; is not a valid list type)&amp;quot;,&lt;br /&gt;
			tostring(listType)&lt;br /&gt;
		), 2)&lt;br /&gt;
	end&lt;br /&gt;
	checkType(&#039;makeList&#039;, 2, args, &#039;table&#039;)&lt;br /&gt;
	local data = p.makeListData(listType, args)&lt;br /&gt;
	local list = p.renderList(data)&lt;br /&gt;
	local trackingCategories = p.renderTrackingCategories(args)&lt;br /&gt;
	return list .. trackingCategories&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
for listType in pairs(listTypes) do&lt;br /&gt;
	p[listType] = function (frame)&lt;br /&gt;
		local mArguments = require(&#039;Module:Arguments&#039;)&lt;br /&gt;
		local origArgs = mArguments.getArgs(frame, {&lt;br /&gt;
			frameOnly = ((frame and frame.args and frame.args.frameonly or &#039;&#039;) ~= &#039;&#039;),&lt;br /&gt;
			valueFunc = function (key, value)&lt;br /&gt;
			if not value or not mw.ustring.find(value, &#039;%S&#039;) then return nil end&lt;br /&gt;
			if mw.ustring.find(value, &#039;^%s*[%*#;:]&#039;) then&lt;br /&gt;
				return value&lt;br /&gt;
			else&lt;br /&gt;
				return value:match(&#039;^%s*(.-)%s*$&#039;)&lt;br /&gt;
			end&lt;br /&gt;
			return nil&lt;br /&gt;
		end&lt;br /&gt;
		})&lt;br /&gt;
		-- Copy all the arguments to a new table, for faster indexing.&lt;br /&gt;
		local args = {}&lt;br /&gt;
		for k, v in pairs(origArgs) do&lt;br /&gt;
			args[k] = v&lt;br /&gt;
		end&lt;br /&gt;
		return p.makeList(listType, args)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Details&amp;diff=11250</id>
		<title>Module:Details</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Details&amp;diff=11250"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;--[[&lt;br /&gt;
-- This module produces a &amp;quot;For more details on this topic&amp;quot; link. It implements&lt;br /&gt;
-- the {{details}} template.&lt;br /&gt;
--]]&lt;br /&gt;
&lt;br /&gt;
local mHatnote = require(&#039;Module:Hatnote&#039;)&lt;br /&gt;
local mArguments -- lazily initialise&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
function p.details(frame)&lt;br /&gt;
	mArguments = require(&#039;Module:Arguments&#039;)&lt;br /&gt;
	local args = mArguments.getArgs(frame, {parentOnly = true})&lt;br /&gt;
	local page = args[1]&lt;br /&gt;
	local topic = args[2]&lt;br /&gt;
	if not page then&lt;br /&gt;
		return mHatnote.makeWikitextError(&lt;br /&gt;
			&#039;no page name specified&#039;,&lt;br /&gt;
			&#039;Template:Details#Errors&#039;,&lt;br /&gt;
			args.category&lt;br /&gt;
		)&lt;br /&gt;
	end&lt;br /&gt;
	local options = {&lt;br /&gt;
		selfref = args.selfref,&lt;br /&gt;
	}&lt;br /&gt;
	return p._details(page, topic, options)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._details(page, topic, options)&lt;br /&gt;
	page = mHatnote._formatLink(page)&lt;br /&gt;
	topic = topic or &#039;this topic&#039;&lt;br /&gt;
	local text = string.format(&#039;For more details on %s, see %s.&#039;, topic, page)&lt;br /&gt;
	options = options or {}&lt;br /&gt;
	options.extraclasses = &#039;boilerplate seealso&#039;&lt;br /&gt;
	return mHatnote._hatnote(text, options)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Module:Cat_main&amp;diff=11248</id>
		<title>Module:Cat main</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Module:Cat_main&amp;diff=11248"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;-- This module implements {{cat main}}.&lt;br /&gt;
&lt;br /&gt;
local mHatnote = require(&#039;Module:Hatnote&#039;)&lt;br /&gt;
local yesno = require(&#039;Module:Yesno&#039;)&lt;br /&gt;
local mTableTools -- lazily initialise&lt;br /&gt;
local mArguments -- lazily initialise&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
function p.catMain(frame)&lt;br /&gt;
	mTableTools = require(&#039;Module:TableTools&#039;)&lt;br /&gt;
	mArguments = require(&#039;Module:Arguments&#039;)&lt;br /&gt;
	local args = mArguments.getArgs(frame, {wrappers = &#039;Template:Cat main&#039;})&lt;br /&gt;
	local pages = mTableTools.compressSparseArray(args)&lt;br /&gt;
	local options = {&lt;br /&gt;
		article = args.article,&lt;br /&gt;
		selfref = args.selfref&lt;br /&gt;
	}&lt;br /&gt;
	return p._catMain(options, unpack(pages))&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._catMain(options, ...)&lt;br /&gt;
	options = options or {}&lt;br /&gt;
&lt;br /&gt;
	-- Get the links table.&lt;br /&gt;
	local links = mHatnote.formatPages(...)&lt;br /&gt;
	if not links[1] then&lt;br /&gt;
		local page = mw.title.getCurrentTitle().text&lt;br /&gt;
		links[1] = mHatnote._formatLink(page)&lt;br /&gt;
	end&lt;br /&gt;
	for i, link in ipairs(links) do&lt;br /&gt;
		links[i] = string.format(&amp;quot;&#039;&#039;&#039;%s&#039;&#039;&#039;&amp;quot;, link)&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Get the pagetype.&lt;br /&gt;
	local pagetype&lt;br /&gt;
	if yesno(options.article) ~= false then&lt;br /&gt;
		pagetype = &#039;article&#039;&lt;br /&gt;
	else&lt;br /&gt;
		pagetype = &#039;page&#039;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Work out whether we need to be singular or plural.&lt;br /&gt;
	local stringToFormat&lt;br /&gt;
	if #links &amp;gt; 1 then&lt;br /&gt;
		stringToFormat = &#039;The main %ss for this [[Help:Categories|category]] are %s.&#039;&lt;br /&gt;
	else&lt;br /&gt;
		stringToFormat = &#039;The main %s for this [[Help:Categories|category]] is %s.&#039;&lt;br /&gt;
	end&lt;br /&gt;
&lt;br /&gt;
	-- Get the text.&lt;br /&gt;
	local text = string.format(&lt;br /&gt;
		stringToFormat,&lt;br /&gt;
		pagetype,&lt;br /&gt;
		mw.text.listToText(links)&lt;br /&gt;
	)&lt;br /&gt;
	&lt;br /&gt;
	-- Pass it through to Module:Hatnote.&lt;br /&gt;
	local hnOptions = {}&lt;br /&gt;
	hnOptions.selfref = options.selfref&lt;br /&gt;
	hnOptions.extraclasses = &#039;relarticle mainarticle&#039;&lt;br /&gt;
&lt;br /&gt;
	return mHatnote._hatnote(text, hnOptions)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Xt&amp;diff=11246</id>
		<title>Template:Xt</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Xt&amp;diff=11246"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{#ifeq:{{NAMESPACE}}|{{ns:0}}|{{FormattingError|Template:xt is only for examples of style and formatting. Do not use it in actual articles.}}|&amp;lt;span class=&amp;quot;example good-example&amp;quot; style=&amp;quot;font-family: Georgia, &#039;DejaVu Serif&#039;, serif; color: #006400;&amp;quot; {{#if:{{{title|}}}|title=&amp;quot;{{{title}}}&amp;quot;}}&amp;gt;{{{1|Example text}}}&amp;lt;/span&amp;gt;}}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{Documentation}}&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Uselang&amp;diff=11244</id>
		<title>Template:Uselang</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Uselang&amp;diff=11244"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{#if: {{{lang|}}} | {{{lang|}}} | {{#ifeq: {{int:Lang}} | &amp;lt;Lang&amp;gt; | default | {{int:Lang}} }} }}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{Documentation}}&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Two_other_uses&amp;diff=11242</id>
		<title>Template:Two other uses</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Two_other_uses&amp;diff=11242"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{about|{{{1|}}}|{{{2|}}}|{{{3|}}}|{{{4|other uses}}}|{{{5|{{PAGENAME}} (disambiguation)}}}}}&amp;lt;noinclude&amp;gt;{{documentation}}&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Transclude&amp;diff=11240</id>
		<title>Template:Transclude</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Transclude&amp;diff=11240"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{#switch: {{NAMESPACE: {{{1}}} }}&lt;br /&gt;
 |#default = {{FULLPAGENAME: {{{1}}} }} &amp;lt;!-- eg &amp;quot;User:Foo&amp;quot; --&amp;gt;&lt;br /&gt;
 |{{ns:0}} = &lt;br /&gt;
    {{#ifeq: {{NAMESPACE: {{{1}}} }} | {{NAMESPACE: Template{{{1}}} }}&lt;br /&gt;
      | Template:{{{1}}}            &amp;lt;!-- no leading colon, eg &amp;quot;Foo&amp;quot; --&amp;gt;&lt;br /&gt;
      | {{PAGENAME: {{{1}}} }}      &amp;lt;!-- leading colon, eg &amp;quot;:Foo&amp;quot;, so we want the article --&amp;gt;&lt;br /&gt;
    }}&lt;br /&gt;
}}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{documentation}}&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Tlx&amp;diff=11238</id>
		<title>Template:Tlx</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Tlx&amp;diff=11238"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Template:Template link expanded]]&lt;br /&gt;
&lt;br /&gt;
{{Redirect category shell|&lt;br /&gt;
{{R from move}}&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Tlf&amp;diff=11236</id>
		<title>Template:Tlf</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Tlf&amp;diff=11236"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;span class=&amp;quot;nowrap&amp;quot;&amp;gt;&amp;amp;#123;&amp;amp;#123;{{#if:{{{1|}}}|{{{1}}}| tlf&amp;amp;#124;...}}&amp;lt;!--&lt;br /&gt;
--&amp;gt;{{#ifeq:{{{2|x}}}|{{{2|}}}| &amp;amp;#124;{{{2}}} | }}&amp;lt;!--&lt;br /&gt;
--&amp;gt;{{#ifeq:{{{3|x}}}|{{{3|}}}| &amp;amp;#124;{{{3}}} | }}&amp;lt;!--&lt;br /&gt;
--&amp;gt;{{#ifeq:{{{4|x}}}|{{{4|}}}| &amp;amp;#124;{{{4}}} | }}&amp;lt;!--&lt;br /&gt;
--&amp;gt;{{#ifeq:{{{5|x}}}|{{{5|}}}| &amp;amp;#124;{{{5}}} | }}&amp;lt;!--&lt;br /&gt;
--&amp;gt;{{#ifeq:{{{6|x}}}|{{{6|}}}| &amp;amp;#124;{{{6}}} | }}&amp;lt;!--&lt;br /&gt;
--&amp;gt;{{#ifeq:{{{7|x}}}|{{{7|}}}| &amp;amp;#124;{{{7}}} | }}&amp;lt;!--&lt;br /&gt;
--&amp;gt;{{#ifeq:{{{8|x}}}|{{{8|}}}| &amp;amp;#124;{{{8}}} | }}&amp;lt;!--&lt;br /&gt;
--&amp;gt;{{#ifeq:{{{9|x}}}|{{{9|}}}| &amp;amp;#124;{{{9}}} | }}&amp;lt;!--&lt;br /&gt;
--&amp;gt;&amp;amp;#125;&amp;amp;#125;&amp;lt;/span&amp;gt;&amp;lt;noinclude&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{documentation}}&lt;br /&gt;
&amp;lt;!-- Add categories and interwikis to the /doc sub-page, not here! --&amp;gt;&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Tl&amp;diff=11234</id>
		<title>Template:Tl</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Tl&amp;diff=11234"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;span class=&amp;quot;nowrap&amp;quot;&amp;gt;&amp;amp;#123;&amp;amp;#123;&amp;lt;/span&amp;gt;[[Template:{{{1}}}|{{{1}}}]]&amp;lt;span class=&amp;quot;nowrap&amp;quot;&amp;gt;&amp;amp;#125;&amp;amp;#125;&amp;lt;/span&amp;gt;&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{documentation}}&lt;br /&gt;
&amp;lt;!-- Categories go on the /doc subpage and interwikis go on Wikidata. --&amp;gt;&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Three_other_uses&amp;diff=11232</id>
		<title>Template:Three other uses</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Three_other_uses&amp;diff=11232"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{about|{{{1|}}}|{{{2|}}}|{{{3|}}}|{{{4|}}}|{{{5|}}}|{{{6|other uses}}}|{{{7|{{PAGENAME}} (disambiguation)}}}}}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Documentation}}&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:TemplateDataHeader&amp;diff=11230</id>
		<title>Template:TemplateDataHeader</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:TemplateDataHeader&amp;diff=11230"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div class=&amp;quot;templatedata-header&amp;quot;&amp;gt;{{#if:{{{noheader|}}}| |This is the [[Wikipedia:VisualEditor/TemplateData|TemplateData]] documentation for this template used by [[Wikipedia:VisualEditor|VisualEditor]] and other tools.}}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{{{1|{{BASEPAGENAME}}}}}&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;includeonly&amp;gt;{{#ifeq:{{SUBPAGENAME}}|sandbox||&lt;br /&gt;
[[Category:TemplateData documentation]]&lt;br /&gt;
}}&amp;lt;/includeonly&amp;gt;&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{Documentation}}&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Technical_reasons&amp;diff=11228</id>
		<title>Template:Technical reasons</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Technical_reasons&amp;diff=11228"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Hatnote|For [[Wikipedia:Naming conventions (technical restrictions)#Forbidden characters|technical reasons]], &amp;quot;{{{1}}}&amp;quot; redirects here. {{#if:{{{2|}}}|For {{#if:{{{3|}}}|{{{2|}}}|{{{1|}}}}}, see [[{{{3|{{{2|}}}}}}]].}} {{#if:{{{5|}}}|For {{{4}}}, see [[{{{5}}}]].}} {{#if:{{{7|}}}|For {{{6}}}, see [[{{{7}}}]].}} }}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Documentation}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:TOC_limit&amp;diff=11226</id>
		<title>Template:TOC limit</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:TOC_limit&amp;diff=11226"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div class=&amp;quot;toclimit-{{{1|{{{limit|3}}}}}}&amp;quot;&amp;gt;__TOC__&amp;lt;/div&amp;gt;&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{documentation}}&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:Succeeding_category&amp;diff=11224</id>
		<title>Template:Succeeding category</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:Succeeding_category&amp;diff=11224"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Hatnote|See also the succeeding [[:Category:{{{1|{{PAGENAME}}}}}]].}}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{documentation}}&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:See_also2&amp;diff=11222</id>
		<title>Template:See also2</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:See_also2&amp;diff=11222"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;includeonly&amp;gt;{{Hatnote|extraclasses=boilerplate seealso|{{{altphrase|See also}}}: {{#if:{{{1|}}} |&amp;lt;!--then:--&amp;gt;{{{1}}}|&amp;lt;!--else:--&amp;gt;&#039;&#039;&#039;Error: [[Template:See also2|Template must be given at least one article name]]&#039;&#039;&#039; &lt;br /&gt;
}}{{#if:{{{2|}}}|{{#if:{{{3|}}}|, |&amp;amp;nbsp;and }} {{{2}}}&lt;br /&gt;
}}{{#if:{{{3|}}}|{{#if:{{{4|}}}|, |,&amp;amp;nbsp;and }} {{{3}}}&lt;br /&gt;
}}{{#if:{{{4|}}}|{{#if:{{{5|}}}|, |,&amp;amp;nbsp;and }} {{{4}}}&lt;br /&gt;
}}{{#if:{{{5|}}}|{{#if:{{{6|}}}|, |,&amp;amp;nbsp;and }} {{{5}}}&lt;br /&gt;
}}{{#if:{{{6|}}}|{{#if:{{{7|}}}|, |,&amp;amp;nbsp;and }} {{{6}}}&lt;br /&gt;
}}{{#if:{{{7|}}}|{{#if:{{{8|}}}|, |,&amp;amp;nbsp;and }} {{{7}}}&lt;br /&gt;
}}{{#if:{{{8|}}}|{{#if:{{{9|}}}|, |,&amp;amp;nbsp;and }} {{{8}}}&lt;br /&gt;
}}{{#if:{{{9|}}}|{{#if:{{{10|}}}|, |,&amp;amp;nbsp;and }} {{{9}}}&lt;br /&gt;
}}{{#if:{{{10|}}}|{{#if:{{{11|}}}|, |,&amp;amp;nbsp;and }} {{{10}}}&lt;br /&gt;
}}{{#if:{{{11|}}}|{{#if:{{{12|}}}|, |,&amp;amp;nbsp;and }} {{{11}}}&lt;br /&gt;
}}{{#if:{{{12|}}}|{{#if:{{{13|}}}|, |,&amp;amp;nbsp;and }} {{{12}}}&lt;br /&gt;
}}{{#if:{{{13|}}}|{{#if:{{{14|}}}|, |,&amp;amp;nbsp;and }} {{{13}}}&lt;br /&gt;
}}{{#if:{{{14|}}}|{{#if:{{{15|}}}|, |,&amp;amp;nbsp;and }} {{{14}}}&lt;br /&gt;
}}{{#if:{{{15|}}}|,&amp;amp;nbsp;and {{{15}}}&lt;br /&gt;
}}{{#if:{{{16|}}}| &amp;amp;mdash; &#039;&#039;&#039;&amp;lt;br/&amp;gt;Error: [[Template:See also2|Too many links specified (maximum is 15)]]&#039;&#039;&#039;&lt;br /&gt;
}}}}&amp;lt;/includeonly&amp;gt;&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{documentation}}&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
	<entry>
		<id>https://www.drugwiki.net/wen/index.php?title=Template:See_also&amp;diff=11220</id>
		<title>Template:See also</title>
		<link rel="alternate" type="text/html" href="https://www.drugwiki.net/wen/index.php?title=Template:See_also&amp;diff=11220"/>
		<updated>2025-11-30T07:02:04Z</updated>

		<summary type="html">&lt;p&gt;Sysop: 1 revision imported&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;includeonly&amp;gt;{{#invoke:Labelled list hatnote|labelledList|See also}}&amp;lt;/includeonly&amp;gt;&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{documentation}}&lt;br /&gt;
&amp;lt;!-- Categories go on the /doc subpage, and interwikis go on Wikidata. --&amp;gt;&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Sysop</name></author>
	</entry>
</feed>