Radicore Forum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » RADICORE » How To » Custom Validation Executed - Blank Screen Displays
Custom Validation Executed - Blank Screen Displays [message #678] Wed, 14 March 2007 02:17 Go to next message
douglas is currently offline  douglas
Messages: 9
Registered: August 2006
Location: Kerala
Junior Member

I have created a class for custom validation and executes properly. The thing is, I am getting only a blank screen after the update. I have to be login again for continue. The record is updated after proper validation. The class i created if as follows. I have updated the concerned column in the data dictionary as
SubType=CUSTOM
custom validation = douglas.validation.class.inc/douglas_validation_class/source _id

The class is as follows

<?php
class douglas_validation_class
{
function source_id (&$input, $fieldspec)
{
$input = strtoupper($input);

if (!empty($input)) {
$pattern = "^[A-Z]{1,2}$";
if (!ereg($pattern, $input)) {
return getLanguageText('validation001');
}
}
return;

} // source_id
} // end class

Kindly inform me what has happened wrongly.
Thanking u sir,
Douglas
?>


Douglas
Re: Custom Validation Executed - Blank Screen Displays [message #679 is a reply to message #678] Wed, 14 March 2007 04:57 Go to previous message
AJM is currently offline  AJM
Messages: 2371
Registered: April 2006
Location: Surrey, UK
Senior Member
If you are using a version of Radicore which is greater than 1.20.0 (as you should be) then there is no need to set SUBTYPE=CUSTOM. This is documented in http://www.tonymarston.net/php-mysql/custom-validation.html

The sample code provided in the Radicore download works OK, so the problem must be somewhere else in your code.

It is not possible to tell what is happening from your description. You will need to step through with your debugger to see where the glitch occurs.


Previous Topic: How do I use a GLOBALS or _SESSION field selection
Next Topic: Regenerate <table_name>.screen.inc files
Goto Forum:
  


Current Time: Wed Nov 27 05:53:52 EST 2024

Total time taken to generate the page: 0.00899 seconds