<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://wiki.eprints.org/w/index.php?action=history&amp;feed=atom&amp;title=User_validate.pl</id>
	<title>User validate.pl - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.eprints.org/w/index.php?action=history&amp;feed=atom&amp;title=User_validate.pl"/>
	<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=User_validate.pl&amp;action=history"/>
	<updated>2026-06-10T02:41:23Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.31.8</generator>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=User_validate.pl&amp;diff=14436&amp;oldid=prev</id>
		<title>Drn@ecs.soton.ac.uk: Added page about config file</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=User_validate.pl&amp;diff=14436&amp;oldid=prev"/>
		<updated>2022-01-31T09:08:03Z</updated>

		<summary type="html">&lt;p&gt;Added page about config file&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{dirs}}&lt;br /&gt;
{{cfgd}}&lt;br /&gt;
&lt;br /&gt;
'''user_validate.pl''' contains configuration for validating User data objects.&lt;br /&gt;
&lt;br /&gt;
The '''validate_user''' function tests the validity of the values set for the metadata fields for a User.  This usually happens when a user submits the form (e.g. clicks on ''Previous'', ''Save and Return'' or ''Next'') on the ''Upload'' stage.&lt;br /&gt;
&lt;br /&gt;
* '''&amp;lt;tt&amp;gt;$user&amp;lt;/tt&amp;gt;''' is the [[API:EPrints/DataObj/User|User]] object being validated.&lt;br /&gt;
* '''&amp;lt;tt&amp;gt;$repository&amp;lt;/tt&amp;gt;''' is a [[API:EPrints/Repository|Repository]] object.&lt;br /&gt;
* '''&amp;lt;tt&amp;gt;$for_archive&amp;lt;/tt&amp;gt;''' is a boolean indicating whether the current validation is a precursor to the item being moved to the live archive.  Its value make no difference for the default '''validate_user''' function.&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
In this example, there are no specific validation checks, which is the default but the ''# CHECKS IN HERE'' is where any validation checks should be inserted.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$c-&amp;gt;{validate_user} = sub&lt;br /&gt;
{&lt;br /&gt;
    my( $user, $repository, $for_archive ) = @_;&lt;br /&gt;
 &lt;br /&gt;
    my @problems = ();&lt;br /&gt;
 &lt;br /&gt;
    # CHECKS IN HERE&lt;br /&gt;
 &lt;br /&gt;
    return( @problems );&lt;br /&gt;
};&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Drn@ecs.soton.ac.uk</name></author>
		
	</entry>
</feed>