{"id":15,"date":"2022-07-26T07:21:00","date_gmt":"2022-07-25T23:21:00","guid":{"rendered":"https:\/\/stackcms.dev\/docs\/?page_id=15"},"modified":"2022-11-17T09:52:07","modified_gmt":"2022-11-17T01:52:07","slug":"plugins","status":"publish","type":"page","link":"https:\/\/stackcms.dev\/docs\/configuration\/plugins\/","title":{"rendered":"Plugins"},"content":{"rendered":"<p class=\"heading\">This section will explain how to add PHP snippets or plugins to your Stack admin-created pages. Please do keep in mind that these pre-added plugins are only for your TCG&#8217;s basic need. If you want to add custom PHP codes to your admin-created page, kindly please refer to <a href=\"https:\/\/stackcms.dev\/docs\/customization\/\" rel=\"noopener\">Customization<\/a> for further information.<\/p>\n<div class=\"alert alert-primary\" role=\"alert\">Before saving an admin-created page with these plugins, make sure to retype any required single quotes on a specific plugin. The page will not work if the copied single quotes are in Sans Serif font instead of Monospace.<\/div>\n<table class=\"table table-hover\">\n<thead>\n<tr>\n<th scope=\"col\" width=\"45%\">Plugin Code<\/th>\n<th scope=\"col\">Usage<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td align=\"middle\">\n<blockquote class=\"code\" style=\"padding:15px !important; text-align:center;\"><p><em class=\"orange\">&lt;?php<\/em> <em class=\"purple\">echo<\/em> <em class=\"blue\">$plugin<\/em><em class=\"gray\">-&gt;<\/em><em class=\"orange\">plugLevels<\/em><em class=\"yellow\">()<\/em><em class=\"white\">;<\/em> <em class=\"orange\">?&gt;<\/em><\/p><\/blockquote>\n<p><em class=\"blue\"><br \/>\n<\/em><\/td>\n<td>Shows the complete list of your TCG&#8217;s levels in table format. It also shows the rewards for each level, which is good if you have multiple set of rewards per level tier.<\/td>\n<\/tr>\n<tr>\n<td align=\"middle\">\n<blockquote class=\"code\" style=\"padding:15px !important; text-align:center;\"><p><em class=\"orange\">&lt;?php<\/em> <em class=\"purple\">echo<\/em> <em class=\"blue\">$plugin<\/em><em class=\"gray\">-&gt;<\/em><em class=\"orange\">plugMastery<\/em><em class=\"yellow\">()<\/em><em class=\"white\">;<\/em> <em class=\"orange\">?&gt;<\/em><\/p><\/blockquote>\n<p><em class=\"blue\"><br \/>\n<\/em><\/td>\n<td>Shows the complete list of your deck mastery and special mastery rewards in table format, it includes member and event cards masteries if you allow this on your TCG.<\/td>\n<\/tr>\n<tr>\n<td align=\"middle\">\n<blockquote class=\"code\" style=\"padding:15px !important; text-align:center;\"><p><em class=\"orange\">&lt;?php<\/em> <em class=\"purple\">echo<\/em> <em class=\"blue\">$plugin<\/em><em class=\"gray\">-&gt;<\/em><em class=\"orange\">plugCurrency<\/em><em class=\"yellow\">(<\/em> <em class=\"green\">&#8216;PLUGGED&#8217;<\/em> <em class=\"yellow\">)<\/em><em class=\"white\">;<\/em> <em class=\"orange\">?&gt;<\/em><\/p><\/blockquote>\n<p><em class=\"blue\"><br \/>\n<\/em><\/td>\n<td>Shows the list of currencies for activity rewards such as deck mastery and level ups. The <code>PLUGGED<\/code> text must be replaced with the actual reward values from the database. To know the format of the rewarded currencies from the database, kindly refer to the <a href=\"..\/configuration\/reward-values\/\">Reward Values<\/a> list.<\/td>\n<\/tr>\n<tr>\n<td align=\"middle\">\n<blockquote class=\"code\" style=\"padding:15px !important; text-align:center;\"><p><em class=\"orange\">&lt;?php<\/em> <em class=\"purple\">echo<\/em> <em class=\"blue\">$plugin<\/em><em class=\"gray\">-&gt;<\/em><em class=\"orange\">plugAffiliates<\/em><em class=\"yellow\">(<\/em> <em class=\"green\">&#8216;general&#8217;<\/em> <em class=\"yellow\">)<\/em><em class=\"white\">;<\/em> <em class=\"orange\">?&gt;<\/em><\/p><\/blockquote>\n<p><em class=\"blue\"><br \/>\n<\/em><\/td>\n<td>Shows the list of your affiliates with images in no specific format but sorted by the affiliates&#8217; subject or name.<\/td>\n<\/tr>\n<tr>\n<td align=\"middle\">\n<blockquote class=\"code\" style=\"padding:15px !important; text-align:center;\"><p><em class=\"orange\">&lt;?php<\/em> <em class=\"purple\">echo<\/em> <em class=\"blue\">$plugin<\/em><em class=\"gray\">-&gt;<\/em><em class=\"orange\">plugAffiliates<\/em><em class=\"yellow\">(<\/em> <em class=\"green\">&#8216;table&#8217;<\/em> <em class=\"yellow\">)<\/em><em class=\"white\">;<\/em> <em class=\"orange\">?&gt;<\/em><\/p><\/blockquote>\n<p><em class=\"blue\"><br \/>\n<\/em><\/td>\n<td>Shows the list of your affiliates with images in table format. Sorted by the affiliates&#8217; subject or name, it will also display the affiliate&#8217;s owner and subject.<\/td>\n<\/tr>\n<tr>\n<td align=\"middle\">\n<blockquote class=\"code\" style=\"padding:15px !important; text-align:center;\"><p><em class=\"orange\">&lt;?php<\/em> <em class=\"purple\">echo<\/em> <em class=\"blue\">$plugin<\/em><em class=\"gray\">-&gt;<\/em><em class=\"orange\">plugAffiliates<\/em><em class=\"yellow\">(<\/em> <em class=\"green\">&#8216;form&#8217;<\/em> <em class=\"yellow\">)<\/em><em class=\"white\">;<\/em> <em class=\"orange\">?&gt;<\/em><\/p><\/blockquote>\n<p><em class=\"blue\"><br \/>\n<\/em><\/td>\n<td>Shows the form for applying for your TCG&#8217;s affiliation and it is pre-formatted in tables. If you want to customize how your affiliation form looks, kindly refer to <a href=\"https:\/\/stackcms.dev\/docs\/customization\/\" rel=\"noopener\">Customization<\/a> for further information.<\/td>\n<\/tr>\n<tr>\n<td align=\"middle\">\n<blockquote class=\"code\" style=\"padding:15px !important; text-align:center;\"><p><em class=\"orange\">&lt;?php<\/em> <em class=\"purple\">echo<\/em> <em class=\"blue\">$plugin<\/em><em class=\"gray\">-&gt;<\/em><em class=\"orange\">plugBadges<\/em><em class=\"yellow\">()<\/em><em class=\"white\">;<\/em> <em class=\"orange\">?&gt;<\/em><\/p><\/blockquote>\n<p><em class=\"blue\"><br \/>\n<\/em><\/td>\n<td>Shows the list of your available level badges for your TCG. It is sorted alphabetically by donators and players will need to click a set to view all the level badges for that specific set.<\/td>\n<\/tr>\n<tr>\n<td align=\"middle\">\n<blockquote class=\"code\" style=\"padding:15px !important; text-align:center;\"><p><em class=\"orange\">&lt;?php<\/em> <em class=\"purple\">echo<\/em> <em class=\"blue\">$plugin<\/em><em class=\"gray\">-&gt;<\/em><em class=\"orange\">plugMemberTasks<\/em><em class=\"yellow\">()<\/em><em class=\"white\">;<\/em> <em class=\"orange\">?&gt;<\/em><\/p><\/blockquote>\n<p><em class=\"blue\"><br \/>\n<\/em><\/td>\n<td>If you have the member deck feature enabled for your TCG, this plugin will show the list of available tasks that a member must complete in order to activate the card associated with a specific task. Please make sure to add the tasks first before using this plugin on any admin-created page, as this will return false or empty if the script detects an empty database table.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n","protected":false},"excerpt":{"rendered":"<p>This section will explain how to add PHP snippets or plugins to your Stack admin-created pages. Please do keep in mind that these pre-added plugins are only for your TCG&#8217;s basic need. If you want to add custom PHP codes to your admin-created page, kindly please refer to Customization for further information. Before saving an [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":14,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-15","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/stackcms.dev\/docs\/wp-json\/wp\/v2\/pages\/15","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/stackcms.dev\/docs\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/stackcms.dev\/docs\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/stackcms.dev\/docs\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/stackcms.dev\/docs\/wp-json\/wp\/v2\/comments?post=15"}],"version-history":[{"count":0,"href":"https:\/\/stackcms.dev\/docs\/wp-json\/wp\/v2\/pages\/15\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/stackcms.dev\/docs\/wp-json\/wp\/v2\/pages\/14"}],"wp:attachment":[{"href":"https:\/\/stackcms.dev\/docs\/wp-json\/wp\/v2\/media?parent=15"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}