Autor Zpráva
SOoly
Profil *
Ahoj,
rozhodl jsem se na svoji stránku vložit recaptchu. Potřebuji,aby když opsaný kód byl správně,aby se provedl následující kód. Mám toto:

if(mysql_query('insert into topsite (id, name, url, description, banner, email, votes, status) values ("'.$id.'", "'.$name.'", "'.$url.'", "'.$description.'", "'.$banner.'", "'.$email.'", 0, "no")'))
    { 
        echo '<strong>Your website has successfully been submited, an admin will check it soon.</strong><br />
You can start earning votes:<br />
<input type="text" value="'.htmlentities('<a href="'.$url_root.'vote.php?id='.$id.'">Vote for this Website</a>').'" size="50" onclick="this.select();" />';
    }
    else
    {     
        echo '<strong>An error occurred while submitting the website.</strong>';
    }



a potřeboval bych něco takového:


if ($resp->is_valid) // zstíme, či zadaný kód je správny
  {
  (mysql_query('insert into topsite (id, name, url, description, banner, email, votes, status) values ("'.$id.'", "'.$name.'", "'.$url.'", "'.$description.'", "'.$banner.'", "'.$email.'", 0, "no")'));
    echo '<strong>Your website has successfully been submited, an admin will check it soon.</strong><br />
You can start earning votes:<br />
<input type="text" value="'.htmlentities('<a href="'.$url_root.'vote.php?id='.$id.'">Vote for this Website</a>').'" size="50" onclick="this.select();" />';
  
    else
    {     
        echo '<strong>An error occurred while submitting the website.</strong>';
    }


Bohužel nevím,jak to zformulovat. Díky.

Moderátor Str4wberry: Vkládej prosím kódy mezi značky [pre] a [/pre] (stačí kliknout na ).
Str4wberry
Profil
A poměrně zdařilý návod nezabral?

Vaše odpověď


Prosím používejte diakritiku a interpunkci.

Ochrana proti spamu. Napište prosím číslo dvě-sta čtyřicet-sedm:

0