[Tiki-devel] Indentation Plugin

Volker Wysk <post-hhF2Jplw28UoZk/[email protected]>
Newsgroups gmane.comp.cms.tiki.devel
Message-ID <[email protected]>
Hi!

I've followed Brendan's advice (in tikiwiki-users) and built an indentation
plugin. This was easy - I've taken the PluginSup as a starting point.
However, I couldn't find documentation for some of the output parameters in
the wikiplugin_indent_info() function. I've commented them out and it
appears to work fine:


<?php
function wikiplugin_indent_info()
{
	return [
		'name' => tra('Indentation'),
		'documentation' => 'PluginIndent',
		'description' => tra('Indent a text block'),
		//'prefs' => [ 'wikiplugin_indent' ],
		'body' => tra('text'),
		//'iconname' => 'superscript',
		//'introduced' => 2,
		//'filter' => 'wikicontent',
		//'tags' => [ 'basic' ],
		'params' => [
		],
	];
}

function wikiplugin_indent($data, $params)
{
	return "<ul><li style=\"list-style-type:none\">$data</li></ul>";
}


(I've removed the copyright notice for clarity. The file is also attached,
with the copyright notice in place.)

Now I'm wondering what those five unknown output parameters do. I think this
plugin should be included in the next Tiki release. Therefore I want to do
it right.

I guess there must be documentation for them somewhere. I've found
documentation here:
http://dev.tiki.org/Hello+World#To_create_a_new_plugin . But it's
incomplete. Have I missed something?

Cheers,
Volker

_______________________________________________
TikiWiki-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel
wikiplugin_indent.php (application/x-php, 739 B)
<?php
// (c) Copyright by authors of the Tiki Wiki CMS Groupware Project
//
// All Rights Reserved. See copyright.txt for details and a complete list of authors.
// Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See license.txt for details.
// $Id$

function wikiplugin_indent_info()
{
	return [
		'name' => tra('Indentation'),
		'documentation' => 'PluginIndent',
		'description' => tra('Indent a text block'),
		//'prefs' => [ 'wikiplugin_indent' ],
		'body' => tra('text'),
		//'iconname' => 'superscript',
		//'introduced' => 2,
		//'filter' => 'wikicontent',
		//'tags' => [ 'basic' ],
		'params' => [
		],
	];
}

function wikiplugin_indent($data, $params)
{
	return "<ul><li style=\"list-style-type:none\">$data</li></ul>";
}
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEE6QXGh82Ov3+2nrxp+K4ydFOsHoUFAmClAZkACgkQ+K4ydFOs
HoU6CxAA0gPSZR1hwjBPKxaRgHRV0JgBo8RLLq5nb5YTfKd7QV+R0oHnih1lBAvW
HxApxf6ssdOUh/CqTJoLk4lYoL6AeBavUKxQWS9rfLi7eoKaK23YF7+f3jnPsC42
j38CKVRxrHCalxcRKcjLDrPGa/bAxkovzLyGcQdl2WUmDE2WA/ZtNHvDF61rZNip
2I1Ry5g1X9KS60qWb58He+Tx0R6s9uMTDVpoPIHjUtobGs4Pg86cPYyfZbB8zLFr
7Rh7GDH/gke0PRsP50H46DuVPzJfp0gHf6ZU9JSCtJ6n5716bQlI+6HaVEtAsPiP
UqTlKqQrOmDrQUl4oLtK0JOxmT0c2haZ8CMtBvZlg/TWSYB45Gergj4FdOKvIqqT
ysmWK2k6lIJwh90h+arRxSt/Z6r4maX2J+IrmNA58tLxHyPvkkW5PZksd004fQeP
jK4PwkDjK7Fve3Y7iH+DimJJvtwjGkBNZw0FAiLA1wvd0TZOwNf0ESFHBRNz3XOc
0Dl5oeHBsxjlmBLlnRGVQvcG48jD0n6wMCPkLRUEdZp2kh2nKWs3cc0cK/Ccl8I1
5C3ccWXCJe0mYTfhpRsmj3FjwX7g7tWrkLFMh2LJrmevOC5tJz4CKwS8dFrGxweL
Kcd3nTeqrkYhjRXN+JBtsQHHNmXDZHyOeP1orTN7cqnDKRNge8E=
=Q7A8
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.