[ic] Strip spaces from email

Mike Heins mike at perusion.com
Wed Apr 14 10:38:28 EDT 2004


Quoting Ethan E. Rowe (ethan at the-rowes.com):
> Susan Misnick wrote:
> 
> >Hi, I'd like to strip leading or trailing spaces from the email field, 
> >which seems very straightforward, but I can't figure out where to put 
> >the code.  Hints?
> >Thanks,
> >Susan
> 
> It depends on what action is being performed; if this is in relation to 
> posting an order to the database, one thing would be to put it in 
> /etc/log_transaction.  However, if you want to do something in a less 
> sensitive area, you could put a little [perl]...[/perl] block in the 
> form profile with a regular expression to trim the leading spaces.  I'm 
> still on the steep part of the Interchange learning curve myself, 
> however, so it's highly possible somebody could offer you a more elegant 
> solution.

It's as easy as:

	[value name=email filter=strip]

-- 
Mike Heins
Perusion -- Expert Interchange Consulting    http://www.perusion.com/
phone +1.765.647.1295  tollfree 800-949-1889 <mike at perusion.com>

For a successful technology, reality must take precedence over public
relations, for Nature cannot be fooled. -- Dick Feynman


More information about the interchange-users mailing list