Project

General

Profile

« Previous | Next » 

Revision 2095

Added by darkviper almost 11 years ago

! /functions::make_thumb() set JPG-compression to 100%
! /database::showError() output text corrected
! ../captcha.php::call_captcha() imagesize corected
! droplet >> [[SiteModified]] recoded
! droplet >> [[ModifiedWhen]] recoded
! install/index length of password restricted to 30 chars

View differences:

branches/2.8.x/CHANGELOG
11 11
! = Update/Change
12 12
===============================================================================
13 13

  
14
03 Feb-2014 Build 2095 Manuela v.d.Decken(DarkViper)
15
! /functions::make_thumb() set JPG-compression to 100%
16
! /database::showError() output text corrected
17
! ../captcha.php::call_captcha() imagesize corected
18
! droplet >> [[SiteModified]]  recoded
19
! droplet >> [[ModifiedWhen]]  recoded
20
! install/index length of password restricted to 30 chars
14 21
30 Jan-2014 Build 2094 Manuela v.d.Decken(DarkViper)
15 22
# TranslateAdaptorWbOldStyle::_getAddonPath now ignores a missing language file
16 23
! admin::print_header() now provides all translations in theme::header.htt and accepts language files in theme
branches/2.8.x/wb/include/captcha/captcha.php
113 113
		switch(CAPTCHA_TYPE) {
114 114
		case 'calc_image':
115 115
			$captcha_width = 160;
116
			$captcha_height = 55;
116
			$captcha_height = 60;
117 117
			break;
118 118
		case 'calc_ttf_image':
119 119
			$captcha_width = 175;
......
125 125
			break;
126 126
		case 'old_image':
127 127
			$captcha_width = 160;
128
			$captcha_height = 55;
128
			$captcha_height = 60;
129 129
			break;
130 130
		default:
131 131
			$captcha_width = 250;
branches/2.8.x/wb/admin/interface/version.php
51 51

  
52 52
// check if defined to avoid errors during installation (redirect to admin panel fails if PHP error/warnings are enabled)
53 53
if(!defined('VERSION')) define('VERSION', '2.8.4');
54
if(!defined('REVISION')) define('REVISION', '2094');
54
if(!defined('REVISION')) define('REVISION', '2095');
55 55
if(!defined('SP')) define('SP', '');
branches/2.8.x/wb/framework/class.database.php
25 25
		$msg .= 'tried to create an invalid <b>'.$y[1]['class'].'</b> - object</p>';
26 26
		$msg .= '<p>Please replace <span style="color:#dd0000; font-weight:bold;">';
27 27
		$msg .= '$database = new database();</span> by <span style="color:#00bb00; font-weight:bold;">';
28
		$msg .= '$database = WbDatabase::getInstance();</span>.</p>';
28
		$msg .= '$database = WbDatabase::getInstance();</span></p>';
29 29
		$msg .= '<p>Also you can get information and help from the ';
30 30
		$msg .= '<a href="http://www.websitebaker.org/forum/index.php/board,2.0.html">WebsiteBaker Forum</a></p>';
31 31
		$msg .= '<hr />';
......
35 35
		$msg .= 'wurde versucht, ein ung&uuml;ltiges <b>'.$y[1]['class'].'</b> - Objekt zu erstellen.</p>';
36 36
		$msg .= '<p>Bitte ersetzen Sie <span style="color:#dd0000; font-weight:bold;">';
37 37
		$msg .= '$database = new database();</span> durch <span style="color:#00bb00; font-weight:bold;">';
38
		$msg .= '$database = WbDatabase::getInstance();</span>.</p>';
38
		$msg .= '$database = WbDatabase::getInstance();</span></p>';
39 39
		$msg .= '<p>Auch k&ouml;nnen sie auch Informationen und Hilfe im ';
40 40
		$msg .= '<a href="http://www.websitebaker.org/forum/index.php/board,31.0.html">WebsiteBaker Forum</a> finden.</p>';
41 41
		$msg .= '</div>';
branches/2.8.x/wb/framework/functions.php
978 978
		$source = imageCreateFromJpeg($source);
979 979
		$dst_img = ImageCreateTrueColor($thumb_w, $thumb_h);
980 980
		imagecopyresampled($dst_img,$source,0,0,0,0,$thumb_w,$thumb_h,$original_x,$original_y);
981
		imagejpeg($dst_img, $destination);
981
		imagejpeg($dst_img, $destination, 100);
982 982
		// Clear memory
983 983
		imagedestroy($dst_img);
984 984
		imagedestroy($source);
branches/2.8.x/wb/install/save.php
356 356
if(!isset($_POST['admin_email']) OR $_POST['admin_email'] == '') {
357 357
	set_error('Please enter an email for the Administrator account','admin_email');
358 358
} else {
359
	if(preg_match('/^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,4})$/i', $_POST['admin_email'])) {
359
	if(preg_match('/^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,})$/i', $_POST['admin_email'])) {
360 360
		$admin_email = $_POST['admin_email'];
361 361
	} else {
362 362
		set_error('Please enter a valid email address for the Administrator account','admin_email');
......
376 376
if($admin_password != $admin_repassword) {
377 377
	set_error('Sorry, the two Administrator account passwords you entered do not match','admin_repassword');
378 378
}
379
if (mb_strlen($admin_password) < 6) {
380
	set_error('Sorry, the password must have 6 chars at last','admin_password');
381
}
382

  
379 383
// End admin user details code
380 384

  
381 385
// Try and write settings to config file
branches/2.8.x/wb/install/index.php
179 179
</tr>
180 180
</table>
181 181

  
182
<form name="website_baker_installation_wizard" action="save.php" method="post">
182
<form name="website_baker_installation_wizard" action="save.php" method="post" accept-charset="UTF-8">
183 183
<input type="hidden" name="url" value="" />
184 184
<input type="hidden" name="username_fieldname" value="admin_username" />
185 185
<input type="hidden" name="password_fieldname" value="admin_password" />
......
552 552
		<tr>
553 553
			<td class="name">Password:</td>
554 554
			<td class="value">
555
				<input <?php echo field_error('admin_password');?> type="password" tabindex="16" name="admin_password" value="" />
555
				<input <?php echo field_error('admin_password');?> type="password" maxlength="30" tabindex="16" name="admin_password" value="" />
556 556
			</td>
557 557
		</tr>
558 558
		<tr>
559 559
			<td class="name">Re-Password:</td>
560 560
			<td class="value">
561
				<input <?php echo field_error('admin_repassword');?> type="password" tabindex="17" name="admin_repassword" value=""  />
561
				<input <?php echo field_error('admin_repassword');?> type="password" maxlength="30" tabindex="17" name="admin_repassword" value=""  />
562 562
			</td>
563 563
		</tr>
564 564
		<tr>
branches/2.8.x/wb/modules/droplets/example/ModifiedWhen.php
1 1
//:Displays the last modification time of the current page
2 2
//:Use [[ModifiedWhen]]
3
global $database, $wb;
-if (PAGE_ID>0) {
-	$query=$database->query("SELECT modified_when FROM ".TABLE_PREFIX."pages where page_id=".PAGE_ID);
-	$mod_details=$query->fetchRow();
-	return "This page was last modified on ".date("d/m/Y",$mod_details[0]). " at ".date("H:i",$mod_details[0]).".";
-}
3

  
4
$sRetval = '';
5
if (($aPageDate = (($GLOBALS['wb']->page_id) ? $GLOBALS['wb']->page['modified_when'] : 0))) {
6
    $sRetval = 'This page was last modified on '.date('d/m/Y', $aPageDate).' at '.date('H:i', $aPageDate);
7
}
8
return $sRetval;
branches/2.8.x/wb/modules/droplets/example/SiteModified.php
1
<?php
1 2
//:Create information on when your site was last updated.
2 3
//:Create information on when your site was last updated. Any page update counts.
3
global $database, $wb;
-if (PAGE_ID>0) {
-	$query=$database->query("SELECT max(modified_when) FROM ".TABLE_PREFIX."pages");
-	$mod_details=$query->fetchRow();
-	return "This site was last modified on ".date("d/m/Y",$mod_details[0]). " at ".date("H:i",$mod_details[0]).".";
-}
4
$sRetval = '';
5
if (PAGE_ID > 0) {
6
    $sql = 'SELECT MAX(`modified_when`) `modified` '
7
         . 'FROM `'.WbDatabase::getInstance()->TablePrefix.'pages`';
8
	$iModified = WbDatabase::getInstance()->getOne($sql);
9
    $sRetval = "This site was last modified on ".date("d/m/Y",$iModified). " at ".date("H:i",$iModified).".";
10
}
11
return $sRetval;

Also available in: Unified diff