摘要: <?phpinclude_once 'common.php';include 'conn.php';$sql_add="insert into `message` (`id`,`user`,`title`,`content`,`lastdate`) values ('','$_POST[user]','$_POST[title]','$_POST[content]',now())";if ($_POST[submit]){ mysql_query($sql_add); if 阅读全文
posted @ 2012-06-29 17:48 神马和浮云 阅读(1262) 评论(1) 推荐(0) 编辑
摘要: 双选确认框,点击是跳转到yes.html,点击否跳转到no.html<?phpecho "<script> if(confirm( '请选择跳转页面,是跳转到yes.html 否跳转到no.html? ')) location.href='yes.html';else location.href='no.html'; </script>"; ?>双选确认框,选择后继续弹出确认对话框<?phpecho "<script> var sure=confirm( ' 阅读全文
posted @ 2012-06-29 17:45 神马和浮云 阅读(16960) 评论(0) 推荐(1) 编辑
摘要: 假设在127.0.0.1上有test1和test2两个库, 其中库test1库中有test1表,test2中有test2表$servername = "127.0.0.1";$username = "root";$password = "root";$conn1 = mysql_connect($servername, $username, $password);mysql_select_db('test1', $conn1);$conn2 = mysql_connect($servername, $username, 阅读全文
posted @ 2012-06-29 12:02 神马和浮云 阅读(2120) 评论(0) 推荐(0) 编辑