Gossamer Forum
Home : Products : Gossamer Links : Version 1.x :

Stupid Question- EASY ANSWER!

Quote Reply
Stupid Question- EASY ANSWER!
Hi:

I erased the validation rule for the URL field... would someone be kind enough to post the validation rule (from Edit Table Definition in Table Maintenence) for this field?

Thanks!

Dave
Quote Reply
Re: Stupid Question- EASY ANSWER! In reply to
Dave,

Odd, none of the copies of my defs have a validation rule for the URL field. I make a point of making an original copy upon install and no copies contain a validation rule for the URL.

I do have one from Links 2.0 from when I was testing out which version to use.

This is the default value and the validation rule from Links 2.0:

'http://', '^http|news|mailto|ftp'

Hope that helps.


Peace.

Kyle
Quote Reply
Re: Stupid Question- EASY ANSWER! In reply to
Kyle:

Maybe that is the answer.... there is no validation rule! And I thought I was going crazy. I must have remembered the validation rule from 2.0.

I will give that a shot, and it should work (right?) Thanks again for the answer!

Dave
Quote Reply
Re: Stupid Question- EASY ANSWER! In reply to
Hey:

Don't do this! I had to edit Links.def to get this out.... it caused a crash on my system!

Dave
Quote Reply
Re: Stupid Question- EASY ANSWER! In reply to
Hey:

What I ended up doing is add VALUE = 'http://' in the INPUT field on the form- problem solved!

Dave
Quote Reply
Re: Stupid Question- EASY ANSWER! In reply to
I haven't added the value="http://" on the add form -- although I've been meaning to -- but I did add http:// as the default for the URL field. Seing as how 99.99999% of the links in my database have been added by none other than me, this is pretty good for the time being...

One thing I keep forgetting to ask, which this conversation has reminded me, is there some guideline to the validation rules? For instance, I added a priority field and followed widgetz' instructions for what to place in the validation field. It worked, but I really didn't know what I was doing... Are the validation rules all standard Perl (I would assume so), or are they specific to Links SQL? That might make a nice FAQ item -- a list of validation rules and what they signify. Wink

Dan

------------------
Run-Down -> Links SQL
http://run-down.com/
Quote Reply
Re: Stupid Question- EASY ANSWER! In reply to
The validations are standard Regex's.

The Mastering Regular Expressions book is _essential_ if you want to do anything serious with regex's



------------------
POSTCARDS.COM -- Everything Postcards on the Internet www.postcards.com
LinkSQL FAQ: www.postcards.com/FAQ/LinkSQL/








Quote Reply
Re: Stupid Question- EASY ANSWER! In reply to
 
Quote:
The Mastering Regular Expressions book is _essential_ if you want to do anything serious with regex's

Although I think many will find this a tough book to get through. You'll need to sit back and read it a couple times to really understand. A good perl book should give you at least a basic understanding of what you need to work with regular expressions.

Cheers,

Alex