TwistPHP Documentation

rename

File path: dist/twist/Core/Models/Database/Table.model.php
Namespace: Twist\Core\Models\Database
Extends:

renameRename the table to a new name withing your database, this command will only work if your database user has the RENAME privilege or above.

Parameters

Name Type Description
$strNewTablestringn/a

Return Values

void — No return information has been documented for this function.

Example

<?php
//Set the variables for the example
$strNewTable 'foo';

//Call the function rename with the example vars
$resTable = new \Twist\Core\Models\Database\Table();
$resTable -> rename($strNewTable);