Replacing datepickerdate with date_picker element

1.9.x
Julio Montoya 11 years ago
parent e0584540e3
commit fa112d7888
  1. 56
      main/attendance/attendance_calendar.php
  2. 25
      main/attendance/attendance_controller.php
  3. 9
      main/attendance/attendance_edit.php
  4. 4
      main/inc/lib/formvalidator/Element/DateRangePicker.php
  5. 39
      main/inc/lib/formvalidator/Rule/Date.php
  6. 41
      main/inc/lib/formvalidator/Rule/DateCompare.php
  7. 8
      main/inc/lib/usermanager.lib.php
  8. 4
      main/survey/create_new_survey.php
  9. 5
      main/survey/survey.lib.php

@ -15,12 +15,12 @@ if (isset($_SESSION['gradebook'])) {
$param_gradebook = '&gradebook='.Security::remove_XSS($_SESSION['gradebook']); $param_gradebook = '&gradebook='.Security::remove_XSS($_SESSION['gradebook']);
} }
if (!$is_locked_attendance || api_is_platform_admin()) { if (!$is_locked_attendance || api_is_platform_admin()) {
echo '<div class="actions">'; echo '<div class="actions">';
if ($action == 'calendar_add') { if ($action == 'calendar_add') {
echo '<a href="index.php?'.api_get_cidreq().'&action=calendar_list&attendance_id='.$attendance_id.$param_gradebook.'">'.Display::return_icon('back.png',get_lang('AttendanceCalendar'),'',ICON_SIZE_MEDIUM).'</a>'; echo '<a href="index.php?'.api_get_cidreq().'&action=calendar_list&attendance_id='.$attendance_id.$param_gradebook.'">'.Display::return_icon('back.png',get_lang('AttendanceCalendar'),'',ICON_SIZE_MEDIUM).'</a>';
} else { } else {
echo '<a href="index.php?'.api_get_cidreq().'&action=attendance_sheet_list&attendance_id='.$attendance_id.$param_gradebook.'">'.Display::return_icon('back.png',get_lang('AttendanceSheet'),'',ICON_SIZE_MEDIUM).'</a>'; echo '<a href="index.php?'.api_get_cidreq().'&action=attendance_sheet_list&attendance_id='.$attendance_id.$param_gradebook.'">'.Display::return_icon('back.png',get_lang('AttendanceSheet'),'',ICON_SIZE_MEDIUM).'</a>';
echo '<a href="index.php?'.api_get_cidreq().'&action=calendar_add&attendance_id='.$attendance_id.$param_gradebook.'">'.Display::return_icon('add.png',get_lang('AddDateAndTime'),'',ICON_SIZE_MEDIUM).'</a>'; echo '<a href="index.php?'.api_get_cidreq().'&action=calendar_add&attendance_id='.$attendance_id.$param_gradebook.'">'.Display::return_icon('add.png',get_lang('AddDateAndTime'),'',ICON_SIZE_MEDIUM).'</a>';
echo '<a onclick="javascript:if(!confirm(\''.get_lang('AreYouSureToDeleteAllDates').'\')) return false;" href="index.php?'.api_get_cidreq().'&action=calendar_all_delete&attendance_id='.$attendance_id.$param_gradebook.'">'.Display::return_icon('clean.png',get_lang('CleanCalendar'),'',ICON_SIZE_MEDIUM).'</a>'; echo '<a onclick="javascript:if(!confirm(\''.get_lang('AreYouSureToDeleteAllDates').'\')) return false;" href="index.php?'.api_get_cidreq().'&action=calendar_all_delete&attendance_id='.$attendance_id.$param_gradebook.'">'.Display::return_icon('clean.png',get_lang('CleanCalendar'),'',ICON_SIZE_MEDIUM).'</a>';
} }
@ -47,14 +47,21 @@ if ($error_checkdate) {
} }
if (isset($action) && $action == 'calendar_add') { if (isset($action) && $action == 'calendar_add') {
// calendar add form // calendar add form
$form = new FormValidator('attendance_calendar_add','POST','index.php?action=calendar_add&attendance_id='.$attendance_id.$param_gradebook.'&'.api_get_cidreq(),''); $form = new FormValidator('attendance_calendar_add','POST','index.php?action=calendar_add&attendance_id='.$attendance_id.$param_gradebook.'&'.api_get_cidreq(),'');
$form->addElement('header', get_lang('AddADateTime')); $form->addElement('header', get_lang('AddADateTime'));
$form->addElement('datepicker', 'date_time', '', array('form_name'=>'attendance_calendar_add'), 5); $form->addElement('date_time_picker', 'date_time');
$defaults['date_time'] = date('Y-m-d H:i', api_strtotime(api_get_local_time())); $defaults['date_time'] = date('Y-m-d H:i', api_strtotime(api_get_local_time()));
$form->addElement('checkbox', 'repeat', null, get_lang('RepeatDate'), array('onclick' => "javascript: if(this.checked){document.getElementById('repeat-date-attendance').style.display='block';}else{document.getElementById('repeat-date-attendance').style.display='none';}", $form->addElement(
)); 'checkbox',
'repeat',
null,
get_lang('RepeatDate'),
array(
'onclick' => "javascript: if(this.checked){document.getElementById('repeat-date-attendance').style.display='block';}else{document.getElementById('repeat-date-attendance').style.display='none';}",
)
);
$defaults['repeat'] = $repeat; $defaults['repeat'] = $repeat;
@ -62,36 +69,41 @@ if (isset($action) && $action == 'calendar_add') {
$form->addElement('html', '<div id="repeat-date-attendance" style="display:block">'); $form->addElement('html', '<div id="repeat-date-attendance" style="display:block">');
} else { } else {
$form->addElement('html', '<div id="repeat-date-attendance" style="display:none">'); $form->addElement('html', '<div id="repeat-date-attendance" style="display:none">');
} }
$a_repeat_type = array('daily'=>get_lang('RepeatDaily'), 'weekly'=>get_lang('RepeatWeekly'), 'monthlyByDate'=>get_lang('RepeatMonthlyByDate')); $a_repeat_type = array(
'daily' => get_lang('RepeatDaily'),
'weekly' => get_lang('RepeatWeekly'),
'monthlyByDate' => get_lang('RepeatMonthlyByDate')
);
$form->addElement('select', 'repeat_type', get_lang('RepeatType') , $a_repeat_type); $form->addElement('select', 'repeat_type', get_lang('RepeatType') , $a_repeat_type);
$form->addElement('datepickerdate', 'end_date_time', get_lang('RepeatEnd'), array('form_name'=>'attendance_calendar_add'));
$defaults['end_date_time'] = date('Y-m-d 12:00:00'); $form->addElement('date_picker', 'end_date_time', get_lang('RepeatEnd'), array('form_name'=>'attendance_calendar_add'));
$defaults['end_date_time'] = date('Y-m-d');
$form->addElement('html', '</div>'); $form->addElement('html', '</div>');
$defaults['repeat_type'] = 'weekly'; $defaults['repeat_type'] = 'weekly';
$form->addElement('style_submit_button', null, get_lang('Save'), 'class="save"'); $form->addElement('style_submit_button', null, get_lang('Save'), 'class="save"');
$form->setDefaults($defaults); $form->setDefaults($defaults);
$form->display(); $form->display();
} else { } else {
// calendar list // calendar list
echo Display::page_subheader(get_lang('CalendarList')); echo Display::page_subheader(get_lang('CalendarList'));
echo '<div class="attendance-calendar-list">'; echo '<div class="attendance-calendar-list">';
if (!empty($attendance_calendar)) { if (!empty($attendance_calendar)) {
foreach ($attendance_calendar as $calendar) { foreach ($attendance_calendar as $calendar) {
echo '<div class="attendance-calendar-row">'; echo '<div class="attendance-calendar-row">';
if ((isset($action) && $action == 'calendar_edit') && (isset($calendar_id) && $calendar_id == $calendar['id'])) { if ((isset($action) && $action == 'calendar_edit') && (isset($calendar_id) && $calendar_id == $calendar['id'])) {
// calendar edit form // calendar edit form
echo '<div class="attendance-calendar-edit">'; echo '<div class="attendance-calendar-edit">';
$form = new FormValidator('attendance_calendar_edit','POST','index.php?action=calendar_edit&attendance_id='.$attendance_id.'&calendar_id='.$calendar_id.'&'.api_get_cidreq().$param_gradebook,''); $form = new FormValidator('attendance_calendar_edit','POST','index.php?action=calendar_edit&attendance_id='.$attendance_id.'&calendar_id='.$calendar_id.'&'.api_get_cidreq().$param_gradebook,'');
$form->addElement('datepicker', 'date_time', '', array('form_name'=>'attendance_calendar_edit'), 5); $form->addElement('date_time_picker', 'date_time', '', array('form_name'=>'attendance_calendar_edit'), 5);
$defaults['date_time'] = $calendar['date_time']; $defaults['date_time'] = $calendar['date_time'];
$form->addElement('style_submit_button', null, get_lang('Save'), 'class="save"'); $form->addElement('style_submit_button', null, get_lang('Save'), 'class="save"');
$form->addElement('style_submit_button', 'cancel', get_lang('Cancel'), 'class="cancel"'); $form->addElement('style_submit_button', 'cancel', get_lang('Cancel'), 'class="cancel"');
$form->setDefaults($defaults); $form->setDefaults($defaults);
$form->display(); $form->display();
echo '</div>'; echo '</div>';
} else { } else {
echo Display::return_icon('lp_calendar_event.png', get_lang('DateTime')).' '.substr($calendar['date_time'], 0, strlen($calendar['date_time'])- 3) .'&nbsp;'; echo Display::return_icon('lp_calendar_event.png', get_lang('DateTime')).' '.substr($calendar['date_time'], 0, strlen($calendar['date_time'])- 3) .'&nbsp;';
if (!$is_locked_attendance || api_is_platform_admin()) { if (!$is_locked_attendance || api_is_platform_admin()) {
@ -100,11 +112,11 @@ if (isset($action) && $action == 'calendar_add') {
echo '<a onclick="javascript:if(!confirm(\''.get_lang('AreYouSureToDelete').'\')) return false;" href="index.php?'.api_get_cidreq().$param_gradebook.'&action=calendar_delete&calendar_id='.intval($calendar['id']).'&attendance_id='.$attendance_id.'">'.Display::return_icon('delete.png', get_lang('Delete'), array('style'=>'vertical-align:middle'), ICON_SIZE_SMALL).'</a>'; echo '<a onclick="javascript:if(!confirm(\''.get_lang('AreYouSureToDelete').'\')) return false;" href="index.php?'.api_get_cidreq().$param_gradebook.'&action=calendar_delete&calendar_id='.intval($calendar['id']).'&attendance_id='.$attendance_id.'">'.Display::return_icon('delete.png', get_lang('Delete'), array('style'=>'vertical-align:middle'), ICON_SIZE_SMALL).'</a>';
echo '</span>'; echo '</span>';
} }
} }
echo '</div>'; echo '</div>';
} }
} else { } else {
echo Display::return_message(get_lang('ThereAreNoRegisteredDatetimeYet'), 'warning'); echo Display::return_message(get_lang('ThereAreNoRegisteredDatetimeYet'), 'warning');
} }
echo '</div>'; echo '</div>';
} }

@ -316,20 +316,21 @@
if (!isset($_POST['cancel'])) { if (!isset($_POST['cancel'])) {
if (isset($_POST['repeat'])) { if (isset($_POST['repeat'])) {
//@todo check this error_logs //@todo check this error_logs
$start_datetime = api_strtotime(api_get_utc_datetime($attendance->build_datetime_from_array($_POST['date_time'])),'UTC'); $start_datetime = api_strtotime(
//error_log('$start_datetime '.$start_datetime); api_get_utc_datetime($_POST['date_time']), 'UTC'
);
$_POST['end_date_time']['H'] = $_POST['date_time']['H']; $end_datetime = api_strtotime(api_get_utc_datetime($_POST['end_date_time'].' 23:59:59'), 'UTC');
$_POST['end_date_time']['i'] = $_POST['date_time']['i']; $checkdate = api_is_valid_date(api_get_utc_datetime($_POST['end_date_time'].' 23:59:59'));
//error_log($attendance->build_datetime_from_array($_POST['end_date_time']));
$end_datetime = api_strtotime(api_get_utc_datetime($attendance->build_datetime_from_array($_POST['end_date_time'])),'UTC');
//error_log('$end_datetime '.$end_datetime);
$checkdate = checkdate($_POST['end_date_time']['F'], $_POST['end_date_time']['d'], $_POST['end_date_time']['Y']);
$repeat_type = $_POST['repeat_type']; $repeat_type = $_POST['repeat_type'];
if (($end_datetime > $start_datetime) && $checkdate) { if (($end_datetime > $start_datetime) && $checkdate) {
$affected_rows = $attendance->attendance_repeat_calendar_add($attendance_id, $start_datetime, $end_datetime, $repeat_type); $affected_rows = $attendance->attendance_repeat_calendar_add(
$attendance_id,
$start_datetime,
$end_datetime,
$repeat_type
);
$action = 'calendar_list'; $action = 'calendar_list';
} else { } else {
if (!$checkdate) { if (!$checkdate) {
@ -341,7 +342,7 @@
$action = 'calendar_add'; $action = 'calendar_add';
} }
} else { } else {
$datetime = $attendance->build_datetime_from_array($_POST['date_time']); $datetime = $_POST['date_time'];
$datetimezone = api_get_utc_datetime($datetime); $datetimezone = api_get_utc_datetime($datetime);
if (!empty($datetime)) { if (!empty($datetime)) {
$attendance->set_date_time($datetimezone); $attendance->set_date_time($datetimezone);
@ -545,4 +546,4 @@
Export::export_html_to_pdf($content, $params); Export::export_html_to_pdf($content, $params);
exit; exit;
} }
} }

@ -7,7 +7,6 @@
* @package chamilo.attendance * @package chamilo.attendance
*/ */
// protect a course script // protect a course script
api_protect_course_script(true); api_protect_course_script(true);
@ -41,15 +40,15 @@ $form->add_html_editor('description', get_lang('Description'), false, false, arr
if (Gradebook::is_active()) { if (Gradebook::is_active()) {
if (!empty($attendance_qualify_title) || !empty($attendance_weight)) { if (!empty($attendance_qualify_title) || !empty($attendance_weight)) {
$advanced = '<a href="javascript://" class="advanced_parameters"><span id="img_plus_and_minus">&nbsp;'.Display::return_icon('div_hide.gif',get_lang('Show'),array('style'=>'vertical-align:middle')).' '.get_lang('AdvancedParameters').'</span></a>'; $advanced = '<a href="javascript://" class="advanced_parameters"><span id="img_plus_and_minus">&nbsp;'.Display::return_icon('div_hide.gif',get_lang('Show'),array('style'=>'vertical-align:middle')).' '.get_lang('AdvancedParameters').'</span></a>';
$form->addElement('advanced_settings',$advanced); $form->addElement('advanced_settings',$advanced);
$form->addElement('html','<div id="id_qualify" style="display:block">'); $form->addElement('html','<div id="id_qualify" style="display:block">');
$form->addElement('checkbox', 'attendance_qualify_gradebook', '', get_lang('QualifyAttendanceGradebook'),array('checked'=>'true','onclick'=>'javascript: if(this.checked){document.getElementById(\'options_field\').style.display = \'block\';}else{document.getElementById(\'options_field\').style.display = \'none\';}')); $form->addElement('checkbox', 'attendance_qualify_gradebook', '', get_lang('QualifyAttendanceGradebook'),array('checked'=>'true','onclick'=>'javascript: if(this.checked){document.getElementById(\'options_field\').style.display = \'block\';}else{document.getElementById(\'options_field\').style.display = \'none\';}'));
$form->addElement('html','<div id="options_field" style="display:block">'); $form->addElement('html','<div id="options_field" style="display:block">');
} else { } else {
$advanced = '<a href="javascript://" class="advanced_parameters"><span id="img_plus_and_minus">&nbsp;'.Display::return_icon('div_show.gif',get_lang('Show'),array('style'=>'vertical-align:middle')).' '.get_lang('AdvancedParameters').'</span></a>'; $advanced = '<a href="javascript://" class="advanced_parameters"><span id="img_plus_and_minus">&nbsp;'.Display::return_icon('div_show.gif',get_lang('Show'),array('style'=>'vertical-align:middle')).' '.get_lang('AdvancedParameters').'</span></a>';
$form->addElement('advanced_settings',$advanced); $form->addElement('advanced_settings',$advanced);
$form->addElement('html','<div id="id_qualify" style="display:none">'); $form->addElement('html','<div id="id_qualify" style="display:none">');
$form->addElement('checkbox', 'attendance_qualify_gradebook', '', get_lang('QualifyAttendanceGradebook'),'onclick="javascript: if(this.checked){document.getElementById(\'options_field\').style.display = \'block\';}else{document.getElementById(\'options_field\').style.display = \'none\';}"'); $form->addElement('checkbox', 'attendance_qualify_gradebook', '', get_lang('QualifyAttendanceGradebook'),'onclick="javascript: if(this.checked){document.getElementById(\'options_field\').style.display = \'block\';}else{document.getElementById(\'options_field\').style.display = \'none\';}"');
$form->addElement('html','<div id="options_field" style="display:none">'); $form->addElement('html','<div id="options_field" style="display:none">');
} }

@ -98,7 +98,6 @@ class DateRangePicker extends HTML_QuickForm_text
*/ */
function validateDates($dates) function validateDates($dates)
{ {
if (empty($dates['start']) || empty($dates['end'])) { if (empty($dates['start']) || empty($dates['end'])) {
return false; return false;
} }
@ -115,7 +114,4 @@ class DateRangePicker extends HTML_QuickForm_text
return true; return true;
} }
} }

@ -1,40 +1,23 @@
<?php <?php
// $Id: Date.php 6187 2005-09-07 10:23:57Z bmol $ /* For licensing terms, see /license.txt */
/* /** @author Bart Mollet, Julio Montoya */
============================================================================== require_once 'HTML/QuickForm/Rule.php';
Dokeos - elearning and course management software
Copyright (c) 2004-2005 Dokeos S.A.
Copyright (c) Bart Mollet, Hogeschool Gent
For a full list of contributors, see "credits.txt".
The full license can be read in "license.txt".
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
See the GNU General Public License for more details.
Contact address: Dokeos, 44 rue des palais, B-1030 Brussels, Belgium
Mail: info@dokeos.com
==============================================================================
*/
require_once ('HTML/QuickForm/Rule.php');
/** /**
* QuickForm rule to check a date * Class HTML_QuickForm_Rule_Date
*/ */
class HTML_QuickForm_Rule_Date extends HTML_QuickForm_Rule class HTML_QuickForm_Rule_Date extends HTML_QuickForm_Rule
{ {
/** /**
* Function to check a date * Check a date
* @see HTML_QuickForm_Rule * @see HTML_QuickForm_Rule
* @param array $date An array with keys F (month), d (day) and Y (year) * @param string $date example 2014-04-30
* @param array $options
*
* @return boolean True if date is valid * @return boolean True if date is valid
*/ */
function validate($date, $options) public function validate($date, $options)
{ {
return checkdate($date['F'], $date['d'], $date['Y']); return api_is_valid_date($date, 'Y-m-d');
} }
} }

@ -1,46 +1,21 @@
<?php <?php
// $Id: DateCompare.php 6187 2005-09-07 10:23:57Z bmol $ /* For licensing terms, see /license.txt */
/* /** @author Bart Mollet, Julio Montoya */
==============================================================================
Dokeos - elearning and course management software
Copyright (c) 2004-2005 Dokeos S.A.
Copyright (c) Bart Mollet, Hogeschool Gent
For a full list of contributors, see "credits.txt".
The full license can be read in "license.txt".
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
See the GNU General Public License for more details.
Contact address: Dokeos, 44 rue des palais, B-1030 Brussels, Belgium
Mail: info@dokeos.com
==============================================================================
*/
require_once 'HTML/QuickForm/Rule/Compare.php'; require_once 'HTML/QuickForm/Rule/Compare.php';
/** /**
* QuickForm rule to compare 2 dates * Class HTML_QuickForm_Rule_DateCompare
*/ */
class HTML_QuickForm_Rule_DateCompare extends HTML_QuickForm_Rule_Compare class HTML_QuickForm_Rule_DateCompare extends HTML_QuickForm_Rule_Compare
{ {
/** /**
* Validate 2 dates * Validate 2 dates
* @param array $values Array with the 2 dates. Each element in this array * @param array $values Array with the 2 dates.
* should be an array width keys F (month), d (day) and Y (year) * @param $operator
* @param string $operator The operator to use (default '==') *
* @return boolean True if the 2 given dates match the operator * @return boolean true if the 2 given dates match the operator
*/ */
function validate($values, $operator = null) function validate($values, $operator = null)
{ {
$date1 = $values[0]; return api_strtotime($values[0]) < api_strtotime($values[1]);
$date2 = $values[1];
$time1 = mktime($date1['H'],$date1['i'],0,$date1['F'],$date1['d'],$date1['Y']);
$time2 = mktime($date2['H'],$date2['i'],0,$date2['F'],$date2['d'],$date2['Y']);
return parent::validate(array($time1,$time2),$operator);
} }
} }
?>

@ -4205,8 +4205,8 @@ class UserManager
} }
break; break;
case self::USER_FIELD_TYPE_DATE: case self::USER_FIELD_TYPE_DATE:
$form->addElement('datepickerdate', 'extra_'.$field_details[1], $field_details[3], array('form_name' => $form_name)); $form->addElement('date_picker', 'extra_'.$field_details[1], $field_details[3]);
$form->_elements[$form->_elementIndex['extra_'.$field_details[1]]]->setLocalOption('minYear', 1900); //$form->_elements[$form->_elementIndex['extra_'.$field_details[1]]]->setLocalOption('minYear', 1900);
$defaults['extra_'.$field_details[1]] = date('Y-m-d 12:00:00'); $defaults['extra_'.$field_details[1]] = date('Y-m-d 12:00:00');
$form->setDefaults($defaults); $form->setDefaults($defaults);
if (!$admin_permissions) { if (!$admin_permissions) {
@ -4216,8 +4216,8 @@ class UserManager
$form->applyFilter('theme', 'trim'); $form->applyFilter('theme', 'trim');
break; break;
case self::USER_FIELD_TYPE_DATETIME: case self::USER_FIELD_TYPE_DATETIME:
$form->addElement('datepicker', 'extra_'.$field_details[1], $field_details[3], array('form_name' => $form_name)); $form->addElement('date_time_picker', 'extra_'.$field_details[1], $field_details[3]);
$form->_elements[$form->_elementIndex['extra_'.$field_details[1]]]->setLocalOption('minYear', 1900); //$form->_elements[$form->_elementIndex['extra_'.$field_details[1]]]->setLocalOption('minYear', 1900);
$defaults['extra_'.$field_details[1]] = date('Y-m-d 12:00:00'); $defaults['extra_'.$field_details[1]] = date('Y-m-d 12:00:00');
$form->setDefaults($defaults); $form->setDefaults($defaults);
if (!$admin_permissions) { if (!$admin_permissions) {

@ -151,8 +151,8 @@ $form->addElement('html_editor', 'survey_subtitle', get_lang('SurveySubTitle'),
// Pass the language of the survey in the form // Pass the language of the survey in the form
$form->addElement('hidden', 'survey_language'); $form->addElement('hidden', 'survey_language');
$form->addElement('datepickerdate', 'start_date', get_lang('StartDate'), array('form_name' => 'survey')); $form->addElement('date_picker', 'start_date', get_lang('StartDate'));
$form->addElement('datepickerdate', 'end_date', get_lang('EndDate'), array('form_name' => 'survey')); $form->addElement('date_picker', 'end_date', get_lang('EndDate'));
//$group = ''; //$group = '';
//$group[] =& HTML_QuickForm::createElement('radio', 'survey_share', null, get_lang('Yes'), $form_share_value); //$group[] =& HTML_QuickForm::createElement('radio', 'survey_share', null, get_lang('Yes'), $form_share_value);

@ -155,13 +155,10 @@ class survey_manager
public static function store_survey($values) public static function store_survey($values)
{ {
$_user = api_get_user_info(); $_user = api_get_user_info();
$course_id = api_get_course_int_id();
// Table defnitions
$table_survey = Database :: get_course_table(TABLE_SURVEY); $table_survey = Database :: get_course_table(TABLE_SURVEY);
$shared_survey_id = 0; $shared_survey_id = 0;
$course_id = api_get_course_int_id();
if (!$values['survey_id'] || !is_numeric($values['survey_id'])) { if (!$values['survey_id'] || !is_numeric($values['survey_id'])) {
// Check if the code doesn't soon exists in this language // Check if the code doesn't soon exists in this language
$sql = 'SELECT 1 FROM '.$table_survey.' $sql = 'SELECT 1 FROM '.$table_survey.'

Loading…
Cancel
Save