Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if (isset($_POST['save']) && $_POST['save'] == 'save') {$q_cont = $_POST['Klausimas'];
- $q_title = $_POST['KlausimoPav'];
- $db =mysql_connect("localhost","root","burblis7") or die ("cant connect");
- mysql_select_db("psichologasWP",$db) or die("unable to find database");
- $duom = mysql_query("INSERT INTO wp_posts ( post_author,post_content,post_title,post_type) VALUES('2','$q_title','$q_cont', 'question')");}
- ?>
- <form action="" method="post" name="uzd_klausima">
- <input name="KlausimoPav" id="KlausimoPav" type="text" />
- <br>
- <textarea name="Klausimas" id="Klausimas" cols="20" rows="5"></textarea><br>
- <input name="submit" type="submit" value="Klausti" name="ask_side" />
- <input type="hidden" id="save" name="save" value="save">
- </form>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement