WIKINDX METHODS

Method:
writeCreatorTable()

Class:
IMPORTCOMMON

Method Call:
include_once("core/file/import/IMPORTCOMMON.php");
$common = new IMPORTCOMMON($this->db);
INT $common->writeCreatorTable(STRING: $firstname, STRING: $initials, STRING: $prefix, STRING: $surname);

Description:
Write a creator name to the database and return the creator ID. If the creator already exists in the database, that creator's ID is returned, if not, the new creator is written to the database and the new ID returned. To not write any part ($surname is required), use either FALSE or an empty string. Any initials are expected to be space-delimited.

Once you have an ID back from this function, it needs to be written to the appropriate creatorx field of WKX_resource_creator for that resource.

Usage:
Example:
	include_once("core/file/import/IMPORTCOMMON.php");
	$common = new IMPORTCOMMON($this->db);
	$creatorId = $common->writeCreatorTable("Mickey", "W D", FALSE, "Mouse");

WIKINDX home      WIKINDX usage      WIKINDX classes