3ef995c2108fe77d22c0b556fb9717cb848bc48f
bernd Webapp-Installer für Drupal-7

bernd authored 14 years ago

1) <?php
Hanno Böck Add newlines before comment...

Hanno Böck authored 6 days ago

2) 
Bernd Wurst Added license tags for CC0,...

Bernd Wurst authored 13 years ago

3) /*
4) This file belongs to the Webinterface of schokokeks.org Hosting
5) 
Hanno Böck Change license from CC0 to...

Hanno Böck authored 2 years ago

6) Written by schokokeks.org Hosting, namely
Bernd Wurst Added license tags for CC0,...

Bernd Wurst authored 13 years ago

7)   Bernd Wurst <bernd@schokokeks.org>
8)   Hanno Böck <hanno@schokokeks.org>
9) 
Hanno Böck Change license from CC0 to...

Hanno Böck authored 2 years ago

10) This code is published under a 0BSD license.
Bernd Wurst Added license tags for CC0,...

Bernd Wurst authored 13 years ago

11) 
12) Nevertheless, in case you use a significant part of this code, we ask (but not require, see the license) that you keep the authors' names in place and return your changes to the public. We would be especially happy if you tell us what you're going to do with this code.
13) */
bernd Webapp-Installer für Drupal-7

bernd authored 14 years ago

14) 
15) require_once('inc/debug.php');
16) 
17) require_once('webapp-installer.php');
18) 
19) 
20) function validate_data($post)
21) {
Hanno Fix coding style with php-c...

Hanno authored 6 years ago

22)     DEBUG('Validating Data:');
23)     DEBUG($post);
Hanno Böck Codingstyle PSR12 + array s...

Hanno Böck authored 3 years ago

24)     $fields = ['adminuser', 'adminpassword', 'adminemail', 'sitename', 'siteemail'];
Hanno Fix coding style with php-c...

Hanno authored 6 years ago

25)     foreach ($fields as $field) {
Hanno Böck Fix not operator (!) spaces

Hanno Böck authored 1 year ago

26)         if ((!isset($post[$field])) || $post[$field] == '') {
Hanno Böck Spaces between string conca...

Hanno Böck authored 1 year ago

27)             system_failure('Nicht alle Werte angegeben (' . $field . ')');
Hanno Fix coding style with php-c...

Hanno authored 6 years ago

28)         }
29)     }
30) 
31)     $dbdata = create_webapp_mysqldb('drupal7', $post['sitename']);
32) 
33)     $data = "adminuser={$post['adminuser']}
bernd Webapp-Installer für Drupal-7

bernd authored 14 years ago

34) adminpassword={$post['adminpassword']}
35) adminemail={$post['adminemail']}
36) sitename={$post['sitename']}
37) siteemail={$post['siteemail']}
38) dbname={$dbdata['dbname']}
39) dbuser={$dbdata['dbuser']}
40) dbpass={$dbdata['dbpass']}";
Hanno Fix coding style with php-c...

Hanno authored 6 years ago

41)     DEBUG($data);
42)     return $data;