这里是我需要我将如何让用户能够发布并保留在网站上?
我希望能够张贴本网站上的文字帮助的代码,并为它留
<html>
<head>
<title>Negulos</title>
<style>
p {
text-align: center;
color: lime;
font-size: 20px;
}
body {
background-color: black;
overflow-x: hidden;
}
input[type=text], select {
boarder: none;
background-color: black;
color: lime;
position: absolute;
right: 550px;
}
div {
border-radius: 5px;
padding: 20px;
}
</style>
</head>
<body>
<p>Welcome to Negulos the current time is</p><p id="t"></p>
<p>Write anything you'd like to get off your chest</p>
<div>
<input type="text" id="user" value="Your text here">
</div>
<p onclick="post" onmouseover="colorOn(this)" onmouseout="colorOff(this)">post</p>
<p id="post"></p>
<script>
function colorOn(x) {
x.style.color = "red";
}
function colorOff(x) {
x.style.color = "lime";
}
</script>
<script>
function post() {
var x = document.getElementById("user").value;
document.getElementById("post").innerHTML = x;
}
</script>
<script>
document.getElementById("t").innerHTML = Date();
</script>
<?php
?>
</body>
</html>
使用AJAX?!或者可能是我没有得到你想要的东西 –
这里和php有什么关系? –
和你是什么意思*“并保持在网站上?”* - ?? –