Smarty Forum Index Smarty
The discussions here are for Smarty, a template engine for the PHP programming language.

SmartyValidate is_valid($_POST) problem

 
Post new topic   Reply to topic    Smarty Forum Index -> Add-ons
View previous topic :: View next topic  
Author Message
wrzasq
Smarty n00b


Joined: 13 Sep 2004
Posts: 2

PostPosted: Mon Sep 13, 2004 5:10 pm    Post subject: SmartyValidate is_valid($_POST) problem Reply with quote

i got problem with validation of my form. i got this in template:
Code:
   {validate field="author" criteria="notEmpty" transform="trim"}
   {if $logged}
                  {$nick}
                  <INPUT type="hidden" name="author" value="{$nick}">
   {else}
                  <INPUT type="text" name="author">
   {/if}

in my php file i got:
[php:1:061639ef79]
if( !SmartyValidate::is_valid($_POST) )
{
$site->display("error.tpl");
}
else
{
[/php:1:061639ef79]

when im not logged its all ok, but when im logged it display error, but when i do
[php:1:061639ef79]
echo $_POST['author'];
[/php:1:061639ef79]
it shows my nick correct.

can anyone help?
Back to top
View user's profile Send private message
kills
Smarty Elite


Joined: 28 May 2004
Posts: 493

PostPosted: Wed Sep 15, 2004 6:11 am    Post subject: Reply with quote

error message?
Back to top
View user's profile Send private message
wrzasq
Smarty n00b


Joined: 13 Sep 2004
Posts: 2

PostPosted: Sun Sep 19, 2004 1:54 pm    Post subject: Reply with quote

nvm please... i forgot to disconnect() after one form and old validators stay for other form Confused sorry for trouble Razz
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Smarty Forum Index -> Add-ons All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP