Project

General

Profile

« Previous | Next » 

Revision 1655

Added by Dietmar over 12 years ago

add replyto to form module (see DEVINFOS)

View differences:

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

  
14
01 Apr-2012 Build 1655 Dietmar Woellbrink (Luisehahne)
15
+ add replyto to form module (see DEVINFOS)
14 16
01 Apr-2012 Build 1654 Dietmar Woellbrink (Luisehahne)
15 17
# Fixed SERVER_EMAIL in languages, needs double brackets
16 18
! Installer redesign Step 2
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.3');
54
if(!defined('REVISION')) define('REVISION', '1654');
54
if(!defined('REVISION')) define('REVISION', '1655');
55 55
if(!defined('SP')) define('SP', '');
branches/2.8.x/wb/framework/class.wb.php
416 416
//			$myMail->AddReplyTo($fromaddress);                // REPLY TO:
417 417
		}
418 418
		if($replyTo) {
419
			$myMail->AddReplyTo($fromaddress);                // REPLY TO:
419
			$myMail->AddReplyTo($replyTo);                // REPLY TO:
420 420
		}
421 421
		// define recepient and information to send out
422 422
		$myMail->AddAddress($toaddress);                      // TO:
branches/2.8.x/wb/modules/form/info.php
4 4
 * @category        module
5 5
 * @package         Form
6 6
 * @author          WebsiteBaker Project
7
 * @copyright       2009-2011, Website Baker Org. e.V.
7
 * @copyright       2009-2012, Website Baker Org. e.V.
8 8
 * @link			http://www.websitebaker2.org/
9 9
 * @license         http://www.gnu.org/licenses/gpl.html
10
 * @platform        WebsiteBaker 2.8.x
10
 * @platform        WebsiteBaker 2.8.3
11 11
 * @requirements    PHP 5.2.2 and higher
12 12
 * @version         $Id$
13 13
 * @filesource		$HeadURL$
......
16 16
 */
17 17

  
18 18
// Must include code to stop this file being access directly
19
/* -------------------------------------------------------- */
20
if(defined('WB_PATH') == false)
21
{
22
	// Stop this file being access directly
23
		die('<head><title>Access denied</title></head><body><h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2></body></html>');
19
if(!defined('WB_URL')) {
20
	require_once(dirname(dirname(dirname(__FILE__))).'/framework/globalExceptionHandler.php');
21
	throw new IllegalFileException();
24 22
}
25 23
/* -------------------------------------------------------- */
26 24
$module_directory = 'form';
27 25
$module_name = 'Form';
28 26
$module_function = 'page';
29
$module_version = '2.8.4';
30
$module_platform = '2.8.x';
31
$module_author = 'Ryan Djurovich & Rudolph Lartey - additions John Maats - PCWacht';
27
$module_version = '2.8.5';
28
$module_platform = '2.8.3';
29
$module_author = 'Ryan Djurovich & Rudolph Lartey - additions John Maats - PCWacht, dev-team';
32 30
$module_license = 'GNU General Public License';
33 31
$module_description = 'This module allows you to create customised online forms, such as a feedback form. '.
34 32
'Thank-you to Rudolph Lartey who help enhance this module, providing code for extra field types, etc.';
branches/2.8.x/wb/modules/form/modify_settings.php
84 84

  
85 85
<input type="hidden" name="page_id" value="<?php echo $page_id; ?>" />
86 86
<input type="hidden" name="section_id" value="<?php echo $section_id; ?>" />
87
<input type="hidden" name="success_email_to" value="" />
87 88
<?php echo $admin->getFTAN(); ?>
88 89

  
89 90
<table summary="" class="row_a" cellpadding="2" cellspacing="0" border="0" width="100%">
......
166 167
	<tbody>
167 168
	<tr>
168 169
		<td class="frm-setting_name"><?php echo $TEXT['EMAIL'].' '.$MOD_FORM['TO']; ?>:</td>
169
		<td class="frm-setting_value">
170
			<select name="success_email_to" style="width: 98%;">
171
			<option value="" onclick="javascript: document.getElementById('success_email_to').style.display = 'block';"><?php echo $TEXT['NONE']; ?></option>
172
			<?php
173
			$success_email_to = str_replace($raw, $friendly, ($setting['success_email_to']));
174
			$sql  = 'SELECT `field_id`, `title` FROM `'.TABLE_PREFIX.'mod_form_fields` ';
175
			$sql .= 'WHERE `section_id` = '.(int)$section_id.' ';
176
			$sql .= '  AND  `type` = \'email\' ';
177
			$sql .= 'ORDER BY `position` ASC ';
178
			if($query_email_fields = $database->query($sql)) {
179
				if($query_email_fields->numRows() > 0) {
180
					while($field = $query_email_fields->fetchRow(MYSQL_ASSOC)) {
181
						?>
182
						<option value="field<?php echo $field['field_id']; ?>"<?php if($success_email_to == 'field'.$field['field_id']) { echo ' selected'; $selected = true; } ?> onclick="javascript: document.getElementById('email_from').style.display = 'none';">
183
							<?php echo $TEXT['FIELD'].': '.$field['title']; ?>
184
						</option>
185
						<?php
186
					}
187
				}
188
			}
189
			?>
190
			</select>
191
		</td>
170
		<td class="frm-setting_value"><?php echo  $MOD_FORM['RECIPIENT'] ?>	</td>
192 171
	</tr>
193 172

  
194 173
	<tr>
......
198 177
			<input type="text" name="success_email_fromname" style="width: 98%;" maxlength="255" value="<?php echo str_replace($raw, $friendly, ($setting['success_email_fromname'])); ?>" />
199 178
		</td>
200 179
	</tr>
180

  
201 181
	<tr>
202 182
		<td class="frm-setting_name"><?php echo $TEXT['EMAIL'].' '.$TEXT['SUBJECT']; ?>:</td>
203 183
		<td class="frm-setting_value">
branches/2.8.x/wb/modules/form/view.php
29 29
require_once(!file_exists($lang) ? (dirname(__FILE__)) . '/languages/EN.php' : $lang );
30 30

  
31 31
include_once(WB_PATH .'/framework/functions.php');
32
$aWebsiteTitle = (defined('WEBSITE_TITLE') && WEBSITE_TITLE != '' ? WEBSITE_TITLE : $_SERVER['SERVER_NAME']);
33
$replace = array('WEBSITE_TITLE' => $aWebsiteTitle );
34
$MOD_FORM['EMAIL_SUBJECT'] = replace_vars($MOD_FORM['EMAIL_SUBJECT'], $replace);
35
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = replace_vars($MOD_FORM['SUCCESS_EMAIL_TEXT'], $replace);
36
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = replace_vars($MOD_FORM['SUCCESS_EMAIL_SUBJECT'], $replace);
32 37
/*
33 38
function removebreaks($value) {
34 39
	return trim(preg_replace('=((<CR>|<LF>|0x0A/%0A|0x0D/%0D|\\n|\\r)\S).*=i', null, $value));
......
115 120
}
116 121

  
117 122
// Work-out if the form has been submitted or not
118
if($_POST == array()) {
123
if($_POST == array())
124
{
119 125
	require_once(WB_PATH.'/include/captcha/captcha.php');
120 126

  
121 127
	// Set new submission ID in session
......
129 135
	// Get settings
130 136
	$sql  = 'SELECT * FROM `'.TABLE_PREFIX.'mod_form_settings` ';
131 137
	$sql .= 'WHERE section_id = '.$section_id.' ';
132
	if($query_settings = $database->query($sql)) {
133
		if($query_settings->numRows() > 0) {
138
	if($query_settings = $database->query($sql))
139
	{
140
		if($query_settings->numRows() > 0)
141
		{
134 142
			$fetch_settings = $query_settings->fetchRow(MYSQL_ASSOC);
135 143
			$header = str_replace('{WB_URL}',WB_URL,$fetch_settings['header']);
136 144
			$field_loop = $fetch_settings['field_loop'];
......
138 146
			$use_captcha = $fetch_settings['use_captcha'];
139 147
			$form_name = 'form';
140 148
			$use_xhtml_strict = false;
149
			$page_id = $fetch_settings['page_id'];
141 150
		}
142 151
	}
143 152

  
......
182 191
			<?php }
183 192

  
184 193
	// Print header  MYSQL_ASSOC
185
   echo $header.PHP_EOL;
194
		   echo $header."\n";
186 195
			while($field = $query_fields->fetchRow(MYSQL_ASSOC)) {
187 196
				// Set field values
188 197
				$field_id = $field['field_id'];
......
196 205
				}
197 206
				$values = array($field_title);
198 207
				if ($field['required'] == 1) {
199
					$values[] = '<span class="frm-required">*</span>'.PHP_EOL;
208
					$values[] = '<span class="frm-required">*</span>'."\n";
200 209
				} else {
201 210
					$values[] = '';
202 211
				}
......
268 277
	// Check that submission ID matches
269 278
	if(isset($_SESSION['form_submission_id']) AND isset($_POST['submission_id']) AND $_SESSION['form_submission_id'] == $_POST['submission_id']) {
270 279

  
280
	   $mail_replyto = '';
281
	   $mail_replyName = '';
282
		if( $wb->is_authenticated() && $wb->get_email() ) {
283
		   $mail_replyto = $wb->get_email();
284
		   $mail_replyName = htmlspecialchars($wb->add_slashes($wb->get_display_name()));
285
		}
286

  
271 287
		// Set new submission ID in session
272 288
		$_SESSION['form_submission_id'] = new_submission_id();
273 289

  
......
301 317
				}
302 318
*/
303 319
				$email_fromname = $fetch_settings['email_fromname'];
320
// 				$email_fromname = (($mail_replyName='') ? $fetch_settings['email_fromname'] : $mail_replyName);
321
 				$email_fromname = (($mail_replyName='') ? htmlspecialchars($wb->add_slashes($fetch_settings['email_fromname'])) : $mail_replyName);
322

  
304 323
				if(substr($email_fromname, 0, 5) == 'field') {
305 324
					// Set the email_fromname to field to what the user entered in the specified field
306 325
					$email_fromname = htmlspecialchars($wb->add_slashes($_POST[$email_fromname]));
307 326
				}
327

  
308 328
				$email_subject = (($fetch_settings['email_subject'] != '') ? $fetch_settings['email_subject'] : $MOD_FORM['EMAIL_SUBJECT']);
309 329
				$success_page = $fetch_settings['success_page'];
330
				$success_email_to = $mail_replyto;
331
/*
310 332
				$success_email_to = (($fetch_settings['success_email_to'] != '') ? $fetch_settings['success_email_to'] : '');
311 333
				if(substr($success_email_to, 0, 5) == 'field') {
312 334
					// Set the success_email to field to what the user entered in the specified field
313 335
					$success_email_to = htmlspecialchars($wb->add_slashes($_POST[$success_email_to]));
314 336
				}
337
*/
315 338
				$success_email_from = $admin->add_slashes(SERVER_EMAIL);
316 339
				$success_email_fromname = $fetch_settings['success_email_fromname'];
317 340
				$success_email_text = htmlspecialchars($wb->add_slashes($fetch_settings['success_email_text']));
......
324 347
				exit($TEXT['UNDER_CONSTRUCTION']);
325 348
			}
