|
If it will make things easier though - in the remainder of this Tutorial - all __Plugins__ are __Liberty Data Plugins__.
|
|
-! How can a Plugin Add Functionallity?
|
-Easy! Here's a situation for you. You've just updated a page - and say "Not Bad - I just wish I had some ))EyeCandy(( to make this more noticable". Now if we were doing things the old fashioned way using pure HTML pages - there are literaly thousands of different things that could be easilly added to give you exactly the effect you want - providing you have the skill to add it. Bitweaver's pages are not like a pure HTML pages - but anything that works in an HTML page can be placed in a Plugin and will work in a bitweaver page.
|
+! How can a Plugin Add Functionality? |
+Easy! Here's a situation for you. You've just updated a page - and say "Not Bad - I just wish I had some ))EyeCandy(( to make this more noticeable". Now if we were doing things the old fashioned way using pure HTML pages - there are literally thousands of different things that could be easily added to give you exactly the effect you want - providing you have the skill to add it. Bitweaver's pages are not like a pure HTML pages - but anything that works in an HTML page can be placed in a Plugin and will work in a bitweaver page. |
The __"))EyeCandy(( ))NeonText((" (ECNT)__ Plugin is a very good example. It was written for two reasons:
|
# I renamed a finished a Proposed Plugin ((PluginProposal-HideText)) and wanted some ))EyeCandy(( to make a __Notice - It's Done__ statement.
|
# I decided to create the second Tutorial ((Tutorial - Liberty Plugins II)) and needed a good example for it.
|
__Note:__ The Plugin __"))EyeCandy(( ))NeonText((" (ECNT)__ applies a Neon Lighting Effect (an age old technique of attracting attention) to a string. The original source is a DHTML Script file from [http://www.dynamicdrive.com]. Of course - not everything is as simple as this was - but sometimes the simple things are the most rewarding.
|
|
! But I'm not a Computer Guru!
|
-You don't have to be. At the minimum - all that is required is a little knowledge of HTML / the PHP language / the ability to look things up / and the ability to experiment a little. Plugins can be as simple or as complex as you want to them to be. They provide an excelent place for a beginner to play and learn.
|
+You don't have to be. At the minimum - all that is required is a little knowledge of HTML / the PHP language / the ability to look things up / and the ability to experiment a little. Plugins can be as simple or as complex as you want to them to be. They provide an excellent place for a beginner to play and learn. |
|
^::__The Plugin "Comment" will be used as an example throughout this Tutorial.__::^
|
|
! What does this Plugin do?
|
The Comment Plugin is the simplest Plugin imaginable. All it does is - well - nothing. By doing "nothing" though - it allow text to be stored in a page that is not displayed or processed in any way.
|
! How is a Plugin Used?
|
-The __Comment__ Plugin allowes text to be stored in a page - and prevents it from being displayed. It is used like this: ~123~))COMMENT(( ~125~ The Text Inside the Block ~123~COMMENT~125~
|
+The __Comment__ Plugin allows text to be stored in a page - and prevents it from being displayed. It is used like this: ~123~))COMMENT(( ~125~ The Text Inside the Block ~123~COMMENT~125~ |
|
The Comment Plugin (unlike most Plugins) operates on the text encased between a pair of __Code Blocks__. A __Code Block__ is the __Key__ used to start the Plugin encased in curly brackets “{“ and “}” like this: ~123~))COMMENT(( ~125~
|
-__Parameters__ are used to make a Plugins more useful. They provide additional information / and control how the Plugin works. Parameters are added to the first code block in the form of __parameter_name=’value’__. This works because the Plugin defines each __Parameter__ that it will use and knows what to expecte. The __Value__ can be a single number (123456) / single words like TRUE / FALSE / or a ))KeyWord(( (again defined by the plugin). None of these __Has__ to be quoted. It can also be a __String__ - defined as:
|
-Any series of numbers or text that contains whitespaces or non-alphanumeric characters.
|
+__Parameters__ are used to make a Plugins more useful. They provide additional information / and control how the Plugin works. Parameters are added to the first code block in the form of __parameter_name=’value’__. This works because the Plugin defines each __Parameter__ that it will use and knows what to expect. The __Value__ can be a single number (123456) / single words like TRUE / FALSE / or a ))KeyWord(( (again defined by the Plugin). None of these __Has__ to be quoted. It can also be a __String__ - defined as: |
+Any series of numbers or text that contains white spaces or non-alphanumeric characters. |
__Must be Quoted__ - the quote character can be either a single quote or a double quote (characters ' or ").
|
|
-__Note:__ Capitolization is __Not__ manditory with the Plugins Key or with Parameter Names.
|
-~123~))COMMENT(( ~125~ = ~123~Comment ~125~ = ~123~comment ~125~ / and /
|
-))PARAMETER_NAME(( = ))Prameter_Name(( = ))parameter_name((
|
-With a Parameter's __Value__ - it could be!
|
+__Note:__ Capitalization is __Not__ mandatory with the Plugins Key or with Parameter Names. |
+__~123~))COMMENT(( ~125~ = ~123~Comment ~125~ = ~123~comment ~125~ / and / ))PARAMETER_NAME(( = ))Prameter_Name(( = ))parameter_name((__ |
+With the Parameter's __Value__ - it could be! |
! Where do I find the Plugins?
|
-The best way to become fluent with the Plugins is to use them. A complete listing of all Active Plugins can be found inside the __Page Editor__ at the bottom of the page. Look for the __Plugin Help__ tab. Selecting “More Details” shows the Plugin's Parameters and what they do. It should also show an example or two.
|
-The Files are stored in the Liberty/Plugins directory. The files use a strict file naming convention that must be adhered to. For our Example Plugin, the filename is “data.example.php”.
|
+The best way to become fluent with the Plugins is to use them. A complete listing of all Active Plugins can be found inside the __Page Editor__ at the bottom of the page. Look for the __Plugin Help__ tab. Selecting __“More Details”__ shows each of the Plugin's Parameters and explains what they do. Normally - an __Example__ or two is also given. |
+The Files are stored in the Liberty/Plugins directory. The files use a strict file naming convention that must be adhered to. For our Example Plugin, that filename is “data.example.php”. |
|
! Show me a Plugin then.
|
{CODE source=php num=on }<?php
|