Welcome, Guest
Username: Password: Remember me

TOPIC: [FIXED] Required not enforced on AJAX Dropdown

Required not enforced on AJAX Dropdown 22 Dec 2015 13:22 #13751

  • MorganL
  • MorganL's Avatar
  • Offline
  • Platinum Member
  • Posts: 438
  • Thank you received: 53
  • Karma: 15
This is affecting a project I currently have exported and running. If I run the project in JCook sandbox it works fine.

I have a dropdown field which is showing the asterix for being a required field, and in the XML file the required settings are there but it is not being enforced.

What files do I need to debug to fix a required not working for AJAX Select box.

Other required fields in the form are working fine (such as a date field)
Morgan Leecy MCSE

Novell / Linux
PHP. MYSQL, Apache, node.js
Coldfusion, JQuery, HTML5
Joomla
The administrator has disabled public write access.

Required not enforced on AJAX Dropdown 04 Jan 2016 11:29 #13759

  • Romkabouter
  • Romkabouter's Avatar
  • Offline
  • Elite Member
  • Posts: 310
  • Thank you received: 131
  • Karma: 48
Hi,

Maybe related to my problem: www.j-cook.pro/index.php/forum/19-new-ti...elect-not-validating

The problem might not be the AJAX, but the dropdown. It uses Jquery chosen.
In the end I post a piece of code to fix it in a specific form, but you can fork the headerdeclaration to fix it for all forms.

There is a little error in the code, the correct code is:
(function($){
	$(document).ready(function () {
		$("#adminForm").validationEngine('attach',{prettySelect:true,useSuffix:"_chzn"});
	});
})(jQuery)
The administrator has disabled public write access.

Required not enforced on AJAX Dropdown 09 May 2016 10:48 #13935

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 987
  • Karma: 140
This ticket has been fixed and can be closed now.
The new trick also works with AJAX.

Can you confirm me that Morgan ?
Coding is now a piece of cake
The administrator has disabled public write access.
Time to create page: 0.069 seconds

Get Started