326 349
		}
350

  
327 351
		$email_body = '';
328

  
329 352
		// Create blank "required" array
330 353
		$required = array();
331 354

  
......
336 359
				if(!isset($_POST['captcha']) OR !isset($_SESSION['captcha']) OR $_POST['captcha'] != $_SESSION['captcha']) {
337 360
					$replace = array('webmaster_email' => emailAdmin() );
338 361
					$captcha_error = replace_vars($MOD_FORM['INCORRECT_CAPTCHA'], $replace);
362
					$required[]= '';
339 363
				}
340 364
			} else {
341 365
				$replace = array('webmaster_email'=>emailAdmin() );
342 366
				$captcha_error = replace_vars($MOD_FORM['INCORRECT_CAPTCHA'],$replace );
367
				$required[]= '';
343 368
			}
344 369
		}
345 370
		if(isset($_SESSION['captcha'])) { unset($_SESSION['captcha']); }
......
354 379
				while($field = $query_fields->fetchRow(MYSQL_ASSOC)) {
355 380
					// Add to message body
356 381
					if($field['type'] != '') {
357
						if(!empty($_POST['field'.$field['field_id']])) {
382
						if(!empty($_POST['field'.$field['field_id']]))
383
						{
358 384
							// do not allow droplets in user input!
359 385
							if (is_array($_POST['field'.$field['field_id']])) {
360
								$_SESSION['field'.$field['field_id']] = str_replace(array("[[", "]]"), array("&#91;&#91;", "&#93;&#93;"), $_POST['field'.$field['field_id']]);
386
								$_SESSION['field'.$field['field_id']] = str_replace(array("[[", "]]"), array("&#91;&#91;", "&#93;&#93;"), $wb->strip_slashes($_POST['field'.$field['field_id']]));
361 387
							} else {
362
								$_SESSION['field'.$field['field_id']] = str_replace(array("[[", "]]"), array("&#91;&#91;", "&#93;&#93;"), htmlspecialchars($_POST['field'.$field['field_id']]));
388
								$_SESSION['field'.$field['field_id']] = str_replace(array("[[", "]]"), array("&#91;&#91;", "&#93;&#93;"), htmlspecialchars($wb->strip_slashes($_POST['field'.$field['field_id']])));
363 389
							}
390

  
364 391
							if($field['type'] == 'email' AND $admin->validate_email($_POST['field'.$field['field_id']]) == false) {
365 392
								$email_error = $MESSAGE['USERS_INVALID_EMAIL'];
393
								$required[]= '';
366 394
							}
367 395
							if($field['type'] == 'heading') {
368 396
								$email_body .= $_POST['field'.$field['field_id']]."\n\n";
......
375 403
								}
376 404
								$email_body .= "\n";
377 405
							}
406

  
378 407
						} elseif($field['required'] == 1) {
379 408
							$required[] = $field['title'];
380 409
						}
......
382 411
				} //  while
383 412
			}  // numRows
