├── .gitattributes ├── .gitignore ├── action_page.php ├── auto_restrict.php ├── config.php ├── config_page.php ├── design ├── actions.png ├── bladebo │ └── style.css ├── broken_noise.png ├── classic │ ├── actions.png │ ├── broken_noise.png │ ├── favicon2.png │ ├── foil.png │ ├── index.html │ ├── lined_paper.png │ ├── logo2.png │ ├── paper.png │ ├── style.css │ └── zip.png ├── favicon2.png ├── foil.png ├── index.html ├── lined_paper.png ├── logo2.png ├── paper.png ├── pinterest │ ├── broken_noise.png │ ├── favicon2.png │ ├── foil.png │ ├── fond.png │ ├── index.html │ ├── lined_paper.png │ ├── logo2.png │ ├── paper.png │ ├── style.css │ └── zip.png ├── style.css └── zip.png ├── index.php ├── login_form.php ├── mypersonaldata ├── index.html ├── private │ └── index.html ├── public │ └── index.html ├── tags.txt └── zipversions │ └── index.html ├── readme.md ├── readme.txt └── zip.php /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | 4 | # Custom for Visual Studio 5 | *.cs diff=csharp 6 | *.sln merge=union 7 | *.csproj merge=union 8 | *.vbproj merge=union 9 | *.fsproj merge=union 10 | *.dbproj merge=union 11 | 12 | # Standard to msysgit 13 | *.doc diff=astextplain 14 | *.DOC diff=astextplain 15 | *.docx diff=astextplain 16 | *.DOCX diff=astextplain 17 | *.dot diff=astextplain 18 | *.DOT diff=astextplain 19 | *.pdf diff=astextplain 20 | *.PDF diff=astextplain 21 | *.rtf diff=astextplain 22 | *.RTF diff=astextplain 23 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ################# 2 | ## Eclipse 3 | ################# 4 | 5 | *.pydevproject 6 | .project 7 | .metadata 8 | bin/ 9 | tmp/ 10 | *.tmp 11 | *.bak 12 | *.swp 13 | *~.nib 14 | local.properties 15 | .classpath 16 | .settings/ 17 | .loadpath 18 | 19 | # External tool builders 20 | .externalToolBuilders/ 21 | 22 | # Locally stored "Eclipse launch configurations" 23 | *.launch 24 | 25 | # CDT-specific 26 | .cproject 27 | 28 | # PDT-specific 29 | .buildpath 30 | 31 | 32 | ################# 33 | ## Visual Studio 34 | ################# 35 | 36 | ## Ignore Visual Studio temporary files, build results, and 37 | ## files generated by popular Visual Studio add-ons. 38 | 39 | # User-specific files 40 | *.suo 41 | *.user 42 | *.sln.docstates 43 | 44 | # Build results 45 | 46 | [Dd]ebug/ 47 | [Rr]elease/ 48 | x64/ 49 | build/ 50 | [Bb]in/ 51 | [Oo]bj/ 52 | 53 | # MSTest test Results 54 | [Tt]est[Rr]esult*/ 55 | [Bb]uild[Ll]og.* 56 | 57 | *_i.c 58 | *_p.c 59 | *.ilk 60 | *.meta 61 | *.obj 62 | *.pch 63 | *.pdb 64 | *.pgc 65 | *.pgd 66 | *.rsp 67 | *.sbr 68 | *.tlb 69 | *.tli 70 | *.tlh 71 | *.tmp 72 | *.tmp_proj 73 | *.log 74 | *.vspscc 75 | *.vssscc 76 | .builds 77 | *.pidb 78 | *.log 79 | *.scc 80 | 81 | # Visual C++ cache files 82 | ipch/ 83 | *.aps 84 | *.ncb 85 | *.opensdf 86 | *.sdf 87 | *.cachefile 88 | 89 | # Visual Studio profiler 90 | *.psess 91 | *.vsp 92 | *.vspx 93 | 94 | # Guidance Automation Toolkit 95 | *.gpState 96 | 97 | # ReSharper is a .NET coding add-in 98 | _ReSharper*/ 99 | *.[Rr]e[Ss]harper 100 | 101 | # TeamCity is a build add-in 102 | _TeamCity* 103 | 104 | # DotCover is a Code Coverage Tool 105 | *.dotCover 106 | 107 | # NCrunch 108 | *.ncrunch* 109 | .*crunch*.local.xml 110 | 111 | # Installshield output folder 112 | [Ee]xpress/ 113 | 114 | # DocProject is a documentation generator add-in 115 | DocProject/buildhelp/ 116 | DocProject/Help/*.HxT 117 | DocProject/Help/*.HxC 118 | DocProject/Help/*.hhc 119 | DocProject/Help/*.hhk 120 | DocProject/Help/*.hhp 121 | DocProject/Help/Html2 122 | DocProject/Help/html 123 | 124 | # Click-Once directory 125 | publish/ 126 | 127 | # Publish Web Output 128 | *.Publish.xml 129 | *.pubxml 130 | 131 | # NuGet Packages Directory 132 | ## TODO: If you have NuGet Package Restore enabled, uncomment the next line 133 | #packages/ 134 | 135 | # Windows Azure Build Output 136 | csx 137 | *.build.csdef 138 | 139 | # Windows Store app package directory 140 | AppPackages/ 141 | 142 | # Others 143 | sql/ 144 | *.Cache 145 | ClientBin/ 146 | [Ss]tyle[Cc]op.* 147 | ~$* 148 | *~ 149 | *.dbmdl 150 | *.[Pp]ublish.xml 151 | *.pfx 152 | *.publishsettings 153 | 154 | # RIA/Silverlight projects 155 | Generated_Code/ 156 | 157 | # Backup & report files from converting an old project file to a newer 158 | # Visual Studio version. Backup files are not needed, because we have git ;-) 159 | _UpgradeReport_Files/ 160 | Backup*/ 161 | UpgradeLog*.XML 162 | UpgradeLog*.htm 163 | 164 | # SQL Server files 165 | App_Data/*.mdf 166 | App_Data/*.ldf 167 | 168 | ############# 169 | ## Windows detritus 170 | ############# 171 | 172 | # Windows image file caches 173 | Thumbs.db 174 | ehthumbs.db 175 | 176 | # Folder config file 177 | Desktop.ini 178 | 179 | # Recycle Bin used on file shares 180 | $RECYCLE.BIN/ 181 | 182 | # Mac crap 183 | .DS_Store 184 | 185 | 186 | ############# 187 | ## Python 188 | ############# 189 | 190 | *.py[co] 191 | 192 | # Packages 193 | *.egg 194 | *.egg-info 195 | dist/ 196 | build/ 197 | eggs/ 198 | parts/ 199 | var/ 200 | sdist/ 201 | develop-eggs/ 202 | .installed.cfg 203 | 204 | # Installer logs 205 | pip-log.txt 206 | 207 | # Unit test / coverage reports 208 | .coverage 209 | .tox 210 | 211 | #Translations 212 | *.mo 213 | 214 | #Mr Developer 215 | .mr.developer.cfg 216 | -------------------------------------------------------------------------------- /action_page.php: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | the $_POST data was converted into a php config file 5 | 6 | 7 | 8 | 9 | Return to form and see the changes ! -------------------------------------------------------------------------------- /auto_restrict.php: -------------------------------------------------------------------------------- 1 | '); 37 | include('login_form.php');exit(); 38 | } 39 | else{ # On affiche un formulaire invitant à rentrer le mdp puis on exit le script 40 | include('login_form.php');exit(); 41 | } 42 | } 43 | // --------------------------------------------------------------------------------- 44 | 45 | 46 | // ------------------------------------------------------------------ 47 | 48 | // ------------------------------------------------------------------ 49 | // gestion de post pour demande de connexion 50 | // si un utilisateur tente de se loguer, on gère ici 51 | // ------------------------------------------------------------------ 52 | if (isset($_POST['login'])&&isset($_POST['pass'])){ 53 | log_user($_POST['login'],$_POST['pass']); 54 | if (isset($_POST['cookie'])){setcookie($auto_restrict['cookie_name'],sha1($_SERVER['HTTP_USER_AGENT']),time()+31104000);}//un an 55 | header('location: index.php'); 56 | } 57 | 58 | // ------------------------------------------------------------------ 59 | // si pas de demande de connexion on verifie les vars de session 60 | // et la duree d'inactivité de la session 61 | // si probleme,on include un form de login. 62 | // ------------------------------------------------------------------ 63 | if (!is_ok()){session_destroy();header('location: index.php?public');exit();} 64 | 65 | // ------------------------------------------------------------------ 66 | // demande de deco via la variable get 'deconnexion' 67 | // ------------------------------------------------------------------ 68 | if (isset($_GET['deconnexion'])){log_user($_POST['login'],$_POST['pass']);} 69 | // ------------------------------------------------------------------ 70 | //header('location: index.php?public'); 71 | 72 | 73 | 74 | 75 | // ------------------------------------------------------------------ 76 | // fonctions de cryptage 77 | // récupérées sur http://www.info-3000.com/phpmysql/cryptagedecryptage.php 78 | // ------------------------------------------------------------------ 79 | function GenerationCle($Texte,$CleDEncryptage) 80 | { 81 | $CleDEncryptage = md5($CleDEncryptage); 82 | $Compteur=0; 83 | $VariableTemp = ""; 84 | for ($Ctr=0;$Ctr -------------------------------------------------------------------------------- /config.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /config_page.php: -------------------------------------------------------------------------------- 1 | true, 20 | 'allow_user_to_config'=>false, 21 | 'adresse_du_site'=>'www.warriordudimanche.net', 22 | 'use_a_choice'=>'choice one',// current value: other values are defined below 23 | 'use_a_radiobutton_choice'=>'choice one',// current value: other values are defined below 24 | 'my_password'=>'password', 25 | 'confirm_password'=>'', 26 | 27 | );*/ 28 | //then render_form($config); 29 | 30 | 31 | /* ##################################################################### 32 | # auto_form config # 33 | ##################################################################### 34 | 35 | */ 36 | 37 | // here are the basic parameters 38 | $autoform_config=array( 39 | 'use_labels'=>true, 40 | 'use_placeholder'=>true, 41 | 'method'=>'post', 42 | 'action'=>'config_page.php', 43 | 'form_name'=>'autoform', 44 | 'form_id'=>'autoform', 45 | 'form_class'=>'autoform', 46 | 'enctype'=>'', 47 | 'submit_button_label'=>'Save changes', 48 | 'reset_button_label' 49 | ); 50 | 51 | foreach (glob('design/*') as $skin){ 52 | $skin=basename($skin);if ($skin!='index.html'){$skins[]=$skin;} 53 | } 54 | $autoform_config['skin']=$skins; 55 | $autoform_config['default_data_folder']=array('private','public'); 56 | 57 | /* ##################################################################### 58 | # the render function # 59 | ##################################################################### 60 | You can call it from anywhere in the page and render more than one form 61 | just call render_form($data_array)to create a brand new form with differents 62 | names, classes, ids etc. 63 | */ 64 | function render_form($var){ 65 | global $autoform_config;$all_keys=''; 66 | $id=$class=$enctype=$reset=''; 67 | if ($autoform_config['form_id']){$id=' id="'.$autoform_config['form_id'].'" ';} 68 | if ($autoform_config['form_class']){$class=' class="'.$autoform_config['form_class'].'" ';} 69 | if ($autoform_config['enctype']){$enctype=' enctype="'.$autoform_config['enctype'].'" ';} 70 | if (isset($autoform_config['reset_button_label'])){$reset="';} 71 | 72 | echo '
\n "; 73 | foreach($var as $key=>$value){ 74 | $all_keys.=$key.' | '; 75 | $txt=str_replace('_',' ',$key); 76 | $label=""; 77 | $idclasname="name='$key' id='$key' class='$key'"; 78 | // 79 | echo '
  • '; 80 | if (is_bool($value)){ 81 | // oh, a checkbox ! 82 | if ($value==true){$checked=' checked ';}else{$checked='';} 83 | echo $label; 84 | echo ""; 85 | } 86 | else{ 87 | if (!$autoform_config['use_labels']){$label='';} 88 | if (isset($autoform_config[$key])&&is_array($autoform_config[$key])){ 89 | // lists of choices 90 | if (isset($autoform_config[$key]['type'])&&$autoform_config[$key]['type']=='radio'){ 91 | unset($autoform_config[$key]['type']); 92 | 93 | // oh, a radiobutton list ! 94 | echo $txt.'
    '; 95 | echo "
      \n"; 96 | foreach ($autoform_config[$key] as $chkey=>$choice){ 97 | if ($choice==$value){$checked='checked';}else{$checked='';} 98 | echo "
    • \n"; 99 | } 100 | echo "
    \n"; 101 | 102 | }else{ 103 | // oh, a select input ! 104 | echo $label; 105 | echo "\n"; 111 | } 112 | }else if (isset($autoform_config[$key]) && $autoform_config[$key]=='pass'){ 113 | //oh, a password input ! 114 | echo $label; 115 | echo "\n"; 116 | 117 | }else{ 118 | // ok, so that's a text input... 119 | echo $label; 120 | if ($autoform_config['use_placeholder']){$placeholder=" placeholder='$txt'";}else{$placeholder='';} 121 | echo "\n"; 122 | } 123 | 124 | } 125 | echo "
  • \n"; 126 | } 127 | echo "\n";// this line to prevent unchecked boxes to desapear. 128 | echo ' $reset \n
    "; 129 | } 130 | include('auto_restrict.php'); 131 | include('config.php'); 132 | unset($GLOBAL['private_data_folder']); 133 | unset($GLOBAL['public_data_folder']); 134 | $GLOBAL['default_data_folder']=basename($GLOBAL['default_data_folder']); 135 | 136 | $message=''; 137 | if ($_POST){ 138 | $auto_form['filename']='config.php'; 139 | $auto_form['filecontent']=""; 156 | 157 | file_put_contents($auto_form['filename'],$auto_form['filecontent']); 158 | if ($postdata['data_folder']!=$GLOBAL['data_folder']){ rename ($GLOBAL['data_folder'],$postdata['data_folder']);} 159 | $message=' saved.'; 160 | unset($postdata['all_keys']); 161 | $GLOBAL=$postdata; 162 | } 163 | ?> 164 | 165 | 166 | 167 | 168 | 169 | Configuration 170 | 171 | 172 | 173 | 174 | 175 |
    176 | 179 |
    180 | 185 | 186 | -------------------------------------------------------------------------------- /design/actions.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/actions.png -------------------------------------------------------------------------------- /design/bladebo/style.css: -------------------------------------------------------------------------------- 1 | * { -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box; } 2 | body { 3 | background:url(paper.png) #efe; 4 | width: 100%; 5 | min-width:320px; 6 | margin:0;padding:0; 7 | font-family: Georgia, Serif;font-size : 13px; color: #050; 8 | } 9 | a:hover { color: #050;text-shadow:0 0 3px green;} 10 | 11 | a { color: black; text-decoration: none;} 12 | .icon{font-family:arial, sans-serif;display:inline-block;border-radius: 2px;margin:1px;height:16px;width:16px;border:solid 1px;font-size:10px;line-height:16px;font-weight: bold; text-align:center;} 13 | .private .icon{color:rgba(200,0,0,0.6);background-color:rgba(255,0,0,0.2);border-color:rgba(255,0,0,0.4);} 14 | .public .icon{color:rgba(0,200,0,0.6);background-color:rgba(0,255,0,0.2);border-color:rgba(0,255,0,0.4);} 15 | .private .icon:hover{color:rgba(200,0,0,1);background-color:rgba(255,0,0,0.5);border-color:rgba(255,0,0,0.8);text-shadow:none;box-shadow: 0 0 1px red} 16 | .public .icon:hover{color:rgba(0,200,0,1);background-color:rgba(0,255,0,0.5);border-color:rgba(0,255,0,0.8);text-shadow:none;box-shadow: 0 0 1px green} 17 | .public .icon.suppr:hover,.private .icon.suppr:hover{color:pink;background-color:rgba(255,0,0,0.9);border-color:rgba(255,0,0,1);} 18 | input{font-family: times,serif;outline:none; font-size:16px;border-radius: 3px; height:25px;padding : 3px ; vertical-align: bottom; margin-top : 3px ;} 19 | input[type=text]{width:80%;min-width:200px; background-color:rgba(255,255,255,0.8);border:1px solid #444;border-top-color:#333;border-bottom-color:#aaa; -moz-box-shadow: inset 0 1px 3px #000000; -webkit-box-shadow: inset 0 1px 3px #000000; box-shadow: inset 0 1px 3px #000000; } 20 | input[type=text]:hover{background-color:rgba(200,255,200,0.8);-moz-box-shadow: inset 0 1px 3px #040; -webkit-box-shadow: inset 0 1px 3px #040; box-shadow: inset 0 1px 3px #040; } 21 | input[type=text]:focus{background-color:rgba(200,255,200,0.9);-moz-box-shadow: inset 0 0 3px #040; -webkit-box-shadow: inset 0 0 3px #040; box-shadow: inset 0 0 3px #040; } 22 | input[type=submit]{border:1px solid green;cursor: pointer; color:lightgreen; text-shadow: 0 1px 1px darkgreen; display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(100,255,100,0.4);} 23 | input[type=submit]:hover{ background-color:rgba(0,255,0,0.8);} 24 | input[type=submit]:active{border-color:black; background-color:rgba(0,255,0,0.8);} 25 | #____q{margin-top:20px;} 26 | header{ 27 | 28 | -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; 29 | border-bottom:1px solid #222; 30 | -moz-box-shadow: 0 1px 3px #888; -webkit-box-shadow: 0 1px 3px #888; box-shadow: 0 1px 3px #888; -ms-filter: "progid:DXImageTransform.Microsoft.Shadow(Strength=2, Direction=135, Color='#888')"; filter: progid:DXImageTransform.Microsoft.Shadow(Strength=2, Direction=135, Color='#888'); 31 | padding : 10px ; width: 100%; height:auto;margin: 0; 32 | text-align: left;box-shadow: 0 1px 2px; 33 | filter: progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333)"; 34 | background-image: -moz-linear-gradient( top, #555, #333); background-image: -ms-linear-gradient( top, #555, #333); 35 | background-image: -o-linear-gradient( top, #555, #333); background-image: -webkit-gradient(linear, center top, center bottom, from(#555), to(#333)); background-image: -webkit-linear-gradient( top, #555, #333); background-image: linear-gradient( top, #555, #333); 36 | } 37 | header nav{display:inline-block; vertical-align: top;} 38 | header nav .zip{width:16px;height:16px; display:inline-block;background:url(zip.png) no-repeat;} 39 | header nav p{color:lightgreen;text-shadow: 0 1px 1px black;font-size:20px;} 40 | 41 | aside{height:100%;padding-bottom : 70px;text-align:center;} 42 | aside iframe{height:100%;border:none;} 43 | aside ul{padding:0;} 44 | aside li{margin:5px;list-style:none;vertical-align:middle;border-radius:3px;} 45 | aside li .tag{font-size:10px;display:inline-block;padding:2px;border-radius:3px;} 46 | nav .tag_public{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(100,255,100,0.4);color:green;text-shadow:0 1px 1px darkgreen;} 47 | aside .public li .tag{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(100,255,100,0.4);color:green;} 48 | nav .tag_public:hover{background:green;} 49 | aside .public li .tag:hover{background:rgba(0,255,0,0.4);} 50 | nav .tag_private{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(255,100,100,0.4);color:pink;text-shadow:0 1px 1px darkred;} 51 | aside .private li .tag{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(255,100,100,0.4);color:darkred;} 52 | aside .private li .tag:hover{background:rgba(255,0,0,0.5);} 53 | nav .tag_private:hover{background:red;} 54 | .tag_cloud{padding:2px; height: 24px; overflow: hidden;} 55 | .tag_cloud:hover{padding:2px; height:100%; overflow: visible;transition: all 0.7s ease-out;} 56 | nav .tag_public{color:lightgreen;} 57 | 58 | aside .public,.private{overflow-x:hidden;min-width:300px;text-align:left;vertical-align:top; margin-top:25px;padding:10px; border-radius:3px; border:1px solid;display:inline-block;} 59 | aside .public{background:rgba(100,255,100,0.2);border-color:rgba(0,255,0,0.4);} 60 | aside .private{background:rgba(255,100,100,0.2);border-color:rgba(255,0,0,0.3);} 61 | aside .private a:hover{text-shadow:0 0 5px red;color:darkred;} 62 | aside .private em{color:darkred;} 63 | aside li em {font-size:10px ;} 64 | aside .public li{background:rgba(100,255,100,0.2);} 65 | aside .private li{background:rgba(255,100,100,0.2);} 66 | li .infos{display:inline-block;padding:0;margin:0;} 67 | li .tools{display:inline-block;padding:0;margin:0;vertical-align: middle;} 68 | aside li img {vertical-align:middle;margin:1px;width:16px;height:16px;} 69 | aside li a.toprivate,aside li a.topublic{margin-right:5px;opacity:0.5;} 70 | aside li a.toprivate:hover,aside li a.topublic:hover{opacity:1;} 71 | 72 | footer { 73 | font-size:10px;text-align: right; color:lightgreen;text-shadow: 0 1px 1px black; position:fixed; line-height:15px; 74 | bottom:0;left:0;right:0;height:auto;min-height:15px;padding-right : 5px ; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; 75 | border-top:1px solid #888;-moz-box-shadow: 0 0px 9px #000; -webkit-box-shadow: 0 0px 9px #000; box-shadow: 0 0px 9px #000; 76 | -ms-filter: "progid:DXImageTransform.Microsoft.Shadow(Strength=9, Direction=135, Color='#000')"; filter: progid:DXImageTransform.Microsoft.Shadow(Strength=9, Direction=135, Color='#000'); filter: progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333)"; background-image: -moz-linear-gradient( top, #555, #333); background-image: -ms-linear-gradient( top, #555, #333); background-image: -o-linear-gradient( top, #555, #333); background-image: -webkit-gradient(linear, center top, center bottom, from(#555), to(#333)); background-image: -webkit-linear-gradient( top, #555, #333); background-image: linear-gradient( top, #555, #333); } 77 | footer a {color:lightgreen;text-shadow:0 1px 1px green;} 78 | footer a:hover {color:white;} 79 | 80 | body.iframe aside{padding-bottom:0!important;} 81 | body.iframe header {padding:2px;vertical-align: top;} 82 | body.iframe header img{width:32px;height:auto;} 83 | body.iframe header input{vertical-align: top;} 84 | body.iframe header #____q{margin-top:2px;} 85 | body.iframe header nav{margin-top:2px;display:inline-block; vertical-align: top;} 86 | body.iframe header nav p{margin:0;padding:0;} 87 | 88 | body.config label{display:block;width:300px;margin:auto;} 89 | body.config input{display:block;width:300px;margin-bottom:30px;margin:auto;} 90 | body.config input[type=submit]{color:darkgreen;} 91 | body.config select{display:block;width:300px;margin-bottom:30px;margin:auto;} 92 | body.config h1{color:#5F0;} 93 | -------------------------------------------------------------------------------- /design/broken_noise.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/broken_noise.png -------------------------------------------------------------------------------- /design/classic/actions.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/classic/actions.png -------------------------------------------------------------------------------- /design/classic/broken_noise.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/classic/broken_noise.png -------------------------------------------------------------------------------- /design/classic/favicon2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/classic/favicon2.png -------------------------------------------------------------------------------- /design/classic/foil.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/classic/foil.png -------------------------------------------------------------------------------- /design/classic/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/classic/index.html -------------------------------------------------------------------------------- /design/classic/lined_paper.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/classic/lined_paper.png -------------------------------------------------------------------------------- /design/classic/logo2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/classic/logo2.png -------------------------------------------------------------------------------- /design/classic/paper.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/classic/paper.png -------------------------------------------------------------------------------- /design/classic/style.css: -------------------------------------------------------------------------------- 1 | * { -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box; } 2 | body { 3 | background:url(paper.png) #efe; 4 | width: 100%; 5 | min-width:320px; 6 | margin:0;padding:0; 7 | font-family: Georgia, Serif;font-size : 16px; color: #050; 8 | } 9 | a:hover { color: #050;text-shadow:0 0 3px green;} 10 | 11 | a { color: black; text-decoration: none;} 12 | .icon{font-family:arial, sans-serif;display:inline-block;border-radius: 2px;margin:1px;height:16px;width:16px;border:solid 1px;font-size:10px;line-height:16px;font-weight: bold; text-align:center;} 13 | .private .icon{color:rgba(200,0,0,0.6);background-color:rgba(255,0,0,0.2);border-color:rgba(255,0,0,0.4);} 14 | .public .icon{color:rgba(0,200,0,0.6);background-color:rgba(0,255,0,0.2);border-color:rgba(0,255,0,0.4);} 15 | .private .icon:hover{color:rgba(200,0,0,1);background-color:rgba(255,0,0,0.5);border-color:rgba(255,0,0,0.8);text-shadow:none;box-shadow: 0 0 1px red} 16 | .public .icon:hover{color:rgba(0,200,0,1);background-color:rgba(0,255,0,0.5);border-color:rgba(0,255,0,0.8);text-shadow:none;box-shadow: 0 0 1px green} 17 | .public .icon.suppr:hover,.private .icon.suppr:hover{color:pink;background-color:rgba(255,0,0,0.9);border-color:rgba(255,0,0,1);} 18 | input{font-family: times,serif;outline:none; font-size:16px;border-radius: 3px; height:25px;padding : 3px ; vertical-align: bottom; margin-top : 3px ;} 19 | input[type=text]{width:80%;min-width:200px; background-color:rgba(255,255,255,0.8);border:1px solid #444;border-top-color:#333;border-bottom-color:#aaa; -moz-box-shadow: inset 0 1px 3px #000000; -webkit-box-shadow: inset 0 1px 3px #000000; box-shadow: inset 0 1px 3px #000000; } 20 | input[type=text]:hover{background-color:rgba(200,255,200,0.8);-moz-box-shadow: inset 0 1px 3px #040; -webkit-box-shadow: inset 0 1px 3px #040; box-shadow: inset 0 1px 3px #040; } 21 | input[type=text]:focus{background-color:rgba(200,255,200,0.9);-moz-box-shadow: inset 0 0 3px #040; -webkit-box-shadow: inset 0 0 3px #040; box-shadow: inset 0 0 3px #040; } 22 | input[type=submit]{border:1px solid green;cursor: pointer; color:lightgreen; text-shadow: 0 1px 1px darkgreen; display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(100,255,100,0.4);} 23 | input[type=submit]:hover{ background-color:rgba(0,255,0,0.8);} 24 | input[type=submit]:active{border-color:black; background-color:rgba(0,255,0,0.8);} 25 | #____q{margin-top:20px;} 26 | header{ 27 | 28 | -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; 29 | border-bottom:1px solid #222; 30 | -moz-box-shadow: 0 1px 3px #888; -webkit-box-shadow: 0 1px 3px #888; box-shadow: 0 1px 3px #888; -ms-filter: "progid:DXImageTransform.Microsoft.Shadow(Strength=2, Direction=135, Color='#888')"; filter: progid:DXImageTransform.Microsoft.Shadow(Strength=2, Direction=135, Color='#888'); 31 | padding : 10px ; width: 100%; height:auto;margin: 0; 32 | text-align: left;box-shadow: 0 1px 2px; 33 | filter: progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333)"; 34 | background-image: -moz-linear-gradient( top, #555, #333); background-image: -ms-linear-gradient( top, #555, #333); 35 | background-image: -o-linear-gradient( top, #555, #333); background-image: -webkit-gradient(linear, center top, center bottom, from(#555), to(#333)); background-image: -webkit-linear-gradient( top, #555, #333); background-image: linear-gradient( top, #555, #333); 36 | } 37 | header nav{display:inline-block; vertical-align: top;} 38 | header nav .zip{width:16px;height:16px; display:inline-block;background:url(zip.png) no-repeat;} 39 | header nav p{color:lightgreen;text-shadow: 0 1px 1px black;font-size:20px;} 40 | 41 | 42 | 43 | 44 | aside{height:100%;padding-bottom : 70px;text-align:center;} 45 | aside iframe{height:100%;border:none;} 46 | aside ul{padding:0;} 47 | aside li{margin:5px;list-style:none;vertical-align:middle;border-radius:3px;} 48 | aside li .tag{font-size:10px;display:inline-block;padding:2px;border-radius:3px;} 49 | nav .tag_public{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(100,255,100,0.4);color:green;text-shadow:0 1px 1px darkgreen;} 50 | aside .public li .tag{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(100,255,100,0.4);color:green;} 51 | nav .tag_public:hover{background:green;} 52 | aside .public li .tag:hover{background:rgba(0,255,0,0.4);} 53 | nav .tag_private{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(255,100,100,0.4);color:pink;text-shadow:0 1px 1px darkred;} 54 | aside .private li .tag{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(255,100,100,0.4);color:darkred;} 55 | aside .private li .tag:hover{background:rgba(255,0,0,0.5);} 56 | nav .tag_private:hover{background:red;} 57 | .tag_cloud{padding:2px;} 58 | nav .tag_public{color:lightgreen;} 59 | 60 | aside .public,.private{overflow-x:hidden;min-width:300px;text-align:left;vertical-align:top; margin-top:25px;padding:10px; border-radius:3px; border:1px solid;display:inline-block;} 61 | aside .public{background:rgba(100,255,100,0.2);border-color:rgba(0,255,0,0.4);} 62 | aside .private{background:rgba(255,100,100,0.2);border-color:rgba(255,0,0,0.3);} 63 | aside .private a:hover{text-shadow:0 0 5px red;color:darkred;} 64 | aside .private em{color:darkred;} 65 | aside li em {font-size:10px ;} 66 | aside .public li{background:rgba(100,255,100,0.2);} 67 | aside .private li{background:rgba(255,100,100,0.2);} 68 | li .infos{display:inline-block;padding:0;margin:0;} 69 | li .tools{display:inline-block;padding:0;margin:0;vertical-align: middle;} 70 | aside li img {vertical-align:middle;margin:1px;width:16px;height:16px;} 71 | aside li a.toprivate,aside li a.topublic{margin-right:5px;opacity:0.5;} 72 | aside li a.toprivate:hover,aside li a.topublic:hover{opacity:1;} 73 | 74 | 75 | footer { 76 | font-size:10px;text-align: right; color:lightgreen;text-shadow: 0 1px 1px black; position:fixed; line-height:15px; 77 | bottom:0;left:0;right:0;height:auto;min-height:15px;padding-right : 5px ; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; 78 | border-top:1px solid #888;-moz-box-shadow: 0 0px 9px #000; -webkit-box-shadow: 0 0px 9px #000; box-shadow: 0 0px 9px #000; 79 | -ms-filter: "progid:DXImageTransform.Microsoft.Shadow(Strength=9, Direction=135, Color='#000')"; filter: progid:DXImageTransform.Microsoft.Shadow(Strength=9, Direction=135, Color='#000'); filter: progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333)"; background-image: -moz-linear-gradient( top, #555, #333); background-image: -ms-linear-gradient( top, #555, #333); background-image: -o-linear-gradient( top, #555, #333); background-image: -webkit-gradient(linear, center top, center bottom, from(#555), to(#333)); background-image: -webkit-linear-gradient( top, #555, #333); background-image: linear-gradient( top, #555, #333); } 80 | footer a {color:lightgreen;text-shadow:0 1px 1px green;} 81 | footer a:hover {color:white;} 82 | 83 | body.iframe aside{padding-bottom:0!important;} 84 | body.iframe header {padding:2px;vertical-align: top;} 85 | body.iframe header img{width:32px;height:auto;} 86 | body.iframe header input{vertical-align: top;} 87 | body.iframe header #____q{margin-top:2px;} 88 | body.iframe header nav{margin-top:2px;display:inline-block; vertical-align: top;} 89 | body.iframe header nav p{margin:0;padding:0;} 90 | 91 | body.config label{display:block;width:300px;margin:auto;} 92 | body.config input{display:block;width:300px;margin-bottom:30px;margin:auto;} 93 | body.config input[type=submit]{color:darkgreen;} 94 | body.config select{display:block;width:300px;margin-bottom:30px;margin:auto;} 95 | body.config h1{color:#5F0;} 96 | -------------------------------------------------------------------------------- /design/classic/zip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/classic/zip.png -------------------------------------------------------------------------------- /design/favicon2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/favicon2.png -------------------------------------------------------------------------------- /design/foil.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/foil.png -------------------------------------------------------------------------------- /design/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/index.html -------------------------------------------------------------------------------- /design/lined_paper.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/lined_paper.png -------------------------------------------------------------------------------- /design/logo2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/logo2.png -------------------------------------------------------------------------------- /design/paper.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/paper.png -------------------------------------------------------------------------------- /design/pinterest/broken_noise.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/pinterest/broken_noise.png -------------------------------------------------------------------------------- /design/pinterest/favicon2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/pinterest/favicon2.png -------------------------------------------------------------------------------- /design/pinterest/foil.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/pinterest/foil.png -------------------------------------------------------------------------------- /design/pinterest/fond.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/pinterest/fond.png -------------------------------------------------------------------------------- /design/pinterest/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/pinterest/index.html -------------------------------------------------------------------------------- /design/pinterest/lined_paper.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/pinterest/lined_paper.png -------------------------------------------------------------------------------- /design/pinterest/logo2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/pinterest/logo2.png -------------------------------------------------------------------------------- /design/pinterest/paper.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/pinterest/paper.png -------------------------------------------------------------------------------- /design/pinterest/style.css: -------------------------------------------------------------------------------- 1 | /* pinterest style */ 2 | 3 | * { -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box; } 4 | body { 5 | background:url(fond.png) #efe; 6 | width: 100%; 7 | min-width:320px; 8 | margin:0;padding:0; 9 | font-family: Georgia, Serif;font-size : 16px; color: #050; 10 | } 11 | a:hover { color: #050;text-shadow:0 0 3px green;} 12 | 13 | a { color: black; text-decoration: none;} 14 | .icon{font-family:arial, sans-serif;display:inline-block;border-radius: 2px;margin:1px;height:16px;width:16px;border:solid 1px;font-size:10px;line-height:16px;font-weight: bold; text-align:center;} 15 | .private .icon{color:rgba(200,0,0,0.6);background-color:rgba(255,0,0,0.2);border-color:rgba(255,0,0,0.4);} 16 | .public .icon{color:rgba(0,200,0,0.6);background-color:rgba(0,255,0,0.2);border-color:rgba(0,255,0,0.4);} 17 | .private .icon:hover{color:rgba(200,0,0,1);background-color:rgba(255,0,0,0.5);border-color:rgba(255,0,0,0.8);text-shadow:none;box-shadow: 0 0 1px red} 18 | .public .icon:hover{color:rgba(0,200,0,1);background-color:rgba(0,255,0,0.5);border-color:rgba(0,255,0,0.8);text-shadow:none;box-shadow: 0 0 1px green} 19 | .public .icon.suppr:hover,.private .icon.suppr:hover{color:pink;background-color:rgba(255,0,0,0.9);border-color:rgba(255,0,0,1);} 20 | input{font-family: times,serif;outline:none; font-size:16px;border-radius: 3px; height:25px;padding : 3px ; vertical-align: bottom; margin-top : 3px ;} 21 | input[type=text]{width:80%;min-width:200px; background-color:rgba(255,255,255,0.8);border:1px solid #444;border-top-color:#333;border-bottom-color:#aaa; -moz-box-shadow: inset 0 1px 3px #000000; -webkit-box-shadow: inset 0 1px 3px #000000; box-shadow: inset 0 1px 3px #000000; } 22 | input[type=text]:hover{background-color:rgba(200,255,200,0.8);-moz-box-shadow: inset 0 1px 3px #040; -webkit-box-shadow: inset 0 1px 3px #040; box-shadow: inset 0 1px 3px #040; } 23 | input[type=text]:focus{background-color:rgba(200,255,200,0.9);-moz-box-shadow: inset 0 0 3px #040; -webkit-box-shadow: inset 0 0 3px #040; box-shadow: inset 0 0 3px #040; } 24 | input[type=submit]{border:1px solid green;cursor: pointer; color:lightgreen; text-shadow: 0 1px 1px darkgreen; display:inline-block;border-radius:3px;padding:2px;margin:1px;background-color:rgba(100,255,100,0.4);} 25 | input[type=submit]:hover{ background-color:rgba(0,255,0,0.8);} 26 | input[type=submit]:active{border-color:black; background-color:rgba(0,255,0,0.8);} 27 | #____q{margin-top:20px;} 28 | header{ 29 | 30 | -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; 31 | border-bottom:1px solid #222; 32 | -moz-box-shadow: 0 1px 3px #888; -webkit-box-shadow: 0 1px 3px #888; box-shadow: 0 1px 3px #888; padding : 10px ; width: 100%; height:auto;margin: 0; 33 | text-align: left; 34 | filter: progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333)"; 35 | background-image: -moz-linear-gradient( top, #555, #333); background-image: -ms-linear-gradient( top, #555, #333); 36 | background-image: -o-linear-gradient( top, #555, #333); background-image: -webkit-gradient(linear, center top, center bottom, from(#555), to(#333)); background-image: -webkit-linear-gradient( top, #555, #333); background-image: linear-gradient( top, #555, #333); 37 | } 38 | header nav{display:inline-block; vertical-align: top;} 39 | header nav .zip{width:16px;height:16px; display:inline-block;background:url(zip.png) no-repeat;} 40 | header nav p{color:lightgreen;text-shadow: 0 1px 1px black;font-size:20px;} 41 | 42 | 43 | 44 | 45 | aside{height:100%;padding-bottom : 70px;text-align:center;} 46 | aside iframe{height:100%;border:none;} 47 | aside ul{padding:0;} 48 | aside li{margin:5px;list-style:none;vertical-align:middle;border-radius:3px;} 49 | aside li .tag{font-size:10px;display:inline-block;padding:2px;border-radius:3px;} 50 | nav .tag_public{background:url(paper.png);display:inline-block;border-radius:3px;padding:2px;margin:1px;background-color:rgba(100,255,100,0.4);color:green;text-shadow:0 1px 1px darkgreen;} 51 | aside .public li .tag{background:url(paper.png);display:inline-block;border-radius:3px;padding:2px;margin:1px;background-color:rgba(100,255,100,0.4);color:green;} 52 | nav .tag_public:hover{background-color:green;} 53 | aside .public li .tag:hover{background-color:rgba(0,255,0,0.4);} 54 | nav .tag_private{background:url(paper.png);display:inline-block;border-radius:3px;padding:2px;margin:1px;background-color:rgba(255,100,100,0.4);color:pink;text-shadow:0 1px 1px darkred;} 55 | aside .private li .tag{background:url(paper.png);display:inline-block;border-radius:3px;padding:2px;margin:1px;background-color:rgba(255,100,100,0.4);color:darkred;} 56 | aside .private li .tag:hover{background-color:rgba(255,0,0,0.5);} 57 | nav .tag_private:hover{background-color:red;} 58 | .tag_cloud{padding:2px;} 59 | nav .tag_public{color:lightgreen;background-color:rgba(0,255,0,0.5);} 60 | 61 | aside .public,aside .private{ 62 | background:url(paper.png); 63 | overflow-x:hidden; 64 | min-width:300px; 65 | text-align:left; 66 | vertical-align:top; 67 | margin-top:25px;padding:10px; 68 | 69 | border:none; 70 | display:inline-block; 71 | text-align:center; 72 | } 73 | aside .public{} 74 | aside .private{} 75 | 76 | aside .private a:hover{text-shadow:0 0 5px red;color:darkred;} 77 | aside .private em{color:darkred;} 78 | aside li em {font-size:10px ;} 79 | 80 | aside .public li,aside .private li{ 81 | display:inline-block; 82 | width:200px; 83 | overflow:hidden; 84 | height: 200px; 85 | border:1px solid; 86 | } 87 | aside .public li:hover{background-color:rgba(100,255,100,0.4);} 88 | aside .private li:hover{background-color:rgba(255,100,100,0.4);} 89 | aside li .suppr{display:block;padding:0;margin:0;opacity:0;} 90 | aside li .title{display:block;font-size:18px;padding:0;margin:2px;height: 107px;text-align:left;overflow:hidden;} 91 | aside li .infos{padding:0;margin:0;height:50px;display: table-cell; 92 | vertical-align: bottom;} 93 | aside li .tools{padding:0;margin:0;opacity:0;height:20px;text-align:left;} 94 | aside li:hover .suppr ,aside li:hover .tools {opacity:1;height:16px;} 95 | aside .public li{background-color:rgba(100,255,100,0.2);border-color:rgba(0,255,0,0.4);} 96 | aside .private li{background-color:rgba(255,100,100,0.2);border-color:rgba(255,0,0,0.3);} 97 | 98 | aside li img {vertical-align:bottom;margin:1px;width:16px;height:16px;} 99 | aside li a.toprivate,aside li a.topublic{margin-right:5px;opacity:0.5;} 100 | aside li a.toprivate:hover,aside li a.topublic:hover{opacity:1;} 101 | 102 | 103 | footer { 104 | font-size:10px;text-align: right; color:lightgreen;text-shadow: 0 1px 1px black; position:fixed; line-height:15px; 105 | bottom:0;left:0;right:0;height:auto;min-height:15px;padding-right : 5px ; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; 106 | border-top:1px solid #888;-moz-box-shadow: 0 0px 9px #000; -webkit-box-shadow: 0 0px 9px #000; box-shadow: 0 0px 9px #000; 107 | -ms-filter: "progid:DXImageTransform.Microsoft.Shadow(Strength=9, Direction=135, Color='#000')"; filter: progid:DXImageTransform.Microsoft.Shadow(Strength=9, Direction=135, Color='#000'); filter: progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333)"; background-image: -moz-linear-gradient( top, #555, #333); background-image: -ms-linear-gradient( top, #555, #333); background-image: -o-linear-gradient( top, #555, #333); background-image: -webkit-gradient(linear, center top, center bottom, from(#555), to(#333)); background-image: -webkit-linear-gradient( top, #555, #333); background-image: linear-gradient( top, #555, #333); } 108 | footer a {color:lightgreen;text-shadow:0 1px 1px green;} 109 | footer a:hover {color:white;} 110 | 111 | body.iframe aside{padding-bottom:0!important;} 112 | body.iframe header {padding:2px;vertical-align: top;} 113 | body.iframe header img{width:32px;height:auto;} 114 | body.iframe header input{vertical-align: top;} 115 | body.iframe header #____q{margin-top:2px;} 116 | body.iframe header nav{margin-top:2px;display:inline-block; vertical-align: top;} 117 | body.iframe header nav p{margin:0;padding:0;} 118 | 119 | body *{transition:all 300ms} 120 | body *:hover{transition:all 300ms} 121 | 122 | body.config label{display:block;width:300px;margin:auto;} 123 | body.config input{display:block;width:300px;margin-bottom:30px;margin:auto;} 124 | body.config input[type=submit]{color:darkgreen;} 125 | body.config select{display:block;width:300px;margin-bottom:30px;margin:auto;} 126 | body.config h1{color:#5F0;} -------------------------------------------------------------------------------- /design/pinterest/zip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/pinterest/zip.png -------------------------------------------------------------------------------- /design/style.css: -------------------------------------------------------------------------------- 1 | * { -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box; } 2 | body { 3 | background:url(paper.png) #efe; 4 | width: 100%; 5 | min-width:320px; 6 | margin:0;padding:0; 7 | font-family: Georgia, Serif;font-size : 13px; color: #050; 8 | } 9 | a:hover { color: #050;text-shadow:0 0 3px green;} 10 | 11 | a { color: black; text-decoration: none;} 12 | .icon{font-family:arial, sans-serif;display:inline-block;border-radius: 2px;margin:1px;height:16px;width:16px;border:solid 1px;font-size:10px;line-height:16px;font-weight: bold; text-align:center;} 13 | .private .icon{color:rgba(200,0,0,0.6);background-color:rgba(255,0,0,0.2);border-color:rgba(255,0,0,0.4);} 14 | .public .icon{color:rgba(0,200,0,0.6);background-color:rgba(0,255,0,0.2);border-color:rgba(0,255,0,0.4);} 15 | .private .icon:hover{color:rgba(200,0,0,1);background-color:rgba(255,0,0,0.5);border-color:rgba(255,0,0,0.8);text-shadow:none;box-shadow: 0 0 1px red} 16 | .public .icon:hover{color:rgba(0,200,0,1);background-color:rgba(0,255,0,0.5);border-color:rgba(0,255,0,0.8);text-shadow:none;box-shadow: 0 0 1px green} 17 | .public .icon.suppr:hover,.private .icon.suppr:hover{color:pink;background-color:rgba(255,0,0,0.9);border-color:rgba(255,0,0,1);} 18 | input{font-family: times,serif;outline:none; font-size:16px;border-radius: 3px; height:25px;padding : 3px ; vertical-align: bottom; margin-top : 3px ;} 19 | input[type=text]{width:80%;min-width:200px; background-color:rgba(255,255,255,0.8);border:1px solid #444;border-top-color:#333;border-bottom-color:#aaa; -moz-box-shadow: inset 0 1px 3px #000000; -webkit-box-shadow: inset 0 1px 3px #000000; box-shadow: inset 0 1px 3px #000000; } 20 | input[type=text]:hover{background-color:rgba(200,255,200,0.8);-moz-box-shadow: inset 0 1px 3px #040; -webkit-box-shadow: inset 0 1px 3px #040; box-shadow: inset 0 1px 3px #040; } 21 | input[type=text]:focus{background-color:rgba(200,255,200,0.9);-moz-box-shadow: inset 0 0 3px #040; -webkit-box-shadow: inset 0 0 3px #040; box-shadow: inset 0 0 3px #040; } 22 | input[type=submit]{border:1px solid green;cursor: pointer; color:lightgreen; text-shadow: 0 1px 1px darkgreen; display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(100,255,100,0.4);} 23 | input[type=submit]:hover{ background-color:rgba(0,255,0,0.8);} 24 | input[type=submit]:active{border-color:black; background-color:rgba(0,255,0,0.8);} 25 | #____q{margin-top:20px;} 26 | header{ 27 | 28 | -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; 29 | border-bottom:1px solid #222; 30 | -moz-box-shadow: 0 1px 3px #888; -webkit-box-shadow: 0 1px 3px #888; box-shadow: 0 1px 3px #888; -ms-filter: "progid:DXImageTransform.Microsoft.Shadow(Strength=2, Direction=135, Color='#888')"; filter: progid:DXImageTransform.Microsoft.Shadow(Strength=2, Direction=135, Color='#888'); 31 | padding : 10px ; width: 100%; height:auto;margin: 0; 32 | text-align: left;box-shadow: 0 1px 2px; 33 | filter: progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333)"; 34 | background-image: -moz-linear-gradient( top, #555, #333); background-image: -ms-linear-gradient( top, #555, #333); 35 | background-image: -o-linear-gradient( top, #555, #333); background-image: -webkit-gradient(linear, center top, center bottom, from(#555), to(#333)); background-image: -webkit-linear-gradient( top, #555, #333); background-image: linear-gradient( top, #555, #333); 36 | } 37 | header nav{display:inline-block; vertical-align: top;} 38 | header nav .zip{width:16px;height:16px; display:inline-block;background:url(zip.png) no-repeat;} 39 | header nav p{color:lightgreen;text-shadow: 0 1px 1px black;font-size:20px;} 40 | 41 | aside{height:100%;padding-bottom : 70px;text-align:center;} 42 | aside iframe{height:100%;border:none;} 43 | aside ul{padding:0;} 44 | aside li{margin:5px;list-style:none;vertical-align:middle;border-radius:3px;} 45 | aside li .tag{font-size:10px;display:inline-block;padding:2px;border-radius:3px;} 46 | nav .tag_public{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(100,255,100,0.4);color:green;text-shadow:0 1px 1px darkgreen;} 47 | aside .public li .tag{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(100,255,100,0.4);color:green;} 48 | nav .tag_public:hover{background:green;} 49 | aside .public li .tag:hover{background:rgba(0,255,0,0.4);} 50 | nav .tag_private{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(255,100,100,0.4);color:pink;text-shadow:0 1px 1px darkred;} 51 | aside .private li .tag{display:inline-block;border-radius:3px;padding:2px;margin:1px;background:rgba(255,100,100,0.4);color:darkred;} 52 | aside .private li .tag:hover{background:rgba(255,0,0,0.5);} 53 | nav .tag_private:hover{background:red;} 54 | .tag_cloud{padding:2px; height: 24px; overflow: hidden;} 55 | .tag_cloud:hover{padding:2px; height:100%; overflow: visible;transition: all 0.7s ease-out;} 56 | nav .tag_public{color:lightgreen;} 57 | 58 | aside .public,.private{overflow-x:hidden;min-width:300px;text-align:left;vertical-align:top; margin-top:25px;padding:10px; border-radius:3px; border:1px solid;display:inline-block;} 59 | aside .public{background:rgba(100,255,100,0.2);border-color:rgba(0,255,0,0.4);} 60 | aside .private{background:rgba(255,100,100,0.2);border-color:rgba(255,0,0,0.3);} 61 | aside .private a:hover{text-shadow:0 0 5px red;color:darkred;} 62 | aside .private em{color:darkred;} 63 | aside li em {font-size:10px ;} 64 | aside .public li{background:rgba(100,255,100,0.2);} 65 | aside .private li{background:rgba(255,100,100,0.2);} 66 | li .infos{display:inline-block;padding:0;margin:0;} 67 | li .tools{display:inline-block;padding:0;margin:0;vertical-align: middle;} 68 | aside li img {vertical-align:middle;margin:1px;width:16px;height:16px;} 69 | aside li a.toprivate,aside li a.topublic{margin-right:5px;opacity:0.5;} 70 | aside li a.toprivate:hover,aside li a.topublic:hover{opacity:1;} 71 | 72 | footer { 73 | font-size:10px;text-align: right; color:lightgreen;text-shadow: 0 1px 1px black; position:fixed; line-height:15px; 74 | bottom:0;left:0;right:0;height:auto;min-height:15px;padding-right : 5px ; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; 75 | border-top:1px solid #888;-moz-box-shadow: 0 0px 9px #000; -webkit-box-shadow: 0 0px 9px #000; box-shadow: 0 0px 9px #000; 76 | -ms-filter: "progid:DXImageTransform.Microsoft.Shadow(Strength=9, Direction=135, Color='#000')"; filter: progid:DXImageTransform.Microsoft.Shadow(Strength=9, Direction=135, Color='#000'); filter: progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr = #555, endColorstr = #333)"; background-image: -moz-linear-gradient( top, #555, #333); background-image: -ms-linear-gradient( top, #555, #333); background-image: -o-linear-gradient( top, #555, #333); background-image: -webkit-gradient(linear, center top, center bottom, from(#555), to(#333)); background-image: -webkit-linear-gradient( top, #555, #333); background-image: linear-gradient( top, #555, #333); } 77 | footer a {color:lightgreen;text-shadow:0 1px 1px green;} 78 | footer a:hover {color:white;} 79 | 80 | body.iframe aside{padding-bottom:0!important;} 81 | body.iframe header {padding:2px;vertical-align: top;} 82 | body.iframe header img{width:32px;height:auto;} 83 | body.iframe header input{vertical-align: top;} 84 | body.iframe header #____q{margin-top:2px;} 85 | body.iframe header nav{margin-top:2px;display:inline-block; vertical-align: top;} 86 | body.iframe header nav p{margin:0;padding:0;} 87 | 88 | body.config label{display:block;width:300px;margin:auto;} 89 | body.config input{display:block;width:300px;margin-bottom:30px;margin:auto;} 90 | body.config input[type=submit]{color:darkgreen;} 91 | body.config select{display:block;width:300px;margin-bottom:30px;margin:auto;} 92 | body.config h1{color:#5F0;} 93 | -------------------------------------------------------------------------------- /design/zip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/design/zip.png -------------------------------------------------------------------------------- /index.php: -------------------------------------------------------------------------------- 1 | Bookmarklet'; 47 | $column_width_public='width:60%'; 48 | $column_width_private='width:30%'; 49 | if ($GLOBAL['public']){$bookmarklet='';$column_width='width:97%';} 50 | if (!creer_dossier($GLOBAL['data_folder'], TRUE)) { die('Cant create '.$GLOBAL['data_folder'].' folder.'); } 51 | if (!creer_dossier($GLOBAL['data_folder'].'/zipversions', TRUE)) { die('Cant create '.$GLOBAL['data_folder'].'/zipversions'.' folder.'); } 52 | if (!creer_dossier($GLOBAL['private_data_folder'], TRUE)) { die('Cant create '.$GLOBAL['private_data_folder'].' folder.'); } 53 | if (!creer_dossier($GLOBAL['public_data_folder'], TRUE)) { die('Cant create '.$GLOBAL['public_data_folder'].' folder.'); } 54 | if (is_file($GLOBAL['data_folder'].'/tags.txt')){$GLOBAL['tag_array']=unstore($GLOBAL['data_folder'].'/tags.txt');}else{$GLOBAL['tag_array']=array('public'=>array(),'private'=>array());store($GLOBAL['data_folder'].'/tags.txt',$GLOBAL['tag_array']);} 55 | if (!isset($GLOBAL['tag_array']['public'])){$GLOBAL['tag_array']['public']=array();}; 56 | if (!isset($GLOBAL['tag_array']['private'])){$GLOBAL['tag_array']['private']=array();}; 57 | 58 | // Fonctions 59 | function aff($a,$stop=true){echo 'Arret a la ligne '.__LINE__.' du fichier '.__FILE__.'
    ';var_dump($a);echo '
    ';if ($stop){exit();}} 60 | function BodyClasses($add=''){$regex='#(msie)[/ ]([0-9])+|(firefox)/([0-9])+|(chrome)/([0-9])+|(opera)/([0-9]+)|(safari)/([0-9]+)|(android)|(iphone)|(ipad)|(blackberry)|(Windows Phone)|(symbian)|(mobile)|(bada])#i';@preg_match($regex,$_SERVER['HTTP_USER_AGENT'],$resultat);return ' class="'.$add.' '.@preg_replace('#([a-zA-Z ]+)[ /]([0-9]+)#','$1 $1$2',$resultat[0]).' '.basename($_SERVER['PHP_SELF'],'.php').'" ';} 61 | function title2filename($chaine){$a=array(' ',':','|','#','/','\\','$','*','?','&','<','>');return substr(stripAccents(str_replace($a,'_',$chaine)),0,30);} 62 | function stripAccents($string){ $a=explode(' ','à á â ã ä ç è é ê ë ì í î ï ñ ò ó ô õ ö ù ú û ü ý ÿ À Á Â Ã Ä Ç È É Ê Ë Ì Í Î Ï Ñ Ò Ó Ô Õ Ö Ù Ú Û Ü Ý');$b=explode(' ','a a a a a c e e e e i i i i n o o o o o u u u u y y A A A A A C E E E E I I I I N O O O O O U U U U Y');return str_replace($a,$b,$string);} 63 | function returncurrenturl(){$domaine=dirname($_SERVER['SERVER_PROTOCOL']) . "://" . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'] ;$domaine=explode('?',$domaine);return $domaine[0];} 64 | function store($file,$datas){file_put_contents($file,serialize($datas));} 65 | function unstore($file){ return unserialize(file_get_contents($file));} 66 | function getinfos($path=''){if (!is_file($path.'/index.ini')){return false;} return parse_ini_file($path.'/index.ini');} 67 | function setinfos($path='',$infos=array()){ if (!is_dir($path.'/index.ini')){return false;}$ini='';foreach($infos as $key=>$val){$ini.=$key.'="'.str_replace('"','\"',$val).'"'."\n";}store($path.'/index.ini',$ini);} 68 | function statuspath($path){global $GLOBAL;if (strpos($path,$GLOBAL['public_data_folder'])!==false){return 'public';}else{return 'private';}} 69 | function idfrompath($path){$id=explode('/',$path);$id=$id[count($id)-1];return $id;} 70 | function deltags($tags,$path,$id=false,$status=false){ 71 | /* delete the tags of the page's path*/ 72 | global $GLOBAL; 73 | if (is_string($tags)){$tags=explode(' ',$tags);} 74 | if (!$status){$status=statuspath($path);} 75 | if (!$id){$id=idfrompath($path);} 76 | 77 | foreach($tags as $tag){ 78 | if (isset($GLOBAL['tag_array'][$status][$id])){ 79 | $GLOBAL['tag_array'][$status][$id]=trim(str_replace(' '.$tag.' ','',' '.$GLOBAL['tag_array'][$status][$id].' ')); 80 | } 81 | } 82 | store($GLOBAL['data_folder'].'/tags.txt',$GLOBAL['tag_array']); 83 | } 84 | function settags($tags,$path,$id=false,$status=false){ 85 | /* set tags to the page's path*/ 86 | global $GLOBAL; 87 | if (!$status){$status=statuspath($path);} 88 | if (!$id){$id=idfrompath($path);} 89 | $GLOBAL['tag_array'][$status][$id]=trim($tags); 90 | store($GLOBAL['data_folder'].'/tags.txt',$GLOBAL['tag_array']); 91 | } 92 | function link2favicon($dir){ 93 | global $GLOBAL; 94 | if (!is_dir($dir)){echo '';} 95 | $favs=glob($dir.'/*favicon*'); 96 | if (count($favs)>0){$fav=basename($favs[0]); 97 | $extension=pathinfo($dir,PATHINFO_EXTENSION); 98 | echo ''; 99 | }else{ 100 | echo '';; 101 | } 102 | } 103 | function search($public='public',$tag=false){ 104 | global $GLOBAL; 105 | //$GLOBAL['tag_array']; 106 | if (!$tag){return scandir($GLOBAL[$public.'_data_folder'] );} 107 | else{ 108 | foreach ($GLOBAL['tag_array'][$public] as $key=>$val){ 109 | if (stripos($val,$tag)!==false){$result[]=$key;} 110 | } 111 | if (!empty($result)){return $result;}else{return array();} 112 | } 113 | } 114 | function array2feed($array=null){ 115 | // more infos on this function at https://github.com/broncowdd/feed2array 116 | if (!$array){return false;} 117 | if (empty($array['infos']['type'])){$array['infos']['type']='rss';}else{$array['infos']['type']=strtolower($array['infos']['type']);} 118 | if (empty($array['infos']['description'])){$array['infos']['description']='';} 119 | $r="\n";$t="\t"; 120 | $tpl=array('rss'=>array(),'atom'=>array()); 121 | $tpl['rss']['header']=''.$r.''.$r.$t.''.$r; 122 | $tpl['atom']['header']=''.$r; 123 | $tpl['rss']['footer']=$t.''.$r; 124 | $tpl['atom']['footer']=''.$r; 125 | $tpl['rss']['content-type']='Content-Type: application/rss+xml'; 126 | $tpl['atom']['content-type']='Content-Type: application/atom+xml;charset=utf-8'; 127 | header($tpl[$array['infos']['type']]['content-type']); 128 | $feed=$tpl[$array['infos']['type']]['header']; 129 | //create the feed's info content 130 | foreach($array['infos'] as $key=>$value){ 131 | if ($array['infos']['type']=='atom'){ // ATOM 132 | if ($key=='link'){$feed.=$t.$t.''.$r;} 133 | elseif ($key=='author'){$feed.=$t.$t.''.$value.''.$r;} 134 | elseif ($key=='licence'){$feed.=$t.$t.'<'.$key.' href="'.$value.'" rel="license"/>'.$r;} // in atom feed, licence is the link to the licence type 135 | elseif ($key!='version'&&$key!='type'){$feed.=$t.$t.'<'.$key.'>'.$value.''.$r;} 136 | }else{ // RSS 137 | if ($key!='version'&&$key!='type'){$feed.=$t.$t.'<'.$key.'>'.$value.''.$r;} 138 | } 139 | } 140 | 141 | //then the items content 142 | foreach ($array['items'] as $item){ 143 | if ($array['infos']['type']=='atom'){ $feed.=$t.$t.$t.''.$r;}else{$feed.=$t.$t.$t.''.$r;} 144 | foreach($item as $key=>$value){ 145 | if ($array['infos']['type']=='atom'){ // ATOM 146 | if ($key=='link'){$feed.=$t.$t.$t.$t.''.$r;} 147 | elseif ($key=='content'){$feed.=$t.$t.$t.$t.''.htmlspecialchars($value).''.$r;} 148 | else{$feed.=$t.$t.$t.$t.'<'.$key.'>'.$value.''.$r;} 149 | }else{ // RSS 150 | if ($key=='date'||$key=='pubDate'||$key=='title'||$key=='link'){$feed.=$t.$t.$t.$t.'<'.$key.'>'.htmlspecialchars($value).''.$r;} 151 | elseif($key=='guid'){ $feed.=$t.$t.$t.$t.''.$value.''.$r;} 152 | else{$feed.=$t.$t.$t.$t.'<'.$key.'>'.$r;} 153 | } 154 | } 155 | if ($array['infos']['type']=='atom'){ $feed.=$t.$t.$t.''.$r;}else{$feed.=$t.$t.$t.''.$r;} 156 | } 157 | 158 | 159 | $feed.=$tpl[$array['infos']['type']]['footer']; 160 | return $feed; 161 | } 162 | function tagcloud(){ 163 | global $GLOBAL; $array=array('public'=>array(),'private'=>array()); 164 | if (!$GLOBAL['public']){ 165 | foreach ($GLOBAL['tag_array']['private'] as $key=>$tag){ 166 | $tags=explode(' ',trim($tag)); 167 | foreach ($tags as $t){ 168 | if (!isset($array['private'][$t]['nb'])){$array['private'][$t]['nb']=1;}else{$array['private'][$t]['nb']++;} 169 | } 170 | } 171 | } 172 | foreach ($GLOBAL['tag_array']['public'] as $key=>$tag){ 173 | $tags=explode(' ',trim($tag)); 174 | foreach ($tags as $t){ 175 | if (!isset($array['public'][$t]['nb'])){$array['public'][$t]['nb']=1;}else{$array['public'][$t]['nb']++;} 176 | //if (!isset($array[$t]['status'])){$array[$t]['status']='public';} 177 | } 178 | } 179 | 180 | foreach ($array['public'] as $tag=>$val){if (trim($tag)!=''){echo ''.$tag.' '.$val['nb'].'';}} 181 | if (isset($array['private'])){foreach ($array['private'] as $tag=>$val){if (trim($tag)!=''){echo ''.$tag.' '.$val['nb'].'';}}} 182 | } 183 | function tag2links($tagstring){ 184 | global $GLOBAL; 185 | $array=explode(' ',$tagstring);$links='';$public=''; 186 | if ($GLOBAL['public']){$public='&public';} 187 | foreach ($array as $tag){ 188 | $links.=''.$tag.''; 189 | } 190 | return $links; 191 | } 192 | if(isset($_GET['publicget'])||isset($_GET['privateget'])){$bodyclass.=' iframe';} 193 | $bodyclass=bodyclasses($bodyclass);$target=''; 194 | 195 | 196 | // 197 | // BEGIN SCRIPT 198 | // 199 | // init 200 | // url not yet retrieved 201 | $GLOBAL['done']['d'] = FALSE; 202 | 203 | if (!$GLOBAL['public']){ // private 204 | // Get URL to save. 205 | if (!empty($_GET['q'])) { 206 | 207 | 208 | $url = htmlspecialchars($_GET['q']); 209 | if (strpos($url, '://') === false) { 210 | $url = 'http://'.$url; 211 | } 212 | $GLOBAL['url'] = $url; 213 | $url_p = url_parts(); 214 | 215 | // retrieve the file main HTML file 216 | 217 | $GLOBAL['main_page_data'] = get_external_file($GLOBAL['url'], 6); 218 | 219 | 220 | if ($GLOBAL['main_page_data'] === FALSE) { 221 | die('error retrieving external main page'); 222 | } 223 | 224 | else { 225 | // crée le nouveau dossier basé sur le TS. 226 | $new_folder = date('Y-m-d-H-i-s'); 227 | if (!creer_dossier($GLOBAL['default_data_folder'].'/'.$new_folder) === TRUE ) { 228 | die('error creating data folder'); 229 | } 230 | else { 231 | $GLOBAL['target_folder'] = $GLOBAL['default_data_folder'].'/'.$new_folder; 232 | } 233 | 234 | /*GESTION DU PDF ICI*/ 235 | if (strtolower(substr($_GET['q'],-4))=='.pdf'){ 236 | $title=basename($_GET['q']); 237 | file_put_contents($GLOBAL['target_folder'].'/'.$title,$GLOBAL['main_page_data']); 238 | file_put_contents($GLOBAL['target_folder'].'/index.php',''); 239 | }else{ 240 | 241 | 242 | $liste_css = array(); 243 | // parse le fichier principal à la recherche de données à télécharger 244 | $files = list_retrievable_data($GLOBAL['url'], $GLOBAL['main_page_data']); 245 | // les récupère et les enregistre. 246 | //echo '
    ';print_r($files);die();
     247 | 				foreach ($files as $i => $file) {
     248 | 					if ($data = get_external_file($file['url_fichier'], 3) and ($data !== FALSE) ) {
     249 | 						// CSS files need to be parsed aswell
     250 | 						if ($file['type'] == 'css') {
     251 | 							$liste_css[] = $file;
     252 | 						}
     253 | 						else {
     254 | 							file_put_contents($GLOBAL['target_folder'].'/'.$file['nom_destination'], $data);
     255 | 						}
     256 | 					}
     257 | 				}
     258 | 				// remplace juste les liens  relatifs vers des liens absolus
     259 | 				absolutes_links($GLOBAL['main_page_data']);
     260 | 
     261 | 				// enregistre le fichier HTML principal
     262 | 				file_put_contents($GLOBAL['target_folder'].'/'.'index.html', $GLOBAL['main_page_data']);
     263 | 
     264 | 				// récupère le titre de la page
     265 | 				// cherche le charset spécifié dans le code HTML.
     266 | 				// récupère la balise méta tout entière, dans $meta
     267 | 				preg_match('##Usi', $GLOBAL['main_page_data'], $meta);
     268 | 
     269 | 				// si la balise a été trouvée, on tente d’isoler l’encodage.
     270 | 				if (!empty($meta[0])) {
     271 | 					// récupère juste l’encodage utilisé, dans $enc
     272 | 					preg_match('#charset="?(.*)"#si', $meta[0], $enc);
     273 | 					// regarde si le charset a été trouvé, sinon le fixe à UTF-8
     274 | 					$html_charset = (!empty($enc[1])) ? strtolower($enc[1]) : 'utf-8';
     275 | 				} else { $html_charset = 'utf-8'; }
     276 | 				// récupère le titre, dans le tableau $titles, rempli par preg_match()
     277 | 				preg_match('#(.*)#Usi', $GLOBAL['main_page_data'], $titles);
     278 | 				if (!empty($titles[1])) {
     279 | 					$html_title = trim($titles[1]);
     280 | 					// ré-encode le titre en UTF-8 en fonction de son encodage.
     281 | 					$title = ($html_charset == 'iso-8859-1') ? utf8_encode($html_title) : $html_title;
     282 | 				// si pas de titre : on utilise l’URL.
     283 | 				} else {
     284 | 					$title = $url;
     285 | 				}
     286 | 
     287 | 
     288 | 				// récupère, parse, modifie & enregistre les fichier CSS (et les fichiés liés)
     289 | 				$n = 0;
     290 | 				$count = count($liste_css);
     291 | 				while ( $n < $count and $n <300) { // no more than 300 ext files.
     292 | 					$i = $n;
     293 | 					$file = $liste_css[$i];
     294 | 					if ($data = get_external_file($file['url_fichier'], 3) and ($data !== FALSE) ) {
     295 | 						if (preg_match('#(css|php|txt|html|xml|js)#', $file['url_fichier']) ) {
     296 | 							$matches_url = array();
     297 | 							preg_match_all('#url\s{0,}\(("|\')?([^\'")]{1,})(\'|")?\)#i', $data, $matches_url, PREG_SET_ORDER);
     298 | 							$matches_url2 = array();
     299 | 							preg_match_all("#@import\s*(?:\"([^\">]*)\"?|'([^'>]*)'?)([^;]*)(;|$)#i", $data, $matches_url2, PREG_SET_ORDER);
     300 | 
     301 | 
     302 | 							$matches_url = array_merge($matches_url2, $matches_url);
     303 | 					
     304 | 
     305 | 							// pour chaque URL/URI
     306 | 							foreach ($matches_url as $j => $valuej) {
     307 | 
     308 | 								if (preg_match('#^data:#', $matches_url[$j][2])) break; // if BASE64 data, dont download.
     309 | 
     310 | 								// get the filenam (basename)
     311 | 								$nom_fichier = (preg_match('#^(ht|f)tps?://#', $matches_url[$j][2])) ? pathinfo(parse_url($matches_url[$j][2], PHP_URL_PATH), PATHINFO_BASENAME) : pathinfo($matches_url[$j][2], PATHINFO_BASENAME);
     312 | 
     313 | 								// get the URL. For URIs, uses the GLOBALS[url] tu make the URL
     314 | 								// the files in CSS are relative to the CSS !
     315 | 								if (preg_match('#^https?://#', $matches_url[$j][2])) {
     316 | 									$url_fichier = $matches_url[$j][2];
     317 | 								}
     318 | 								// abs url w/o protocole
     319 | 								elseif (preg_match('#^//#', $matches_url[$j][2])) {
     320 | 									$url_fichier = $url_p['s'].':'.$matches_url[$j][2];
     321 | 								}
     322 | 								// rel url
     323 | 								elseif (preg_match('#^/#', $matches_url[$j][2])) {
     324 | 									$url_fichier = $url_p['s'].'://'.$url_p['h'].$matches_url[$j][2];
     325 | 								}
     326 | 
     327 | 								else {
     328 | 									$endstr = ($w = strpos($file['url_fichier'], '?')) ? $w : strlen($file['url_fichier']);
     329 | 									$url_fichier = substr(substr($file['url_fichier'], 0, $endstr), 0, -strlen($file['nom_fich_origine'])).$matches_url[$j][2];
     330 | 								}
     331 | 								// new rand name, for local storage.
     332 | 								$nouveau_nom = rand_new_name($nom_fichier);
     333 | 								//echo '
    '.$nouveau_nom."\n";
     334 | 								$add = TRUE;
     335 | 
     336 | 								// avoids downloading the same file twice. (yes, we re-use the same $retrievable ($files), why not ?)
     337 | 								foreach ($files as $key => $item) {
     338 | 									if ($item['url_fichier'] == $url_fichier) {
     339 | 										$nouveau_nom = $item['nom_destination'];
     340 | 										$add = FALSE;
     341 | 										break;
     342 | 									}
     343 | 								}
     344 | 
     345 | 								// if we do download, add it to the array.
     346 | 								if ($add === TRUE) {
     347 | 									$files_n = array(
     348 | 										'url_origine' => $matches_url[$j][2],
     349 | 										'url_fichier' => $url_fichier,
     350 | 										'nom_fich_origine' => $nom_fichier,
     351 | 										'nom_destination' => $nouveau_nom
     352 | 										);
     353 | 									$files[] = $files_n;
     354 | 									$liste_css[] = $files_n;
     355 | 								}
     356 | 
     357 | 								// replace url in CSS $data
     358 | 								$data = str_replace($matches_url[$j][2], $nouveau_nom, $data);
     359 | 								// echo $nouveau_nom."
    \n"; 360 | 361 | if (!preg_match('#(css|php|txt|html)#', $file['url_fichier']) ) { 362 | if (FALSE !== ($f = get_external_file($url_fichier, 3)) ) { 363 | file_put_contents($GLOBAL['target_folder'].'/'.$nouveau_nom, $f); 364 | } 365 | } 366 | } 367 | } 368 | 369 | // don't forget to save data 370 | file_put_contents($GLOBAL['target_folder'].'/'.$file['nom_destination'], $data); 371 | } 372 | $n++; 373 | $count = count($liste_css); 374 | } 375 | } 376 | // enregistre un fichier d’informations concernant la page (date, url, titre) 377 | $info = ''; 378 | $info .= 'URL="'.$GLOBAL['url'].'"'."\n"; 379 | $info .= 'TITLE="'.$title.'"'."\n"; 380 | $info .= 'DATE="'.time().'"'."\n"; 381 | file_put_contents($GLOBAL['target_folder'].'/'.'index.ini', $info); 382 | /*$GLOBAL['done']['d'] = 'ajout'; 383 | $GLOBAL['done']['lien'] = $GLOBAL['target_folder'].'/'; */ 384 | 385 | } 386 | 387 | }//die; 388 | 389 | 390 | // in case of delete an entry 391 | if (isset($_GET['suppr']) and $torem = $_GET['suppr'] and $torem != '') { 392 | $torem = htmlspecialchars($_GET['suppr']); 393 | if (is_dir($_GET['suppr'])){ 394 | // suppr tags 395 | $id=idfrompath($_GET['suppr']); 396 | $status=statuspath($_GET['suppr']); 397 | if (isset($GLOBAL['tag_array'][$status][$id])){deltags($GLOBAL['tag_array'][$status][$id],$_GET['suppr'],$id,$status);} 398 | 399 | // suppr page 400 | $sousliste = scandir($_GET['suppr']); // listage des dossiers de data. 401 | $nb_sousfichier = count($sousliste); 402 | for ($j = 0 ; $j < $nb_sousfichier ; $j++) { 403 | if (!($sousliste[$j] == '..' or $sousliste[$j] == '.')) { 404 | unlink($_GET['suppr'].'/'.$sousliste[$j]); 405 | } 406 | } 407 | // then the folder itself. 408 | if (TRUE === rmdir($_GET['suppr'])) { 409 | $GLOBAL['done']['d'] = 'remove'; 410 | 411 | } 412 | } 413 | 414 | header("location: index.php"); 415 | } 416 | 417 | // to private 418 | if (isset($_GET['toprivate']) and $torem = $_GET['toprivate'] and $torem != '') { 419 | $torem = htmlspecialchars($_GET['toprivate']); 420 | if (is_dir($GLOBAL['public_data_folder'].'/'.$_GET['toprivate'])){ 421 | rename ($GLOBAL['public_data_folder'].'/'.$_GET['toprivate'],$GLOBAL['private_data_folder'].'/'.$_GET['toprivate']); 422 | if (isset($GLOBAL['tag_array']['public'][$_GET['toprivate']])){ 423 | $temp=$GLOBAL['tag_array']['public'][$_GET['toprivate']]; 424 | deltags($temp,$_GET['toprivate'],$_GET['toprivate'],'public'); 425 | settags($temp,$_GET['toprivate'],$_GET['toprivate'],'private'); 426 | } 427 | header("location: index.php"); 428 | } 429 | } 430 | // to public 431 | if (isset($_GET['topublic']) and $torem = $_GET['topublic'] and $torem != '') { 432 | $torem = htmlspecialchars($_GET['topublic']); 433 | if (is_dir($GLOBAL['private_data_folder'].'/'.$_GET['topublic'])){ 434 | rename ($GLOBAL['private_data_folder'].'/'.$_GET['topublic'],$GLOBAL['public_data_folder'].'/'.$_GET['topublic']); 435 | if (isset($GLOBAL['tag_array']['private'][$_GET['topublic']])){ 436 | $temp=$GLOBAL['tag_array']['private'][$_GET['topublic']]; 437 | deltags($temp,$_GET['topublic'],$_GET['topublic'],'private'); 438 | settags($temp,$_GET['topublic'],$_GET['topublic'],'public'); 439 | } 440 | header("location: index.php"); 441 | } 442 | } 443 | // disconnect 444 | if (isset($_GET['discotime'])){log_user('disco','');} 445 | 446 | if (isset($_GET['privateget'])&&is_dir($GLOBAL['private_data_folder'].'/'.$_GET['privateget'])){$target=$GLOBAL['private_data_folder'].'/'.$_GET['privateget'];} 447 | 448 | if (isset($_GET['zipprivate'])) { 449 | $ini_file = $GLOBAL['private_data_folder'].'/'.$_GET['zipprivate'].'/index.ini'; 450 | if(is_file($ini_file)){$info=parse_ini_file($ini_file);}else{$info['TITLE']='';} 451 | $origin_folder_path=$GLOBAL['private_data_folder'].'/'.$_GET['zipprivate']; 452 | $zip_foldername=title2filename($info['TITLE']).'-'.$_GET['zipprivate']; 453 | $zip_filename=$zip_foldername.'.zip'; 454 | $zip_completepath=$GLOBAL['data_folder'].'/zipversions/'.$zip_filename; 455 | if (is_file($zip_completepath)){header("location: $zip_completepath");exit();}// il existe déjà, on envoie 456 | if (is_dir($origin_folder_path)){// sinon on crée le zip si le dossier existe 457 | include 'zip.php'; 458 | rename ($origin_folder_path,$zip_foldername); // on le déplace pour éviter de voir la structure de dossiers apparaître dans le zip 459 | zip($zip_filename,$zip_foldername,$GLOBAL['data_folder'].'/zipversions/'); 460 | rename ($zip_foldername,$origin_folder_path); // on le remet à sa place 461 | header('location: '.$GLOBAL['data_folder'].'/zipversions/'.$zip_filename); 462 | } 463 | } 464 | 465 | if (isset($_GET['rename'])&&isset($_GET['to'])&&isset($_GET['file'])) { 466 | if (is_file($_GET['file'].'/index.ini')){ 467 | $ini=parse_ini_file($_GET['file'].'/index.ini'); 468 | 469 | $old=strip_tags(urldecode($_GET['rename'])); 470 | $new=strip_tags(urldecode($_GET['to'])); 471 | $newini='URL="'.$ini['URL'].'"'."\n".'TITLE="'.$new.'"'."\n".'DATE="'.$ini['DATE'].'"'; 472 | file_put_contents($_GET['file'].'/index.ini',$newini); 473 | } 474 | } 475 | if (isset($_GET['settag'])&&isset($_GET['file'])) { 476 | if (is_file($GLOBAL['data_folder'].'/tags.txt')){$GLOBAL['tag_array']=unstore($GLOBAL['data_folder'].'/tags.txt');}else{$GLOBAL['tag_array']=array();} 477 | if (isset($_GET['ispublic'])){$type='public';}else{$type='private';} 478 | $GLOBAL['tag_array'][$type][$_GET['file']]=strip_tags($_GET['settag']); 479 | store($GLOBAL['data_folder'].'/tags.txt',$GLOBAL['tag_array']); 480 | } 481 | }else{ // public get 482 | //download public zip version 483 | if (isset($_GET['zippublic'])) { 484 | $ini_file = $GLOBAL['public_data_folder'].'/'.$_GET['zippublic'].'/index.ini'; 485 | if(is_file($ini_file)){$info=parse_ini_file($ini_file);}else{$info['TITLE']='';} 486 | $origin_folder_path=$GLOBAL['public_data_folder'].'/'.$_GET['zippublic']; 487 | $zip_foldername=title2filename($info['TITLE']).'-'.$_GET['zippublic']; 488 | $zip_filename=$zip_foldername.'.zip'; 489 | $zip_completepath=$GLOBAL['data_folder'].'/zipversions/'.$zip_filename; 490 | if (is_file($zip_completepath)){header("location: $zip_completepath");exit();}// il existe déjà, on envoie 491 | if (is_dir($origin_folder_path)){// sinon on crée le zip si le dossier existe 492 | include 'zip.php'; 493 | rename ($origin_folder_path,$zip_foldername); // on le déplace pour éviter de voir la structure de dossiers apparaître dans le zip 494 | zip($zip_filename,$zip_foldername,$GLOBAL['data_folder'].'/zipversions/'); 495 | rename ($zip_foldername,$origin_folder_path); // on le remet à sa place 496 | header('location: '.$GLOBAL['data_folder'].'/zipversions/'.$zip_filename); 497 | } 498 | } 499 | if (isset($_GET['publicget'])&&is_dir($GLOBAL['public_data_folder'].'/'.$_GET['publicget'])){$target=$GLOBAL['public_data_folder'].'/'.$_GET['publicget'];} 500 | if (isset($_GET['rss'])){ 501 | 502 | $items=array_reverse(search('public',$search_tags)); 503 | $feed=array( 504 | 'infos'=>array( 505 | 'type'=>'rss', 506 | 'description'=>$GLOBAL['rss_description'], 507 | 'title'=>$GLOBAL['rss_title'], 508 | 'link'=>$GLOBAL['respawn_url'], 509 | ) 510 | ); 511 | foreach ($items as $key=>$item){ 512 | if ($item!='index.html'){ 513 | if (is_dir($GLOBAL['public_data_folder'].'/'.$item)){ 514 | if (is_file($GLOBAL['public_data_folder'].'/'.$item.'/index.ini')){ 515 | $infos=parse_ini_file($GLOBAL['public_data_folder'].'/'.$item.'/index.ini'); 516 | date_default_timezone_set('Europe/Paris'); 517 | $infos['DATE']= date("r", $infos['DATE']); 518 | if ($infos['TITLE']==''){$infos['TITLE']='Version Respawn de '.$infos['URL'];} 519 | $feed['items'][$key]=array( 520 | 'description'=>'Version Respawn de '.$infos['URL'], 521 | 'title'=>$infos['TITLE'], 522 | 'link'=>$GLOBAL['respawn_url'].'?publicget='.$item, 523 | 'guid'=>$infos['URL'], 524 | 'pubDate'=>$infos['DATE'], 525 | ); 526 | } 527 | } 528 | } 529 | 530 | } 531 | exit(array2feed($feed)); 532 | } 533 | if (isset($_GET['api'])){ 534 | $content=array(); 535 | $items=search('public',$search_tags); 536 | foreach ($items as $key=>$item){ 537 | if ($item!='index.html'){ 538 | if (is_dir($GLOBAL['public_data_folder'].'/'.$item)){ 539 | if (is_file($GLOBAL['public_data_folder'].'/'.$item.'/index.ini')){ 540 | $infos=parse_ini_file($GLOBAL['public_data_folder'].'/'.$item.'/index.ini'); 541 | date_default_timezone_set('Europe/Paris'); 542 | $infos['DATE']= date('d/m/Y', $infos['DATE']); 543 | if ($infos['TITLE']==''){$infos['TITLE']='Respawn de '.$infos['URL'];} 544 | $t=''; 545 | if (isset($GLOBAL['tag_array']['public'][$item])){$t=$GLOBAL['tag_array']['public'][$item];} 546 | $content[$key]=array( 547 | 'description'=>'Version Respawn de '.$infos['URL'], 548 | 'title'=>$infos['TITLE'], 549 | 'respawn_link'=>$GLOBAL['respawn_url'].'?publicget='.$item, 550 | 'original_link'=>$infos['URL'], 551 | 'date'=>$infos['DATE'], 552 | 'tags'=>$t, 553 | ); 554 | } 555 | } 556 | } 557 | 558 | } 559 | exit(serialize($content)); 560 | } 561 | } 562 | 563 | 564 | 565 | function url_parts() { 566 | global $GLOBAL; 567 | $url_p['s'] = parse_url($GLOBAL['url'], PHP_URL_SCHEME); $url_p['s'] = (is_null($url_p['s'])) ? '' : $url_p['s']; 568 | $url_p['h'] = parse_url($GLOBAL['url'], PHP_URL_HOST); $url_p['h'] = (is_null($url_p['h'])) ? '' : $url_p['h']; 569 | $url_p['p'] = parse_url($GLOBAL['url'], PHP_URL_PORT); $url_p['p'] = (is_null($url_p['p'])) ? '' : ':'.$url_p['p']; 570 | $url_p['pat'] = parse_url($GLOBAL['url'], PHP_URL_PATH); $url_p['pat'] = (is_null($url_p['pat'])) ? '' : $url_p['pat']; 571 | $url_p['file'] = pathinfo($url_p['pat'], PATHINFO_BASENAME); 572 | return $url_p; 573 | } 574 | 575 | // 576 | // Gets external file by URL. 577 | // Make a stream context (better). 578 | // 579 | 580 | function get_external_file($url, $timeout) { 581 | $context = stream_context_create(array("ssl"=>array("verify_peer"=>false,"verify_peer_name"=>false),'http'=>array('timeout' => $timeout))); // Timeout : time until we stop waiting for the response. 582 | $data = @file_get_contents($url, false, $context, -1, 4000000); // We download at most 4 Mb from source. 583 | if (isset($data) and isset($http_response_header) and isset($http_response_header[0]) and (strpos($http_response_header[0], '200 OK') !== FALSE) ) { 584 | return $data; 585 | } 586 | else { 587 | return FALSE; 588 | } 589 | } 590 | 591 | // 592 | // CREATE FOLDER 593 | // 594 | 595 | function creer_dossier($dossier, $indexfile = FALSE) { 596 | if ( !is_dir($dossier) ) { 597 | if (mkdir($dossier, 0777, TRUE) === TRUE) { 598 | chmod($dossier, 0777); 599 | if ($indexfile == TRUE) touch($dossier.'/index.html'); // make a index.html file : avoid the possibility of listing folder's content 600 | return TRUE; 601 | } else { 602 | return FALSE; 603 | } 604 | } 605 | return TRUE; // if folder already exists 606 | } 607 | 608 | 609 | // 610 | // PARSE TAGS AND LISTE DOWNLOADABLE CONTENT IN ARRAY 611 | // Also modify html source code to replace absolutes URLs with local URIs. 612 | // 613 | 614 | function list_retrievable_data($url, &$data) { 615 | $url_p = url_parts(); 616 | 617 | $retrievable = array(); 618 | 619 | // cherche les balises 'link' qui contiennent un rel="(icon|favicon|stylesheet)" et un href="" 620 | // (on ne cherche pas uniquement le "href" sinon on se retrouve avec les flux RSS aussi) 621 | $matches = array(); 622 | preg_match_all('#<\s*link[^>]+rel=["\'][^"\']*(shortcut icon|apple-touch-icon|icon|favicon|stylesheet)[^"\']*["\'][^>]*>#Si', $data, $matches, PREG_SET_ORDER); 623 | // dans les link avec une icone, stylesheet, etc récupère l’url. 624 | foreach($matches as $i => $key) { 625 | $type = (strpos($key[1], 'stylesheet') !== FALSE) ? 'css' : 'icon'; 626 | if ( (preg_match_all('#(href|src)=["\']([^"\']*)["\']#i', $matches[$i][0], $matches_attr, PREG_SET_ORDER) === 1) ) { 627 | $retrievable = add_table_and_replace($data, $retrievable, $matches[$i][0], $matches_attr[0][2], $url_p, $type); 628 | } 629 | } 630 | 631 | // recherche les images, scripts, audio & videos HTML5. 632 | // dans les balises, récupère l’url/uri contenue dans les src="". 633 | // le fichier sera téléchargé. 634 | // Le nom du fichier sera modifié pour être unique, et sera aussi modifié dans le code source. 635 | $matches = array(); 636 | preg_match_all('#<\s*(source|audio|img|script|video)[^>]+src="([^"]*)"[^>]*>#Si', $data, $matches, PREG_SET_ORDER); 637 | 638 | foreach($matches as $i => $key) { 639 | if (preg_match('#^data:#', $matches[$i][2])) break; 640 | $retrievable = add_table_and_replace($data, $retrievable, $matches[$i][0], $matches[$i][2], $url_p, 'other'); 641 | } 642 | 643 | // Dans les balises 23 | 24 |
    -------------------------------------------------------------------------------- /mypersonaldata/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/mypersonaldata/index.html -------------------------------------------------------------------------------- /mypersonaldata/private/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/mypersonaldata/private/index.html -------------------------------------------------------------------------------- /mypersonaldata/public/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/mypersonaldata/public/index.html -------------------------------------------------------------------------------- /mypersonaldata/tags.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/mypersonaldata/tags.txt -------------------------------------------------------------------------------- /mypersonaldata/zipversions/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/broncowdd/respawn/71d7e46985230183fe9899847cd48ae80d40f916/mypersonaldata/zipversions/index.html -------------------------------------------------------------------------------- /readme.md: -------------------------------------------------------------------------------- 1 | RESPAWN 2.0: 2 | 3 | Ceci est un fork de l'appli Respawn de Timo le Hollandais Volant. 4 | J'ai utilisé le moteur de cette appli et y ai ajouté quelques aspect. 5 | Nouveautés de la version 2.0: 6 | - un système de tags pour pouvoir filtrer les pages (bouton (T) pour ajouter modifier les tags d'une page), 7 | - un flux RSS des pages publiques filtrable par tags également (le lien RSS de la page en cours est en pied de page) 8 | - une API permettant de récupérer un array d'infos sur les pages au format sérialisé (on peut également filtrer le résultat par tag) 9 | - un bouton de renommage des titres de page (R) 10 | - un bouton pour télécharger le zip de la page qu'on est en train de visionner. 11 | 12 | Ajouts de la version précédente: 13 | - un bookmarklet pour respawner directement une page (depuis un ordinateur connecté en tant qu'admin) 14 | - le verrouillage par mot de passe, 15 | - deux espaces séparés : un public et un privé (dont on peut (doit!) renommer les dossiers dans la config) 16 | - l'ajout (si possible) de la favicon 17 | - l'ajout d'icones et d'un design un peu amélioré, même si beaucoup reste à faire 18 | - l'ajout d'un logo propre à cette appli 19 | 20 | Merci à Timo pour cette merveille de simplicité et d'efficacité qui concourt à conserver et diffuser l'information ! 21 | 22 | 23 | INSTALLATION: 24 | Dézippez l'archive sur votre serveur, allez à l'adresse, créez un mot de passe dans la première fenêtre et c'est parti. 25 | 26 | Démo: http://respawn.warriordudimanche.net/index.php?public 27 | 28 | Bronco - bronco@warriordudimanche.net 29 | -------------------------------------------------------------------------------- /readme.txt: -------------------------------------------------------------------------------- 1 | zip : les noms de fichiers sont plus explicites 2 | un bouton déconnect 3 | retrait du bouton supprimer pour la page publique -------------------------------------------------------------------------------- /zip.php: -------------------------------------------------------------------------------- 1 | open($nom_archive, ZipArchive::CREATE) !== TRUE) { 27 | // La création de l'archive a échouée 28 | return false; 29 | } 30 | } 31 | 32 | if(substr($adr_dossier, -1)!='/') { 33 | // Si l'adresse du dossier ne se termine pas par '/', on le rajoute 34 | $adr_dossier .= '/'; 35 | } 36 | 37 | if($dossier_base=="") { 38 | // Si $dossier_base est vide ça veut dire que l'on rentre 39 | // dans la fonction pour la première fois. Donc on retient 40 | // le tout premier dossier (le dossier racine) dans $dossier_base 41 | $dossier_base=$adr_dossier; 42 | } 43 | 44 | if(file_exists($adr_dossier)) { 45 | if(@$dossier = opendir($adr_dossier)) { 46 | while(false !== ($fichier = readdir($dossier))) { 47 | if($fichier != '.' && $fichier != '..') { 48 | if(is_dir($adr_dossier.$fichier)) { 49 | $zip->addEmptyDir($adr_dossier.$fichier); 50 | zip($nom_archive, $adr_dossier.$fichier, $dossier_destination, $zip, $dossier_base); 51 | } 52 | else { 53 | $zip->addFile($adr_dossier.$fichier); 54 | } 55 | } 56 | } 57 | } 58 | } 59 | 60 | if($dossier_base==$adr_dossier) { 61 | // On ferme la zip 62 | $zip->close(); 63 | 64 | if($dossier_destination!='') { 65 | if(substr($dossier_destination, -1)!='/') { 66 | // Si l'adresse du dossier ne se termine pas par '/', on le rajoute 67 | $dossier_destination .= '/'; 68 | } 69 | 70 | // On déplace l'archive dans le dossier voulu 71 | if(rename($nom_archive, $dossier_destination.$nom_archive)) { 72 | return true; 73 | } 74 | else { 75 | return false; 76 | } 77 | } 78 | else { 79 | return true; 80 | } 81 | } 82 | } 83 | 84 | ?> 85 | --------------------------------------------------------------------------------