Template:CardSearch: Difference between revisions
From LOTR-TCG Wiki
(Only the appropriate sites should appear when filtering by format) |
(A bit of tidying) |
||
Line 19: | Line 19: | ||
AND ("{{{textSearch|}}}" = "" OR CR.GameText LIKE "%{{{textSearch|}}}%") | AND ("{{{textSearch|}}}" = "" OR CR.GameText LIKE "%{{{textSearch|}}}%") | ||
AND ("{{{textRegexSearch|}}}" = "" OR CR.GameText RLIKE "{{#replace:{{{textRegexSearch|}}}|\|\\}}") | AND ("{{{textRegexSearch|}}}" = "" OR CR.GameText RLIKE "{{#replace:{{{textRegexSearch|}}}|\|\\}}") | ||
AND ("{{{culture|}}}" = "" OR "{{{culture|}}}" LIKE CONCAT('%', C.Culture, '%')) | AND ("{{{culture|}}}" = "" OR "{{{culture|}}}" LIKE CONCAT('%', C.Culture, '%')) | ||
Line 33: | Line 32: | ||
AND ("{{{usesItemClass|}}}" = "" OR CR.GameText RLIKE "({{#replace:{{#replace:{{#replace:{{#replace:{{{usesItemClass|}}}|,|{{!}}}}||}}|RangedWeapon|Ranged Weapon}}|HandWeapon|Hand Weapon}})" ) | AND ("{{{usesItemClass|}}}" = "" OR CR.GameText RLIKE "({{#replace:{{#replace:{{#replace:{{#replace:{{{usesItemClass|}}}|,|{{!}}}}||}}|RangedWeapon|Ranged Weapon}}|HandWeapon|Hand Weapon}})" ) | ||
AND ("{{{ | AND ("{{{phaseAction|}}}" = "" OR ((C.CardType IN ('Event') AND "{{{eventPhase|}}}" LIKE CONCAT('%', CR.Subtypes__full, '%')) OR CR.GameText RLIKE "({{#replace:{{#replace:{{{hasPhaseAction|}}}:|,|:{{!}}}}||}})")) | ||
AND ("{{{keyword|}}}" = "" OR CR.GameText RLIKE '(?<!\\w )({{#replace:{{#replace:{{#replace:{{#replace:{{{keyword|}}}|,|{{!}}}}||}}|+|XX \\+}}|XX|}})\\.' OR ("{{{keyword|}}}" LIKE '%Ring-bound%' AND (C.Title IN ('Frodo', 'Sam') OR CR.CanBearRing = 1)) OR ("{{{keyword|}}}" LIKE '%Unbound%' AND (C.CardType = 'Companion' AND C.Title NOT IN ('Frodo', 'Sam') AND CR.GameText NOT RLIKE '(?<!\\w )Ring-bound\\.')) OR ("{{{keyword|}}}" LIKE '%Ambush%' AND CR.GameText RLIKE '(?<!\\w )Ambush \\(\\d+\\)\\.') ) | AND ("{{{keyword|}}}" = "" OR CR.GameText RLIKE '(?<!\\w )({{#replace:{{#replace:{{#replace:{{#replace:{{{keyword|}}}|,|{{!}}}}||}}|+|XX \\+}}|XX|}})\\.' OR ("{{{keyword|}}}" LIKE '%Ring-bound%' AND (C.Title IN ('Frodo', 'Sam') OR CR.CanBearRing = 1)) OR ("{{{keyword|}}}" LIKE '%Unbound%' AND (C.CardType = 'Companion' AND C.Title NOT IN ('Frodo', 'Sam') AND CR.GameText NOT RLIKE '(?<!\\w )Ring-bound\\.')) OR ("{{{keyword|}}}" LIKE '%Ambush%' AND CR.GameText RLIKE '(?<!\\w )Ambush \\(\\d+\\)\\.') ) | ||
Line 63: | Line 60: | ||
AND ("{{{signet|}}}" = "" OR CR.Signet = "{{{signet|}}}") | AND ("{{{signet|}}}" = "" OR CR.Signet = "{{{signet|}}}") | ||
AND ("{{{sitesitenum|}}}" = "" OR (C.CardType = 'Site' AND CR.SiteNum = "{{{sitesitenum|}}}")) | AND ("{{{sitesitenum|}}}" = "" OR (C.CardType = 'Site' AND CR.SiteNum = "{{{sitesitenum|}}}")) | ||
AND ("{{{sitesitenumMore|}}}" = "" OR (C.CardType = 'Site' AND CR.SiteNum >= "{{{sitesitenumMore|}}}")) | AND ("{{{sitesitenumMore|}}}" = "" OR (C.CardType = 'Site' AND CR.SiteNum >= "{{{sitesitenumMore|}}}")) |
Revision as of 06:08, 19 November 2022
This is the "CardSearch" template.
It should be called in the following format:
{{CardSearch |isUnique= |sort= }}
Edit the page to see the template text.