Свойство | Тип | Описание | |
---|---|---|---|
$logsEmail | array | Email addresses to send logs. |
Метод | Описание | |
---|---|---|
createTmpFile ( ) : string | Create a temporary file that automatically gets deleted on __sleep() | |
formSubmit ( ) | Catch form submissions | |
import ( array $current_import ) : boolean | ||
isFormSubmission ( ) : boolean | Check if a user submitted something to options-general.php?page=pb_import | |
log ( string $message, array $more_info = [] ) | Log something using wp_mail() and error_log(), include useful WordPress info. | |
revokeCurrentImport ( ) : boolean | Delete 'pressbooks_current_import' option, delete the file too. | |
setCurrentImportOption ( array $upload ) : boolean | Mandatory setCurrentImportOption() method, creates WP option 'pressbooks_current_import' |
Метод | Описание | |
---|---|---|
determinePostType ( string $id ) : string | Check against what the user selected for post_type in our form | |
flaggedForImport ( $id ) : boolean | Check against what the user selected for import in our form | |
getChapterParent ( ) : integer | Get a valid Part id to act as post_parent to a Chapter | |
properImageExtension ( string $path_to_file, string $filename ) : string | Checks if the file extension matches its mimetype, returns a modified filename if they don't match. | |
tidy ( string $html ) : string | Tidy HTML |
public createTmpFile ( ) : string | ||
Результат | string | fullpath |
protected determinePostType ( string $id ) : string | ||
$id | string | |
Результат | string |
protected flaggedForImport ( $id ) : boolean | ||
$id | ||
Результат | boolean |
protected getChapterParent ( ) : integer | ||
Результат | integer |
static public isFormSubmission ( ) : boolean | ||
Результат | boolean |
public revokeCurrentImport ( ) : boolean | ||
Результат | boolean |
abstract public setCurrentImportOption ( array $upload ) : boolean | ||
$upload | array | An associative array of file attributes |
Результат | boolean |
static public array $logsEmail | ||
Результат | array |