Domanda

I'm new in drupal 7, and I have to work on an existing project

i want to display a validation message of a webform.

In my custom node.tpl i have a webform with a unique validation on the email, but it's don't show any error message.

I think it was stored in "$messages", but nope.

How can i do this ?

Thanks.

È stato utile?

Soluzione

Wow that was easy, but so hard to fine ...

so here is my solution :

<ul style="color:red;">
<?php
foreach (form_get_errors() as $key => $value) {
?>
    <li>
        <?= $value ?>
    </li>
<?php
}

?>
</ul>
<?php
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top