384 413
		} //  query
414

  
385 415
// Check if the user forgot to enter values into all the required fields
386 416
		if(sizeof($required )) {
387 417

  
......
390 420
			} else {
391 421
				echo '<h3>'.$MESSAGE['MOD_FORM_REQUIRED_FIELDS'].'</h3>';
392 422
			}
393
			echo '<ul>'.PHP_EOL;
423
			echo "<ul>\n";
394 424
			foreach($required AS $field_title) {
395
				echo '<li>'.$field_title.PHP_EOL;
425
				if($field_title!=''){
426
					echo '<li>'.$field_title."</li>\n";
427
				}
396 428
			}
429

  
397 430
			if(isset($email_error)) {
398
				echo '<li>'.$email_error.'</li>'.PHP_EOL;
431
				echo '<li>'.$email_error."</li>\n";
399 432
			}
433

  
400 434
			if(isset($captcha_error)) {
401
				echo '<li>'.$captcha_error.'</li>'.PHP_EOL;
435
				echo '<li>'.$captcha_error."</li>\n";
402 436
			}
403 437
			// Create blank "required" array
404 438
			$required = array();
405
			echo '</ul>'.PHP_EOL;
406
			echo '<p>&nbsp;</p>'.PHP_EOL.'<p><a href="'.htmlspecialchars(strip_tags($_SERVER['SCRIPT_NAME'])).'">'.$TEXT['BACK'].'</a></p>'.PHP_EOL;
439
			echo "</ul>\n";
440

  
441
			echo '<p>&nbsp;</p>'."\n".'<p><a href="'.htmlspecialchars(strip_tags($_SERVER['SCRIPT_NAME'])).'">'.$TEXT['BACK'].'</a></p>'."\n";
