Link to home
Start Free TrialLog in
Avatar of denny3d
denny3d

asked on

error remote path plugin validate jquery

Hi EE
i have a problem about path for validate plugin of Jquery
this is my js script:
*****
      var validator = $("#tipformins").validate({
            rules: {
                  cod: {
                        required: true,
                        number: true,
                        remote: "/remote/val_cod_tipGlass2.php"
                  },
                  tipology: "required"
            },
            messages: {
                  cod: {
                        required: "Inserire codice tipologia",
                        number: "formato numerico",
                        remote: jQuery.format("Codice {0} gia' esistente negli archivi!")
                        },
                  tipology: "Nome categoria prodotto"
            }
      });
*****

so , its dont work
while if I copy val_cod_tipGlass2.php in the same directory of primary page and change the code into
****
      var validator = $("#tipformins").validate({
            rules: {
                  cod: {
                        required: true,
                        number: true,
                        remote: "val_cod_tipGlass2.php"
                  },
                  tipology: "required"
            },
            messages: {
                  cod: {
                        required: "Inserire codice tipologia",
                        number: "formato numerico",
                        remote: jQuery.format("Codice {0} gia' esistente negli archivi!")
                        },
                  tipology: "Nome categoria prodotto"
            }
      });
***

it's work fine

maybe I make error in the path from

remote: "/remote/val_cod_tipGlass2.php"

to

remote: "val_cod_tipGlass2.php"


????

regards
Denis
ASKER CERTIFIED SOLUTION
Avatar of Xemorph
Xemorph
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of denny3d
denny3d

ASKER

thanks