Skip to content
Provides a Tagfield for ProcessWire CMS Pages.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Provides a Tag field for ProcessWire CMS pages.


Just clone or put this into a folder and install the module from the module admin page of ProcessWire.

Getting Tags in Templates

Just access this field like any other field of ProcessWire. This field returns an normal PHP Array.


Retrieve tags related to the current page

// Fetch the tag field. Here it's called "Tags'.
$tags = $page->Tags;
foreach($tags as $tag) {
	echo "Tag: " . $tag;

Retrieve alphabetically sorted tags, frequency and related pages

// Retrieve the module
$tags = $this('modules')->get("FieldtypeTags");

// Fetch all tags and their frequency.
foreach($tags->getAllTags("Tags") as $field => $count) {
	echo "<h2>Tag \"{$field}\" (used {$count} times)</h2>";
	echo "<ul>";

	// Fetch all pages for a given tag
	foreach($tags->getPagesByTag($field) as $page) {
		echo "<li><a href=\"{$page->url}\">{$page->title}</a></li>";
	echo "</ul>";


As far as I know, there are currently no single input input fields that output arrays. Maybe you should consider to use the InputfieldTagify I created for this fieldtype.

You can’t perform that action at this time.