407 442
		} else {
408 443
			if(isset($email_error)) {
409
				echo '<br /><ul>'.PHP_EOL;
410
				echo '<li>'.$email_error.'</li>'.PHP_EOL;
411
				echo '</ul>'.PHP_EOL;
444
				echo '<br /><ul>'."\n";
445
				echo '<li>'.$email_error.'</li>'."\n";
446
				echo '</ul>'."\n";
412 447
				echo '<a href="'.htmlspecialchars(strip_tags($_SERVER['SCRIPT_NAME'])).'">'.$TEXT['BACK'].'</a>';
413 448
			} elseif(isset($captcha_error)) {
414
				echo '<br /><ul>'.PHP_EOL;
415
				echo '<li>'.$captcha_error.'</li>'.PHP_EOL;
416
				echo '</ul>'.PHP_EOL;
417
				echo '<p>&nbsp;</p>'.PHP_EOL.'<p><a href="'.htmlspecialchars(strip_tags($_SERVER['SCRIPT_NAME'])).'">'.$TEXT['BACK'].'</a></p>'.PHP_EOL;
449
				echo '<br /><ul>'."\n";
450
				echo '<li>'.$captcha_error.'</li>'."\n";
451
				echo '</ul>'."\n";
452
				echo '<p>&nbsp;</p>'."\n".'<p><a href="'.htmlspecialchars(strip_tags($_SERVER['SCRIPT_NAME'])).'">'.$TEXT['BACK'].'</a></p>'."\n";
418 453
			} else {
419 454
				// Check how many times form has been submitted in last hour
420 455
				$last_hour = time()-3600;
421 456
				$sql  = 'SELECT `submission_id` FROM `'.TABLE_PREFIX.'mod_form_submissions` ';
422 457
				$sql .= 'WHERE `submitted_when` >= '.$last_hour.'';
423 458
				$sql .= '';
424
				if($query_submissions = $database->query($sql)){
425
					if($query_submissions->numRows() > $max_submissions) {
459
				if($query_submissions = $database->query($sql))
460
				{
461
					if($query_submissions->numRows() > $max_submissions)
462
					{
426 463
						// Too many submissions so far this hour
427 464
						echo $MESSAGE['MOD_FORM_EXCESS_SUBMISSIONS'];
428 465
						$success = false;
......
436 473
						$recipient = preg_replace( "/[^a-z0-9 !?:;,.\/_\-=+@#$&\*\(\)]/im", "", $email_fromname );
437 474
						$email_fromname = preg_replace( "/(content-type:|bcc:|cc:|to:|from:)/im", "", $recipient );
438 475
						$email_body = preg_replace( "/(content-type:|bcc:|cc:|to:|from:)/im", "", $email_body );
476

  
439 477
						if($email_to != '') {
440 478
							if($email_from != '') {
441
								if($wb->mail(SERVER_EMAIL,$email_to,$email_subject,$email_body,$email_fromname)) {
442
									$success = true;
443
								}
479
								$success = $wb->mail(SERVER_EMAIL,$email_to,$email_subject,$email_body,$email_fromname,$mail_replyto);
444 480
							} else {
445
								if($wb->mail('',$email_to,$email_subject,$email_body,$email_fromname)) {
446
									$success = true;
447
								}
481
								$success = $wb->mail('',$email_to,$email_subject,$email_body,$email_fromname,$mail_replyto);
448 482
							}
449 483
						}
450 484

  
451
						$recipient = preg_replace( "/[^a-z0-9 !?:;,.\/_\-=+@#$&\*\(\)]/im", "", $success_email_fromname );
452
						$success_email_fromname = preg_replace( "/(content-type:|bcc:|cc:|to:|from:)/im", "", $recipient );
453
						$success_email_text = preg_replace( "/(content-type:|bcc:|cc:|to:|from:)/im", "", $success_email_text );
454
						if($success_email_to != '') {
455
							if($success_email_from != '') {
456
								if($wb->mail(SERVER_EMAIL,$success_email_to,$success_email_subject,($success_email_text).$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'],$success_email_fromname)) {
457
									$success = true;
485
						if($success==true)
486
						{
487
							$recipient = preg_replace( "/[^a-z0-9 !?:;,.\/_\-=+@#$&\*\(\)]/im", "", $success_email_fromname );
488
							$success_email_fromname = preg_replace( "/(content-type:|bcc:|cc:|to:|from:)/im", "", $recipient );
489
							$success_email_text = preg_replace( "/(content-type:|bcc:|cc:|to:|from:)/im", "", $success_email_text );
490
							if($success_email_to != '') {
491
								if($success_email_from != '') {
492
									$success = $wb->mail(SERVER_EMAIL,$success_email_to,$success_email_subject,($success_email_text).$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'],$success_email_fromname,$mail_replyto);
493
								} else {
494
									$success = $wb->mail('',$success_email_to,$success_email_subject,($success_email_text).$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'],$success_email_fromname,$mail_replyto);
458 495
								}
459
							} else {
460
								if($wb->mail('',$success_email_to,$success_email_subject,($success_email_text).$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'],$success_email_fromname)) {
461
									$success = true;
462
								}
463 496
							}
464 497
						}
465 498

  
466
						// Write submission to database
467
						if(isset($admin) AND $admin->is_authenticated() AND $admin->get_user_id() > 0) {
468
							$submitted_by = $admin->get_user_id();
469
						} else {
470
							$submitted_by = 0;
471
						}
472
						$email_body = htmlspecialchars($wb->add_slashes($email_body));
473
						$sql  = 'INSERT INTO '.TABLE_PREFIX.'mod_form_submissions ';
474
						$sql .= 'SET ';
475
						$sql .= 'page_id='.$wb->page_id.',';
476
						$sql .= 'section_id='.$section_id.',';
477
						$sql .= 'submitted_when='.time().',';
478
						$sql .= 'submitted_by=\''.$submitted_by.'\', ';
479
						$sql .= 'body=\''.$email_body.'\' ';
480
						if($database->query($sql)) {
481

  
482
						if(!$database->is_error()) {
483
							$success = true;
484
						}
485
						// Make sure submissions table isn't too full
486
						$query_submissions = $database->query("SELECT submission_id FROM ".TABLE_PREFIX."mod_form_submissions ORDER BY submitted_when");
487
						$num_submissions = $query_submissions->numRows();
488
						if($num_submissions > $stored_submissions) {
489
							// Remove excess submission
490
							$num_to_remove = $num_submissions-$stored_submissions;
491
							while($submission = $query_submissions->fetchRow(MYSQL_ASSOC)) {
492
								if($num_to_remove > 0) {
493
									$submission_id = $submission['submission_id'];
494
									$database->query("DELETE FROM ".TABLE_PREFIX."mod_form_submissions WHERE submission_id = '$submission_id'");
495
									$num_to_remove = $num_to_remove-1;
499
						if($success==true)
500
						{
501
							// Write submission to database
502
							if(isset($admin) AND $admin->is_authenticated() AND $admin->get_user_id() > 0) {
503
								$submitted_by = $admin->get_user_id();
504
							} else {
505
								$submitted_by = 0;
506
							}
507
							$email_body = htmlspecialchars($wb->add_slashes($email_body));
508
							$sql  = 'INSERT INTO '.TABLE_PREFIX.'mod_form_submissions ';
509
							$sql .= 'SET ';
510
							$sql .= 'page_id='.$wb->page_id.',';
511
							$sql .= 'section_id='.$section_id.',';
512
							$sql .= 'submitted_when='.time().',';
513
							$sql .= 'submitted_by=\''.$submitted_by.'\', ';
514
							$sql .= 'body=\''.$email_body.'\' ';
515
							if($database->query($sql))
516
							{
517
								if(!$database->is_error()) {
518
									$success = true;
496 519
								}
497
							}
498
						}
499
					}  // numRows
500
	 			}
501
	 			}
520
								// Make sure submissions table isn't too full
521
								$query_submissions = $database->query("SELECT submission_id FROM ".TABLE_PREFIX."mod_form_submissions ORDER BY submitted_when");
522
								$num_submissions = $query_submissions->numRows();
523
								if($num_submissions > $stored_submissions)
524
								{
525
									// Remove excess submission
526
									$num_to_remove = $num_submissions-$stored_submissions;
527
									while($submission = $query_submissions->fetchRow(MYSQL_ASSOC))
528
									{
529
										if($num_to_remove > 0)
530
										{
531
											$submission_id = $submission['submission_id'];
532
											$database->query("DELETE FROM ".TABLE_PREFIX."mod_form_submissions WHERE submission_id = '$submission_id'");
533
											$num_to_remove = $num_to_remove-1;
534
										}
535
									}
536
								} // $num_submissions
537
							}  // numRows
538
						} // $success
539
		 			}
540
	 			} // end how many times form has been submitted in last hour
502 541
			}
503 542
		}  // email_error
504 543
	} else {
......
506 545
	echo '<p>&nbsp;</p>'.PHP_EOL.'<p><a href="'.htmlspecialchars(strip_tags($_SERVER['SCRIPT_NAME'])).'">'.$TEXT['BACK'].'</a></p>'.PHP_EOL;
507 546
	}
508 547

  
548
	$success_page = ( (isset($success_page) ) ? $success_page : $page_id);
549
	$sql  = 'SELECT `link` FROM `'.TABLE_PREFIX.'pages` ';
550
	$sql .= 'WHERE `page_id` = '.(int)$success_page;
551
	$sSuccessLink = WB_URL;  // if failed set default
552
	if( ($link = $database->get_one($sql)) ) {
553
	   $sSuccessLink = WB_URL.PAGES_DIRECTORY.$link.PAGE_EXTENSION;
554
	}
509 555
	// Now check if the email was sent successfully
510
	if(isset($success) AND $success == true) {
556
	if(isset($success) && $success == true)
557
	{
511 558
	   if ($success_page=='none') {
512 559
			echo str_replace("\n","<br />",($success_email_text));
513
				echo '<p>&nbsp;</p>'.PHP_EOL.'<p><a href="'.htmlspecialchars(strip_tags($_SERVER['SCRIPT_NAME'])).'">'.$TEXT['BACK'].'</a></p>'.PHP_EOL;
560
			echo '<p>&nbsp;</p>'.PHP_EOL.'<p><a href="'.htmlspecialchars(strip_tags($_SERVER['SCRIPT_NAME'])).'">'.$TEXT['BACK'].'</a></p>'.PHP_EOL;
514 561
  		} else {
515
			$query_menu = $database->query("SELECT link,target FROM ".TABLE_PREFIX."pages WHERE `page_id` = '$success_page'");
516
			if($query_menu->numRows() > 0) {
517
  	        	$fetch_settings = $query_menu->fetchRow(MYSQL_ASSOC);
518
			   $link = WB_URL.PAGES_DIRECTORY.$fetch_settings['link'].PAGE_EXTENSION;
519
			   echo "<script type='text/javascript'>location.href='".$link."';</script>";
520
			}
562
			echo "<script type='text/javascript'>location.href='".$sSuccessLink."';</script>";
521 563
		}
522 564
		// clearing session on success
523 565
		$query_fields = $database->query("SELECT field_id FROM ".TABLE_PREFIX."mod_form_fields WHERE section_id = '$section_id'");
......
526 568
			if(isset($_SESSION['field'.$field_id])) unset($_SESSION['field'.$field_id]);
527 569
		}
528 570
	} else {
529
		if(isset($success) AND $success == false) {
530
			echo $TEXT['ERROR'];
571
		if(isset($success) && $success == false) {
572
			echo '<br />'.$MOD_FORM['ERROR'];
573
			echo '<p>&nbsp;</p>'.PHP_EOL.'<p><a href="'.htmlspecialchars(strip_tags($_SERVER['SCRIPT_NAME'])).'">'.$TEXT['BACK'].'</a></p>'.PHP_EOL;
531 574
		}
532 575
	}
533 576

  
branches/2.8.x/wb/modules/form/languages/NL.php
16 16
 */
17 17

  
18 18
// Must include code to stop this file being access directly
19
/* -------------------------------------------------------- */
20
if(defined('WB_PATH') == false)
21
{
22
	// Stop this file being access directly
23
	die('<head><title>Access denied</title></head><body><h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2></body></html>');
19
if(!defined('WB_URL')) {
20
	require_once(dirname(dirname(dirname(dirname(__FILE__)))).'/framework/globalExceptionHandler.php');
21
	throw new IllegalFileException();
24 22
}
25 23
/* -------------------------------------------------------- */
26 24

  
......
31 29
$MOD_FORM['SETTINGS'] = 'Form Settings';
32 30
$MOD_FORM['CONFIRM'] = 'Confirmation';
33 31
$MOD_FORM['SUBMIT_FORM'] = 'Submit';
34
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from '.WEBSITE_TITLE;
35
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message to '.WEBSITE_TITLE;
32
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from {{WEBSITE_TITLE}}';
33
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message by {{WEBSITE_TITLE}}';
36 34

  
37
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to '.WEBSITE_TITLE;
38
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = PHP_EOL.PHP_EOL.PHP_EOL
39
.'****************************************************************************'.PHP_EOL
40
.'This is an automatically generated e-mail. The sender\'s address of this e-mail'.PHP_EOL
41
.'is furnished only for dispatch, not to receive messages!'.PHP_EOL
42
.'If you have received this e-mail by mistake, please contact us and delete this message'.PHP_EOL
43
.'****************************************************************************'.PHP_EOL;
35
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to {{WEBSITE_TITLE}}';
36
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = "\n\n\n"
37
."****************************************************************************\n"
38
."This is an automatically generated e-mail. The sender\'s address of this e-mail\n"
39
."is furnished only for dispatch, not to receive messages!\n"
40
."If you have received this e-mail by mistake, please contact us and delete this message\n"
41
."****************************************************************************\n";
44 42

  
45 43
$MOD_FORM['FROM'] = 'Sender';
46 44
$MOD_FORM['TO'] = 'Recipient';
......
48 46
$MOD_FORM['EXCESS_SUBMISSIONS'] = 'Sorry, this form has been submitted too many times so far this hour. Please retry in the next hour.';
49 47
$MOD_FORM['INCORRECT_CAPTCHA'] = 'The verification number (also known as Captcha) that you entered is incorrect. If you are having problems reading the Captcha, please email to the <a href="mailto:{{webmaster_email}}">webmaster</a>';
50 48
$MOD_FORM['REQUIRED_FIELDS'] = 'You must enter details for the following fields';
49
$MOD_FORM['RECIPIENT'] = 'Send confirmation mail only to authenticated user! Otherwise confirmation mail will be disabled! ';
50
$MOD_FORM['ERROR'] = 'E-Mail could not send!!';
branches/2.8.x/wb/modules/form/languages/NO.php
16 16
 */
17 17

  
18 18
// Must include code to stop this file being access directly
19
/* -------------------------------------------------------- */
20
if(defined('WB_PATH') == false)
21
{
22
	// Stop this file being access directly
23
	die('<head><title>Access denied</title></head><body><h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2></body></html>');
19
if(!defined('WB_URL')) {
20
	require_once(dirname(dirname(dirname(dirname(__FILE__)))).'/framework/globalExceptionHandler.php');
21
	throw new IllegalFileException();
24 22
}
25 23
/* -------------------------------------------------------- */
26 24

  
......
31 29
$MOD_FORM['SETTINGS'] = 'Form Settings';
32 30
$MOD_FORM['CONFIRM'] = 'Confirmation';
33 31
$MOD_FORM['SUBMIT_FORM'] = 'Submit';
34
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from '.WEBSITE_TITLE;
35
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message to '.WEBSITE_TITLE;
32
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from {{WEBSITE_TITLE}}';
33
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message by {{WEBSITE_TITLE}}';
36 34

  
37
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to '.WEBSITE_TITLE;
38
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = PHP_EOL.PHP_EOL.PHP_EOL
39
.'****************************************************************************'.PHP_EOL
40
.'This is an automatically generated e-mail. The sender\'s address of this e-mail'.PHP_EOL
41
.'is furnished only for dispatch, not to receive messages!'.PHP_EOL
42
.'If you have received this e-mail by mistake, please contact us and delete this message'.PHP_EOL
43
.'****************************************************************************'.PHP_EOL;
35
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to {{WEBSITE_TITLE}}';
36
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = "\n\n\n"
37
."****************************************************************************\n"
38
."This is an automatically generated e-mail. The sender\'s address of this e-mail\n"
39
."is furnished only for dispatch, not to receive messages!\n"
40
."If you have received this e-mail by mistake, please contact us and delete this message\n"
41
."****************************************************************************\n";
44 42

  
45 43
$MOD_FORM['FROM'] = 'Sender';
46 44
$MOD_FORM['TO'] = 'Recipient';
......
48 46
$MOD_FORM['EXCESS_SUBMISSIONS'] = 'Sorry, this form has been submitted too many times so far this hour. Please retry in the next hour.';
49 47
$MOD_FORM['INCORRECT_CAPTCHA'] = 'The verification number (also known as Captcha) that you entered is incorrect. If you are having problems reading the Captcha, please email to the <a href="mailto:{{webmaster_email}}">webmaster</a>';
50 48
$MOD_FORM['REQUIRED_FIELDS'] = 'You must enter details for the following fields';
49
$MOD_FORM['RECIPIENT'] = 'Send confirmation mail only to authenticated user! Otherwise confirmation mail will be disabled! ';
50
$MOD_FORM['ERROR'] = 'E-Mail could not send!!';
branches/2.8.x/wb/modules/form/languages/EN.php
16 16
 */
17 17

  
18 18
// Must include code to stop this file being access directly
19
/* -------------------------------------------------------- */
20
if(defined('WB_PATH') == false)
21
{
22
	// Stop this file being access directly
23
	die('<head><title>Access denied</title></head><body><h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2></body></html>');
19
if(!defined('WB_URL')) {
20
	require_once(dirname(dirname(dirname(dirname(__FILE__)))).'/framework/globalExceptionHandler.php');
21
	throw new IllegalFileException();
24 22
}
25 23
/* -------------------------------------------------------- */
26 24

  
......
31 29
$MOD_FORM['SETTINGS'] = 'Form Settings';
32 30
$MOD_FORM['CONFIRM'] = 'Confirmation';
33 31
$MOD_FORM['SUBMIT_FORM'] = 'Submit';
34
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from '.WEBSITE_TITLE;
35
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message to '.WEBSITE_TITLE;
32
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from {{WEBSITE_TITLE}}';
33
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message by {{WEBSITE_TITLE}}';
36 34

  
37
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to '.WEBSITE_TITLE;
38
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = PHP_EOL.PHP_EOL.PHP_EOL
39
.'****************************************************************************'.PHP_EOL
40
.'This is an automatically generated e-mail. The sender\'s address of this e-mail'.PHP_EOL
41
.'is furnished only for dispatch, not to receive messages!'.PHP_EOL
42
.'If you have received this e-mail by mistake, please contact us and delete this message'.PHP_EOL
43
.'****************************************************************************'.PHP_EOL;
35
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to {{WEBSITE_TITLE}}';
36
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = "\n\n\n"
37
."****************************************************************************\n"
38
."This is an automatically generated e-mail. The sender\'s address of this e-mail\n"
39
."is furnished only for dispatch, not to receive messages!\n"
40
."If you have received this e-mail by mistake, please contact us and delete this message\n"
41
."****************************************************************************\n";
44 42

  
45 43
$MOD_FORM['FROM'] = 'Sender';
46 44
$MOD_FORM['TO'] = 'Recipient';
......
48 46
$MOD_FORM['EXCESS_SUBMISSIONS'] = 'Sorry, this form has been submitted too many times so far this hour. Please retry in the next hour.';
49 47
$MOD_FORM['INCORRECT_CAPTCHA'] = 'The verification number (also known as Captcha) that you entered is incorrect. If you are having problems reading the Captcha, please email to the <a href="mailto:{{webmaster_email}}">webmaster</a>';
50 48
$MOD_FORM['REQUIRED_FIELDS'] = 'You must enter details for the following fields';
49
$MOD_FORM['RECIPIENT'] = 'Send confirmation mail only to authenticated user! Otherwise confirmation mail will be disabled! ';
50
$MOD_FORM['ERROR'] = 'E-Mail could not send!!';
branches/2.8.x/wb/modules/form/languages/DA.php
16 16
 */
17 17

  
18 18
// Must include code to stop this file being access directly
19
/* -------------------------------------------------------- */
20
if(defined('WB_PATH') == false)
21
{
22
	// Stop this file being access directly
23
	die('<head><title>Access denied</title></head><body><h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2></body></html>');
19
if(!defined('WB_URL')) {
20
	require_once(dirname(dirname(dirname(dirname(__FILE__)))).'/framework/globalExceptionHandler.php');
21
	throw new IllegalFileException();
24 22
}
25 23
/* -------------------------------------------------------- */
26 24

  
......
31 29
$MOD_FORM['SETTINGS'] = 'Form Settings';
32 30
$MOD_FORM['CONFIRM'] = 'Confirmation';
33 31
$MOD_FORM['SUBMIT_FORM'] = 'Submit';
34
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from '.WEBSITE_TITLE;
35
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message to '.WEBSITE_TITLE;
32
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from {{WEBSITE_TITLE}}';
33
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message by {{WEBSITE_TITLE}}';
36 34

  
37
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to '.WEBSITE_TITLE;
38
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = PHP_EOL.PHP_EOL.PHP_EOL
39
.'****************************************************************************'.PHP_EOL
40
.'This is an automatically generated e-mail. The sender\'s address of this e-mail'.PHP_EOL
41
.'is furnished only for dispatch, not to receive messages!'.PHP_EOL
42
.'If you have received this e-mail by mistake, please contact us and delete this message'.PHP_EOL
43
.'****************************************************************************'.PHP_EOL;
35
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to {{WEBSITE_TITLE}}';
36
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = "\n\n\n"
37
."****************************************************************************\n"
38
."This is an automatically generated e-mail. The sender\'s address of this e-mail\n"
39
."is furnished only for dispatch, not to receive messages!\n"
40
."If you have received this e-mail by mistake, please contact us and delete this message\n"
41
."****************************************************************************\n";
44 42

  
45 43
$MOD_FORM['FROM'] = 'Sender';
46 44
$MOD_FORM['TO'] = 'Recipient';
......
48 46
$MOD_FORM['EXCESS_SUBMISSIONS'] = 'Sorry, this form has been submitted too many times so far this hour. Please retry in the next hour.';
49 47
$MOD_FORM['INCORRECT_CAPTCHA'] = 'The verification number (also known as Captcha) that you entered is incorrect. If you are having problems reading the Captcha, please email to the <a href="mailto:{{webmaster_email}}">webmaster</a>';
50 48
$MOD_FORM['REQUIRED_FIELDS'] = 'You must enter details for the following fields';
49
$MOD_FORM['RECIPIENT'] = 'Send confirmation mail only to authenticated user! Otherwise confirmation mail will be disabled! ';
50
$MOD_FORM['ERROR'] = 'E-Mail could not send!!';
branches/2.8.x/wb/modules/form/languages/RU.php
16 16
 */
17 17

  
18 18
// Must include code to stop this file being access directly
19
/* -------------------------------------------------------- */
20
if(defined('WB_PATH') == false)
21
{
22
	// Stop this file being access directly
23
	die('<head><title>Access denied</title></head><body><h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2></body></html>');
19
if(!defined('WB_URL')) {
20
	require_once(dirname(dirname(dirname(dirname(__FILE__)))).'/framework/globalExceptionHandler.php');
21
	throw new IllegalFileException();
24 22
}
25 23
/* -------------------------------------------------------- */
26 24

  
......
31 29
$MOD_FORM['SETTINGS'] = 'Form Settings';
32 30
$MOD_FORM['CONFIRM'] = 'Confirmation';
33 31
$MOD_FORM['SUBMIT_FORM'] = 'Submit';
34
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from '.WEBSITE_TITLE;
35
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message to '.WEBSITE_TITLE;
32
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from {{WEBSITE_TITLE}}';
33
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message by {{WEBSITE_TITLE}}';
36 34

  
37
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to '.WEBSITE_TITLE;
38
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = PHP_EOL.PHP_EOL.PHP_EOL
39
.'****************************************************************************'.PHP_EOL
40
.'This is an automatically generated e-mail. The sender\'s address of this e-mail'.PHP_EOL
41
.'is furnished only for dispatch, not to receive messages!'.PHP_EOL
42
.'If you have received this e-mail by mistake, please contact us and delete this message'.PHP_EOL
43
.'****************************************************************************'.PHP_EOL;
35
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to {{WEBSITE_TITLE}}';
36
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = "\n\n\n"
37
."****************************************************************************\n"
38
."This is an automatically generated e-mail. The sender\'s address of this e-mail\n"
39
."is furnished only for dispatch, not to receive messages!\n"
40
."If you have received this e-mail by mistake, please contact us and delete this message\n"
41
."****************************************************************************\n";
44 42

  
45 43
$MOD_FORM['FROM'] = 'Sender';
46 44
$MOD_FORM['TO'] = 'Recipient';
......
48 46
$MOD_FORM['EXCESS_SUBMISSIONS'] = 'Sorry, this form has been submitted too many times so far this hour. Please retry in the next hour.';
49 47
$MOD_FORM['INCORRECT_CAPTCHA'] = 'The verification number (also known as Captcha) that you entered is incorrect. If you are having problems reading the Captcha, please email to the <a href="mailto:{{webmaster_email}}">webmaster</a>';
50 48
$MOD_FORM['REQUIRED_FIELDS'] = 'You must enter details for the following fields';
49
$MOD_FORM['RECIPIENT'] = 'Send confirmation mail only to authenticated user! Otherwise confirmation mail will be disabled! ';
50
$MOD_FORM['ERROR'] = 'E-Mail could not send!!';
branches/2.8.x/wb/modules/form/languages/FR.php
16 16
 */
17 17

  
18 18
// Must include code to stop this file being access directly
19
/* -------------------------------------------------------- */
20
if(defined('WB_PATH') == false)
21
{
22
	// Stop this file being access directly
23
	die('<head><title>Access denied</title></head><body><h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2></body></html>');
19
if(!defined('WB_URL')) {
20
	require_once(dirname(dirname(dirname(dirname(__FILE__)))).'/framework/globalExceptionHandler.php');
21
	throw new IllegalFileException();
24 22
}
25 23
/* -------------------------------------------------------- */
26 24

  
......
31 29
$MOD_FORM['SETTINGS'] = 'Form Settings';
32 30
$MOD_FORM['CONFIRM'] = 'Confirmation';
33 31
$MOD_FORM['SUBMIT_FORM'] = 'Submit';
34
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from '.WEBSITE_TITLE;
35
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message to '.WEBSITE_TITLE;
32
$MOD_FORM['EMAIL_SUBJECT'] = 'Delivering a message from {{WEBSITE_TITLE}}';
33
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'You have submitted a message by {{WEBSITE_TITLE}}';
36 34

  
37
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to '.WEBSITE_TITLE;
38
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = PHP_EOL.PHP_EOL.PHP_EOL
39
.'****************************************************************************'.PHP_EOL
40
.'This is an automatically generated e-mail. The sender\'s address of this e-mail'.PHP_EOL
41
.'is furnished only for dispatch, not to receive messages!'.PHP_EOL
42
.'If you have received this e-mail by mistake, please contact us and delete this message'.PHP_EOL
43
.'****************************************************************************'.PHP_EOL;
35
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Thank you for sending your message to {{WEBSITE_TITLE}}';
36
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = "\n\n\n"
37
."****************************************************************************\n"
38
."This is an automatically generated e-mail. The sender\'s address of this e-mail\n"
39
."is furnished only for dispatch, not to receive messages!\n"
40
."If you have received this e-mail by mistake, please contact us and delete this message\n"
41
."****************************************************************************\n";
44 42

  
45 43
$MOD_FORM['FROM'] = 'Sender';
46 44
$MOD_FORM['TO'] = 'Recipient';
......
48 46
$MOD_FORM['EXCESS_SUBMISSIONS'] = 'Sorry, this form has been submitted too many times so far this hour. Please retry in the next hour.';
49 47
$MOD_FORM['INCORRECT_CAPTCHA'] = 'The verification number (also known as Captcha) that you entered is incorrect. If you are having problems reading the Captcha, please email to the <a href="mailto:{{webmaster_email}}">webmaster</a>';
50 48
$MOD_FORM['REQUIRED_FIELDS'] = 'You must enter details for the following fields';
49
$MOD_FORM['RECIPIENT'] = 'Send confirmation mail only to authenticated user! Otherwise confirmation mail will be disabled! ';
50
$MOD_FORM['ERROR'] = 'E-Mail could not send!!';
branches/2.8.x/wb/modules/form/languages/DE.php
15 15
 * @description
16 16
 */
17 17

  
18
// Must include code to stop this file being access directly
19
/* -------------------------------------------------------- */
20
if(defined('WB_PATH') == false)
21
{
18
// Must include code to stop this file being accessed directly
19
if(!defined('WB_URL')) {
20
	require_once(dirname(dirname(dirname(dirname(__FILE__)))).'/framework/globalExceptionHandler.php');
22 21
	// Stop this file being access directly
23
	die('<head><title>Access denied</title></head><body><h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2></body></html>');
24 22
}
25 23
/* -------------------------------------------------------- */
26 24

  
......
31 29
$MOD_FORM['SETTINGS'] = 'Formular Einstellungen';
32 30
$MOD_FORM['CONFIRM'] = 'Best&auml;tigung';
33 31
$MOD_FORM['SUBMIT_FORM'] = 'Absenden';
34
$MOD_FORM['EMAIL_SUBJECT'] = 'Erhalten einer Nachricht von '.WEBSITE_TITLE;
35
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'Sie haben ein Forumlar an '.WEBSITE_TITLE.' gesendet';
32
$MOD_FORM['EMAIL_SUBJECT'] = 'Sie haben eine Nachricht über {{WEBSITE_TITLE}} erhalten';
33
$MOD_FORM['SUCCESS_EMAIL_SUBJECT'] = 'Sie haben ein Forumlar über {{WEBSITE_TITLE}} gesendet';
36 34

  
37
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Vielen Dank f&uuml;r die &Uuml;bermittlung Ihrer Nachricht an '.WEBSITE_TITLE.'';
38
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = PHP_EOL.PHP_EOL.PHP_EOL
39
.'*************************************************************'.PHP_EOL
40
.'Dies ist eine automatisch generierte E-Mail. Die Absenderadresse dieser E-Mail'.PHP_EOL
41
.'ist nur zum Versand, und nicht zum Empfang von Nachrichten eingerichtet!'.PHP_EOL
42
.'Falls Sie diese E-Mail versehentlich erhalten haben, setzen Sie sich bitte'.PHP_EOL
43
.'mit uns in Verbindung und l&ouml;schen diese Nachricht von Ihrem Computer.'.PHP_EOL
44
.'**************************************************************'.PHP_EOL;
35
$MOD_FORM['SUCCESS_EMAIL_TEXT'] = 'Vielen Dank f&uuml;r die &Uuml;bermittlung Ihrer Nachricht an {{WEBSITE_TITLE}}';
36
$MOD_FORM['SUCCESS_EMAIL_TEXT_GENERATED'] = "\n\n\n"
37
."**************************************************************\n"
38
."Dies ist eine automatisch generierte E-Mail. Die Absenderadresse dieser E-Mail\n"
39
."ist nur zum Versand, und nicht zum Empfang von Nachrichten eingerichtet!\n"
40
."Falls Sie diese E-Mail versehentlich erhalten haben, setzen Sie sich bitte\n"
41
."mit uns in Verbindung und l&ouml;schen diese Nachricht von Ihrem Computer.\n"
42
."**************************************************************\n";
45 43

  
46 44
$MOD_FORM['FROM'] = 'Absender';
47 45
$MOD_FORM['TO'] = 'Empf&auml;nger';
......
49 47
$MOD_FORM['EXCESS_SUBMISSIONS'] = 'Dieses Formular wurde zu oft aufgerufen. Bitte versuchen Sie es in einer Stunde noch einmal.';
50 48
$MOD_FORM['INCORRECT_CAPTCHA'] = 'Die eingegebene Pr&uuml;fziffer stimmt nicht &uuml;berein. Wenn Sie Probleme mit dem Lesen der Pr&uuml;fziffer haben, bitte schreiben Sie eine E-Mail an den <a href="mailto:{{webmaster_email}}">Webmaster</a>';
51 49
$MOD_FORM['REQUIRED_FIELDS'] = 'Bitte folgende Angaben erg&auml;nzen';
50
$MOD_FORM['RECIPIENT'] = 'Emailbest&auml;tigung erfolgt nur an die g&uuml;ltige Emailadresse des jeweils angemeldeten Benutzers! Versand an ungepr&uuml;fte Adressen ist nicht möglich! ';
51
$MOD_FORM['ERROR'] = 'E-Mail konnte nicht gesendet werden!!';
branches/2.8.x/wb/modules/form/view_submission.php
21 21
// Include WB admin wrapper script
22 22
require(WB_PATH.'/modules/admin.php');
23 23
/* */
24

  
24
include_once (WB_PATH.'/framework/functions.php');
25 25
// Get id
26 26
$submission_id = intval($admin->checkIDKEY('submission_id', false, 'GET'));
27 27
if (!$submission_id) {
branches/2.8.x/wb/modules/form/modify.php
213 213
		<tr style="background-color: #dddddd; font-weight: bold;">
214 214
			<th width="23" style="text-align: center;">&nbsp;</th>
215 215
			<th width="33" style="text-align: right;"> ID </th>
216
			<th width="250" style="padding-left: 10px;"><?php echo $TEXT['SUBMITTED'] ?></th>
217
			<th width="240" style="padding-left: 10px;"><?php echo $TEXT['USER']; ?></th>
218
			<th width="250"><?php echo $TEXT['EMAIL'].' '.$MOD_FORM['FROM'] ?></th>
216
			<th width="200" style="padding-left: 10px;"><?php echo $TEXT['SUBMITTED'] ?></th>
217
			<th width="200" style="padding-left: 10px;"><?php echo $TEXT['USER']; ?></th>
218
			<th width="350"><?php echo $TEXT['EMAIL'].' '.$MOD_FORM['FROM'] ?></th>
219 219
			<th width="20">&nbsp;</th>
220 220
			<th width="20">&nbsp;</th>
221 221
			<th width="20">&nbsp;</th>
......
242 242
					</a>
243 243
				</td>
244 244
				<td width="30" style="padding-right: 5px;text-align: right;"><?php echo $submission['submission_id']; ?></td>
245
				<td width="250" style="padding-left: 10px;"><?php echo gmdate(DATE_FORMAT.', '.TIME_FORMAT, $submission['submitted_when']+TIMEZONE ); ?></td>
246
				<td width="250" style="padding-left: 10px;"><?php echo $submission['display_name']; ?></td>
247
				<td width="240"><?php echo $submission['email']; ?></td>
245
				<td width="200" style="padding-left: 10px;"><?php echo gmdate(DATE_FORMAT.', '.TIME_FORMAT, $submission['submitted_when']+TIMEZONE ); ?></td>
246
				<td width="200" style="padding-left: 10px;"><?php echo $submission['display_name']; ?></td>
247
				<td width="350"><?php echo $submission['email']; ?></td>
248 248
				<td width="20" style="text-align: center;">&nbsp;</td>
249 249
				<td width="20">&nbsp;</td>
250 250
				<td width="20" style="text-align: center;">
......
276 276
		<tr style="background-color: #dddddd; font-weight: bold;">
277 277
			<th width="23" style="text-align: center;">&nbsp;</th>
278 278
			<th width="33" style="text-align: right;"> ID </th>
279
			<th width="250" style="padding-left: 10px;"><?php echo $TEXT['SUBMITTED'] ?></th>
280
			<th width="250" style="padding-left: 10px;"><?php echo $TEXT['USER']; ?></th>
281
			<th width="250"><?php echo $TEXT['EMAIL'].' '.$MOD_FORM['FROM'] ?></th>
279
			<th width="200" style="padding-left: 10px;"><?php echo $TEXT['SUBMITTED'] ?></th>
280
			<th width="200" style="padding-left: 10px;"><?php echo $TEXT['USER']; ?></th>
281
			<th width="350"><?php echo $TEXT['EMAIL'].' '.$MOD_FORM['FROM'] ?></th>
282 282
			<th width="20">&nbsp;</th>
283 283
			<th width="20">&nbsp;</th>
284 284
			<th width="20">&nbsp;</th>
branches/2.8.x/DEVINFOS
1 1
WebsiteBaker 2.8.3 Developing Instructions/Informations
2 2
=======================================================
3 3

  
4
$Id: DEVINFOS 1634 2012-03-09 02:20:16Z Luisehahne $
4
$Id$
5 5

  
6 6

  
7
01 Apr-2012 Build 1655
8
----------------------
9
handling replyto in form module
10
You can directly answer to the recipient, sending by a authenticated user
11
then in from the recipient name is shown
7 12

  
8 13
22 Mar-2012 Build 1639
9 14
----------------------
10 15

  

Also available in: Unified diff