From 0b00723a678df01df6ec1d614675843e3bbb296e Mon Sep 17 00:00:00 2001 From: Sashi20 Date: Fri, 4 Jan 2019 12:44:05 +0530 Subject: Modified the character limit for project description in proposal form --- proposal.inc | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/proposal.inc b/proposal.inc index 3021700..a20e961 100755 --- a/proposal.inc +++ b/proposal.inc @@ -75,7 +75,8 @@ function om_pssp_proposal_form($form, &$form_state, $no_js_use = FALSE) 'placeholder' => t('Enter your full name.....') ), '#maxlength' => 250, - '#required' => TRUE + '#required' => TRUE, + '#description' => t('Kindly enter the names in the following format: Name1, Name2 and Name3'), ); $form['contributor_contact_no'] = array( '#type' => 'textfield', @@ -259,8 +260,8 @@ function om_pssp_proposal_form($form, &$form_state, $no_js_use = FALSE) $form['description'] = array( '#type' => 'textarea', '#title' => t('Description of Proposed Simulation'), - '#size' => 120, - '#description' => t('Maximum character limit is 120, minimum 60'), + '#size' => 250, + '#description' => t('Maximum character limit is 250, minimum 60'), '#required' => TRUE ); $form['reference'] = array( @@ -321,6 +322,9 @@ function om_pssp_proposal_form($form, &$form_state, $no_js_use = FALSE) function om_pssp_proposal_form_validate($form, &$form_state) { $project_title = $form_state['values']['project_title']; + /*$proposar_name = $form_state['values']['name_title'] . ' ' . $form_state['values']['contributor_name']; + $directory_name = _df_dir_name($project_title, $proposar_name);*/ + //var_dump($directory_name);die; $query = db_select('om_pssp_proposal'); $query->fields('om_pssp_proposal'); $query->condition('project_title', $project_title); @@ -405,9 +409,9 @@ function om_pssp_proposal_form_validate($form, &$form_state) $form_state['values']['description'] = trim($form_state['values']['description']); if ($form_state['values']['description'] != '') { - if (strlen($form_state['values']['description']) > 120) + if (strlen($form_state['values']['description']) > 250) { - form_set_error('description', t('Maximum charater limit is 120 charaters only, please check the length of the description')); + form_set_error('description', t('Maximum charater limit is 250 charaters only, please check the length of the description')); } //strlen($form_state['values']['project_title']) > 250 else if (strlen($form_state['values']['description']) < 60) { -- cgit