Quote:
Originally Posted by Warwick
So what should I use?
Code:
if (value == false ) {
or
Code:
if (value == '' ) {
|
It seems to me two variants are possible.
Quote:
Originally Posted by Warwick
So what should I use?
And is there a way to let the script check if it is an url?
btw when using the 'Buy now' button the script is bypassed 
|
It is highly depend on what are you mean by "correct URL".
Code:
var value = product_option_value("url");
if (value == false ) {
alert("Sorry, you should enter an url");
return false;
}
Should work. Code posted above by Ene is OK too. See if your custom field's name is exactly matching 'url' (including case)