mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2025-07-07 00:48:55 +00:00
jappixmini: include jappix source
This commit is contained in:
parent
61eb1f0d18
commit
302b2820d1
231 changed files with 96082 additions and 2 deletions
51
jappixmini/jappix/php/store-tree.php
Normal file
51
jappixmini/jappix/php/store-tree.php
Normal file
|
@ -0,0 +1,51 @@
|
|||
<?php
|
||||
|
||||
/*
|
||||
|
||||
Jappix - An open social platform
|
||||
This script (re)generates the store sub-folders (after an update)
|
||||
|
||||
-------------------------------------------------
|
||||
|
||||
License: AGPL
|
||||
Author: Vanaryon
|
||||
Last revision: 26/08/11
|
||||
|
||||
*/
|
||||
|
||||
// Someone is trying to hack us?
|
||||
if(!defined('JAPPIX_BASE'))
|
||||
exit;
|
||||
|
||||
// Array of the sub-folders to create
|
||||
$store_folders = array(
|
||||
'access',
|
||||
'avatars',
|
||||
'backgrounds',
|
||||
'cache',
|
||||
'conf',
|
||||
'logos',
|
||||
'logs',
|
||||
'music',
|
||||
'send',
|
||||
'share',
|
||||
'updates'
|
||||
);
|
||||
|
||||
// Creates the sub-folders
|
||||
for($i = 0; $i < count($store_folders); $i++) {
|
||||
$current = JAPPIX_BASE.'/store/'.$store_folders[$i];
|
||||
|
||||
// Create the folder itself
|
||||
if(!is_dir($current))
|
||||
mkdir($current, 0777, true);
|
||||
|
||||
chmod($current, 0777);
|
||||
|
||||
// Create the security file inside the folder
|
||||
$security_html = securityHTML();
|
||||
|
||||
file_put_contents($current.'/index.html', $security_html);
|
||||
}
|
||||
|
||||
?>
|
Loading…
Add table
Add a link
Reference in a new issue