born Posted November 12, 2006 Report Share Posted November 12, 2006 Lietojot POST un GET šajā konstrukcijā nedarbojās POST. Konkrēti EDIT sadaļa nestrādā, tai būtu jāsūta dati ar POST metodi, bet nekā, tā to dara ar GET.. Kods apmēram šāds... <a href="?do=show〈=g1&page=g2">get test</a><br /> <a href="?do=edit">edit</a><br /> <? switch ($_GET['do']) { case "edit": echo '<form action=test.php?do=show mehtod=post >'; echo '<input type="hidden" name="lang" value="p1"> '; echo '<input type="hidden" name="page" value="p2"> '; echo '<textarea name="text" rows="2" cols="5">'; echo '</textarea><br />'; echo '<input type="submit" value="submit" /></form> '; break; case "show": echo "<br />get = $_GET[do] /get = $_GET[lang] /get = $_GET <br />"; echo "post =$_POST[lang] /post = $_POST / post = $_POST[text] "; break; } ?> Link to comment Share on other sites More sharing options...
andrisp Posted November 12, 2006 Report Share Posted November 12, 2006 (edited) Varbūt tāpēc, ka tev ir mehtod nevis method :). PS. Kā arī silti iesaku html tagu atribūtu vērtības likt pēdiņās. Edited November 12, 2006 by andrisp Link to comment Share on other sites More sharing options...
born Posted November 12, 2006 Author Report Share Posted November 12, 2006 Varbūt tāpēc, ka tev ir mehtod nevis method :). PS. Kā arī silti iesaku html tagu atribūtus likt pēdiņās. fuck...es 50 reizes parbaudiju pareizrakstibas kljudas, jo man biezhi sanaak :D bet nekadi nevareeju pamaniit :D thnx...bus janoligst darbaa koda redaktoru kursh labo pareizrakstibas kljudas... Link to comment Share on other sites More sharing options...
andrisp Posted November 12, 2006 Report Share Posted November 12, 2006 FF + HTML Validator extension. Link to comment Share on other sites More sharing options...
Recommended Posts