当前位置: 首页>>代码示例>>PHP>>正文


PHP Plugin::registration方法代码示例

本文整理汇总了PHP中Plugin::registration方法的典型用法代码示例。如果您正苦于以下问题:PHP Plugin::registration方法的具体用法?PHP Plugin::registration怎么用?PHP Plugin::registration使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Plugin的用法示例。


在下文中一共展示了Plugin::registration方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "PagingLinks";
				// A short description, what the Plugin is for.
				$this->description = "Add previous page - next page links to the website.";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				// Every module can have its own and individual META-Data in NX. The following Handler is
				// for creating a META-Data-Template and for assigning it to the Plugin.
				// IF you do not want to declare an individual META-Scheme, then set $mtid=0 and delete
				// everything between del1 and /del1!


				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$mtid  = nextGUID();	      
	
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', $this->pluginType)");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:33,代码来源:pgn_paginglinks.php

示例2: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "Google Maps API";
				// A short description, what the Plugin is for.
				$this->description = "Google Maps API";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				/**** do not change from this point ****/
				$mtid = nextGUID(); // getting next GUID.
				//del1

				// SQL for creating the tables in the database. Do not call, if you do not need any tables in the database 
				
				// SQL for deleting the tables from the database. 
				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();				
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', 3)");				
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:32,代码来源:pgn_googlemaps.php

