skeleton for channel import
This commit is contained in:
parent
3216607e0f
commit
303c24b261
32
mod/import.php
Normal file
32
mod/import.php
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
// Import a channel, either by direct file upload or via
|
||||||
|
// connection to original server.
|
||||||
|
|
||||||
|
|
||||||
|
function import_post(&$a) {
|
||||||
|
|
||||||
|
$src = $_FILES['userfile']['tmp_name'];
|
||||||
|
$filename = basename($_FILES['userfile']['name']);
|
||||||
|
$filesize = intval($_FILES['userfile']['size']);
|
||||||
|
$filetype = $_FILES['userfile']['type'];
|
||||||
|
|
||||||
|
|
||||||
|
if(($src) && (! $filesize)) {
|
||||||
|
logger('mod_import: empty file.');
|
||||||
|
notice( t('Imported file is empty.');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function import_content(&$a) {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
@ -1 +1 @@
|
|||||||
2013-01-11.197
|
2013-01-12.198
|
||||||
|
Reference in New Issue
Block a user