354c05a4ddd678c49bcbba458bffa7d13482139a
bernd biete auch Drupal 6 an

bernd authored 15 years ago

1) <?php
Bernd Wurst Added license tags for CC0,...

Bernd Wurst authored 12 years ago

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

Hanno Böck authored 1 year ago

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

Bernd Wurst authored 12 years ago

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

Hanno Böck authored 1 year ago

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

Bernd Wurst authored 12 years ago

10) 
11) 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.
12) */
bernd biete auch Drupal 6 an

bernd authored 15 years ago

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

Hanno authored 5 years ago

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

Hanno Böck authored 2 years ago

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

Hanno authored 5 years ago

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

Hanno Böck authored 6 months ago

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

Hanno Böck authored 6 months ago

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

Hanno authored 5 years ago

27)         }
28)     }
29) 
30)     $dbdata = create_webapp_mysqldb('drupal6', $post['sitename']);
31) 
32)     $passwordhash = md5($post['adminpassword']);
Hanno remove whitespace in empty...

Hanno authored 5 years ago

33) 
Hanno Fix coding style with php-c...

Hanno authored 5 years ago

34)     $data = "adminuser={$post['adminuser']}
bernd biete auch Drupal 6 an

bernd authored 15 years ago

35) adminpassword={$passwordhash}
36) adminemail={$post['adminemail']}
37) sitename={$post['sitename']}
38) siteemail={$post['siteemail']}
bernd Frage Datenbank-Kürzel nich...

bernd authored 15 years ago

39) dbname={$dbdata['dbname']}
40) dbuser={$dbdata['dbuser']}
41) dbpass={$dbdata['dbpass']}";
Hanno Fix coding style with php-c...

Hanno authored 5 years ago

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