示例3: registration

           /**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;
            		$this->name = "BulkImage";
            		$this->description = "System-Extensions for importing images in archives.";
            		$this->version = 1;
			if ($auth->checkPermission("ADMINISTRATOR")) {
				Plugin::registration();
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, 0, '$classname', '$source', 3);");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:15,代码来源:pgn_bulkimage.php

示例4: registration

		/**
	     * Specifies information for installation and deinstallation of the plugin.
		 */
		function registration() {
			global $auth;	
			if ($auth->checkPermission("ADMINISTRATOR")) {
				Plugin::registration();
				$this->name = "E-Mail Obfuscator";
				$this->description = "Filters email-addresses form texts and recodes them to avoid spidering";
				$this->version = 1;
				$mtid = nextGUID(); // getting next GUID.
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', 4)");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:16,代码来源:pgn_emailobfuscator.php

示例5: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;	
			if ($auth->checkPermission("ADMINISTRATOR")) {
				Plugin::registration();
				$this->name = "CMS";
				$this->description = "CDS-API-Extension for creating, launching and editing Clusters.";
				$this->version = 1;
				$mtid = nextGUID(); // getting next GUID.
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', 3)");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:16,代码来源:pgn_cms.php

示例6: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;	
			if ($auth->checkPermission("ADMINISTRATOR")) {
				Plugin::registration();
				$this->name = "Rate";
				$this->description = "CDS-API-Extension for rating items.";
				$this->version = 1;
				$mtid = nextGUID(); // getting next GUID.
				$this->installHandler->addDBAction("CREATE TABLE `pgn_rating` (  `RATINGID` bigint(20) NOT NULL auto_increment,  `SOURCEID` bigint(20) NOT NULL default '0',  `VOTE` tinyint(4) NOT NULL default '0',  `COMMENT` text NOT NULL,  `timestamp` timestamp(14) NOT NULL,  PSEUDO varchar(64) null, EMail varchar(128) null, Published tinyint(1) not null default 0, PRIMARY KEY  (`RATINGID`)) TYPE=MyISAM AUTO_INCREMENT=1 ;");
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_rating`");
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', 3)");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:18,代码来源:pgn_rate.php

示例7: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "Knowledgebase";
				// A short description, what the Plugin is for.
				$this->description = "Knowledgebase for your website";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				// Every module can have its own and individual META-Data in NX. The following Handler is
				// for creating a META-Data-Template and for assigning it to the Plugin.
				// IF you do not want to declare an individual META-Scheme, then set $mtid=0 and delete
				// everything between del1 and /del1!

				/**** do not change from this point ****/
				$mtid = nextGUID(); // getting next GUID.

				// SQL for creating the tables in the database. Do not call, if you do not need any tables in the database 
				$sql1 = "CREATE TABLE `pgn_knowledgebase` (`ID` BIGINT NOT NULL ,`TITLE` VARCHAR( 255 ) NOT NULL ,`DESCRIPTION` TEXT NULL ,`UPDATEUSER` VARCHAR( 64 ) NULL ,`UPDATETIMESTAMP` DATETIME NULL ,`ENABLED` TINYINT( 1 ) NULL DEFAULT '0',PRIMARY KEY ( `ID` ))";							
				$sql2 = "CREATE TABLE `pgn_knowledgebase_tags` (`TAG_ID` BIGINT NOT NULL ,`TAG` CHAR( 32 ) NOT NULL ,`TAG_CAT` INT( 3 ) NOT NULL ,PRIMARY KEY ( `TAG_ID` ) ,INDEX ( `TAG` ) ) TYPE = MYISAM ;";
				$sql3 = "CREATE TABLE `pgn_knowledgebase_tag_relation` (`TAG_ID` BIGINT NOT NULL ,`FK_ID` BIGINT NOT NULL ,`POSITION` INT( 3 ) NULL ,INDEX ( `TAG_ID` , `FK_ID` ) ) TYPE = MYISAM ;";

				$this->installHandler->addDBAction($sql1);
				$this->installHandler->addDBAction($sql2);
				$this->installHandler->addDBAction($sql3);

				// SQL for deleting the tables from the database. 
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_knowledgebase`");
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_knowledgebase_tags`");
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_knowledgebase_tag_relation`");

				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', $this->pluginType)");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:47,代码来源:pgn_knowledgebase.php

示例8: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;
            		$this->name = "Calendar";
            		$this->description = "CDS-API-Extension for creating calendars.";
            		$this->version = 1;
			if ($auth->checkPermission("ADMINISTRATOR")) {
				Plugin::registration();
				$mtid = nextGUID(); // getting next GUID.
                		$this->installHandler->addDBAction("CREATE TABLE `pgn_cal_appointment` (  `APID` bigint(20) NOT NULL default '0',  `CALID` bigint(20) NOT NULL default '0',  `CATID` bigint(20) NOT NULL default '0',  `TITLE` varchar(255) NOT NULL default '',  `DESCRIPTION` longtext default NULL,  `STARTDATE` date NOT NULL default '0000-00-00',  `STARTTIME` time NOT NULL default '00:00:00',  `ENDDATE` date NOT NULL default '0000-00-00',  `ENDTIME` time NOT NULL default '00:00:00',  `IMAGE` bigint(20) default NULL,  `LINK` bigint(20) default NULL, `VERSION` tinyint(4) NOT NULL default '0',  PRIMARY KEY  (`APID`)) TYPE=MyISAM;");
                		$this->installHandler->addDBAction("CREATE TABLE `pgn_cal_calendars` (  `CALID` bigint(20) NOT NULL default '0',  `NAME` varchar(64) NOT NULL default '',  PRIMARY KEY  (`CALID`),  UNIQUE KEY `NAME` (`NAME`)) TYPE=MyISAM;");
                		$this->installHandler->addDBAction("CREATE TABLE `pgn_cal_categories` (  `CATID` bigint(20) NOT NULL default '0',  `CALID` bigint(20) NOT NULL default '0',  `NAME` varchar(64) NOT NULL default '',  `DESCRIPTION` varchar(255) default NULL, `COLOR` varchar(8) NOT NULL default '#ffffff',  PRIMARY KEY  (`CATID`)) TYPE=MyISAM;");
                		$id1 = nextGUID();
                		$this->installHandler->addDBAction("INSERT INTO `pgn_cal_calendars` (`CALID`, `NAME`) VALUES (".$id1.", 'My Calendar');");
                		$this->installHandler->addDBAction("INSERT INTO `pgn_cal_categories` (`CATID`, `CALID`, `NAME`, `DESCRIPTION`, `COLOR`) VALUES (".nextGUID().", $id1, 'Event', 'Events are public. All visitors are welcome.', '#f0f0f0');");
                		$this->uninstallHandler->addDBAction("DROP TABLE `pgn_cal_categories`");
                		$this->uninstallHandler->addDBAction("DROP TABLE `pgn_cal_calendars`");
                		$this->uninstallHandler->addDBAction("DROP TABLE `pgn_cal_appointment`");
                		$this->uninstallHandler->addDBAction("DELETE FROM temp_vars WHERE NAME='calsel'");
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', 3);");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:26,代码来源:pgn_calendar.php

示例9: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "Image";
				// A short description, what the Plugin is for.
				$this->description = "Image. Allowed formats are GIF, JPEG and PNG.";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				// Every module can have its own and individual META-Data in NX. The following Handler is
				// for creating a META-Data-Template and for assigning it to the Plugin.
				// IF you do not want to declare an individual META-Scheme, then set $mtid=0 and delete
				// everything between del1 and /del1!

				/**** do not change from this point ****/
				$mtid = nextGUID(); // getting next GUID.
				//del1
				$this->metaInstallHandler->addDBAction("INSERT INTO meta_templates (MT_ID, NAME, DESCRIPTION, INTERNAL) VALUES ($mtid, '$this->name PlugIn-Scheme', 'internally used for assigning $this->name plugin meta data', 1)");

				define("_TEXT", 1);
				define("_TEXTAREA", 2);
				define("_COLOR", 3);

				/**** add META-Data now ****/
				$guid = nextGUID();
				$this->metaInstallHandler->addDBAction("INSERT INTO meta_template_items (MTI_ID, MT_ID, NAME, POSITION, MTYPE_ID) VALUES($guid, $mtid, 'Image Description', 1, " . _TEXTAREA . ")");

				/**** end adding META-Data ****/
				// /del1

				// SQL for creating the tables in the database. Do not call, if you do not need any tables in the database 
				$this->installHandler->addDBAction("CREATE TABLE pgn_image (FKID bigint(20) NOT NULL default '0', FILENAME varchar(32) default NULL, ALT varchar(64) default NULL, WIDTH smallint(6) default NULL, HEIGHT smallint(6) default NULL, COPYRIGHT varchar(64) default NULL, PRIMARY KEY  (FKID), UNIQUE KEY FKID (FKID)) TYPE=MyISAM;");

				// SQL for deleting the tables from the database. 
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_image`");

				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname','$source')");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:52,代码来源:pgn_image.php

示例10: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "Quote";
				// A short description, what the Plugin is for.
				$this->description = "Quote of the day";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				// Every module can have its own and individual META-Data in NX. The following Handler is
				// for creating a META-Data-Template and for assigning it to the Plugin.
				// IF you do not want to declare an individual META-Scheme, then set $mtid=0 and delete
				// everything between del1 and /del1!

				/**** do not change from this point ****/
				$mtid = nextGUID(); // getting next GUID.
				$rlid = nextGUID(); // getting next GUID.

				// SQL for creating the tables in the database. Do not call, if you do not need any tables in the database 
				$sql1 = "CREATE TABLE pgn_quote ( QUOTE_ID bigint(20) NOT NULL default '0',  QUOTE text,  TITLE varchar(64) NOT NULL default '',  PRIMARY KEY  (QUOTE_ID))";

				$this->installHandler->addDBAction($sql1);
				$this->installHandler->addDBAction("INSERT INTO roles (ROLE_ID, ROLE_NAME, DESCRIPTION) VALUES ($rlid, 'Quoter', 'This role is for editing quotes.')");

				// SQL for deleting the tables from the database. 
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_quote`");
				$this->uninstallHandler->addDBAction("DELETE FROM roles WHERE ROLE_NAME = 'Quoter'");

				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', $this->pluginType)");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:44,代码来源:pgn_quote.php

示例11: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "File";
				// A short description, what the Plugin is for.
				$this->description = "File Uploads. Accepts all type of files.";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				// Every module can have its own and individual META-Data in NX. The following Handler is
				// for creating a META-Data-Template and for assigning it to the Plugin.
				// IF you do not want to declare an individual META-Scheme, then set $mtid=0 and delete
				// everything between del1 and /del1!
				$mtid = nextGUID();

				// SQL for creating the tables in the database. Do not call, if you do not need any tables in the database 
				$this->installHandler->addDBAction("CREATE TABLE `pgn_file` (`FKID` BIGINT NOT NULL ,`NAME` VARCHAR( 64 ) NOT NULL ,`DESCRIPTION` VARCHAR( 255 ) ,`FILENAME` VARCHAR( 255 ) ,`FILETYPE` VARCHAR( 32 ) ,`LOCATION` VARCHAR( 128 ), `DOWNLOADS` BIGINT ,PRIMARY KEY ( `FKID` ))");

				// SQL for deleting the tables from the database. 
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_file`");

				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname','$source')");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:37,代码来源:pgn_file.php

示例12: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "Linkexchange";
				// A short description, what the Plugin is for.
				$this->description = "Enables a visitor to place reciprocal links on his website.";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				// Every module can have its own and individual META-Data in NX. The following Handler is
				// for creating a META-Data-Template and for assigning it to the Plugin.
				// IF you do not want to declare an individual META-Scheme, then set $mtid=0 and delete
				// everything between del1 and /del1!


				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$mtid  = nextGUID();	      
				$this->installHandler->addDBAction("CREATE TABLE `pgn_linkexchange` (`ID` BIGINT NOT NULL , `SOURCEID` BIGINT NOT NULL, `TITLE` VARCHAR( 256 ) NULL ,`URL` VARCHAR( 256 ) NULL ,`DESCRIPTION` VARCHAR( 1024 ) NULL ,`INSERTTIMESTAMP` DATETIME NOT NULL ,`EMAIL` VARCHAR( 128 ) NULL ,`KEYWORDS` VARCHAR( 1024 ) NULL ,`USERNAME` VARCHAR( 64 ) NULL ,`PASSWORD` VARCHAR( 64 ) NULL ,`RECIPROCALURL` VARCHAR( 256 ) NULL,APPROVED TINYINT(1) NOT NULL DEFAULT 0 ,PRIMARY KEY ( `ID` )) ENGINE = MYISAM ;");
				
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', $this->pluginType)");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:34,代码来源:pgn_linkexchange.php

示例13: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "Code Sniplets";
				// A short description, what the Plugin is for.
				$this->description = "PHP, HTML or Javascript sniplets.";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				// Every module can have its own and individual META-Data in NX. The following Handler is
				// for creating a META-Data-Template and for assigning it to the Plugin.
				// IF you do not want to declare an individual META-Scheme, then set $mtid=0 and delete
				// everything between del1 and /del1!

				/**** do not change from this point ****/
				$mtid = nextGUID(); // getting next GUID.
				//del1


				/**** add META-Data now ****/
				$guid = nextGUID();
				

				/**** end adding META-Data ****/
				// /del1

				// SQL for creating the tables in the database. Do not call, if you do not need any tables in the database 
				$this->installHandler->addDBAction("CREATE TABLE `pgn_sniplet` (`FKID` BIGINT NOT NULL ,`SNIPLET` TEXT NULL, `SNIPLETTYPE` TINYINT NULL ) TYPE = MYISAM");

				// SQL for deleting the tables from the database. 
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_sniplet`");

				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE, MODULE_TYPE_ID) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source', $this->pluginType)");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:48,代码来源:pgn_sniplet.php

示例14: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "Adsense";
				// A short description, what the Plugin is for.
				$this->description = "Google Adsense Ad-Management Plugin.";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				/**** do not change from this point ****/
				$mtid = nextGUID(); // getting next GUID.
				//del1

				// SQL for creating the tables in the database. Do not call, if you do not need any tables in the database 
				$this->installHandler->addDBAction("CREATE TABLE `pgn_adsense` (`FKID` BIGINT NOT NULL ,`ADTEXT` TEXT NULL ,`IMPRESSIONS` BIGINT NOT NULL DEFAULT '0',`CLICKS` BIGINT NOT NULL DEFAULT '0',PRIMARY KEY ( `FKID` ) );");
				

				// SQL for deleting the tables from the database. 
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_adsense`");

				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source')");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:36,代码来源:pgn_adsense.php

示例15: registration

		/**
		   * Specifies information for installation and deinstallation of the plugin.
		   */
		function registration() {
			global $auth;

			// Authentification is require_onced for changing system configuration. Do not change.
			if ($auth->checkPermission("ADMINISTRATOR")) {

				// parent registration function for initializing. Do not change.
				Plugin::registration();

				// Name of the Plugin. The name will be displayed in the WCMS for selection
				$this->name = "FeedReader";
				// A short description, what the Plugin is for.
				$this->description = "ATOM and RSS FeedReader.";
				// Version of the plugin. Use integer numbers only. Is important for future releases.
				$this->version = 1;

				// Every module can have its own and individual META-Data in NX. The following Handler is
				// for creating a META-Data-Template and for assigning it to the Plugin.
				// IF you do not want to declare an individual META-Scheme, then set $mtid=0 and delete
				// everything between del1 and /del1!

				/**** do not change from this point ****/
				$mtid = nextGUID(); // getting next GUID.
				//del1
				/**** add META-Data now ****/
				$guid = nextGUID();
				/**** end adding META-Data ****/
				// /del1

				// SQL for creating the tables in the database. Do not call, if you do not need any tables in the database 
				$this->installHandler->addDBAction("CREATE TABLE `pgn_feeds` (`FKID` BIGINT NOT NULL ,`FEEDURL` VARCHAR( 256 ) NULL ,`SHOWLINKS` TINYINT( 1 ) NOT NULL DEFAULT '0',`CHANNEL_CAT` BIGINT NOT NULL DEFAULT '0',`CHANNEL_TEMPLATE` BIGINT NOT NULL DEFAULT '0',`CHANNEL_OVERVIEW_PAGE` BIGINT NOT NULL DEFAULT '0',PRIMARY KEY ( `FKID` ) ) ENGINE = MYISAM ;");

				// SQL for deleting the tables from the database. 
				$this->uninstallHandler->addDBAction("DROP TABLE `pgn_feeds`");

				/**** change nothing beyond this point ****/
				global $source, $classname; // the source path has to be provided by the calling template
				$modId = nextGUID();
				$this->installHandler->addDBAction("INSERT INTO modules (MODULE_ID, MODULE_NAME, DESCRIPTION, VERSION, MT_ID, CLASS, SOURCE) VALUES ($modId, '$this->name', '$this->description', $this->version, $mtid, '$classname', '$source')");
			}
		}
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:44,代码来源:pgn_feedreader.php


注:本文中的Plugin::registration方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。