
正文
php文本框显示数据,php文本框代码
提示:扫一扫查出行【扫一扫了解最新限行尾号】
复制提示
php 文本框显示数据库中的内容,然后修改
笨方法:
用JS获取文本框里的值,然后根据这个值获取oid号,提交的时候一起发送给更新处理程序
相关问答
Q1: 用PHP读取出的数据怎么显示到网页的文本框中?高分在线等
html
head
title无标题文档/title
/head
body
p align="center"网页便条 /p
hr/
?php
$file = 'G:/google/a.txt';
$content = file_get_contents($file); //读取文件中的内容
echo HTM
form name="form1" method="post" action=""
div align="center"
input type="text" name="textbox1" value=$content //怎么显示到这个文本框中
input type="button" name="btn1" value="保存" onClick="savefile('newfile.txt',this.form.textbox1.value)"
/div
/form
HTM;
echo $content;
?
/body
/html
用定界符试试
Q2: php文本框内显示数据库里面的数据问题
input name="username" type="text" value="?=$row['username']?"
$username=$_POST['username'];
update("update `table` set `username`='$username' where `id`='$id'");
这样就可以了。。。





