English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I want someone to be able to mark off a task and have it timestamped and remain un-editable.

2006-07-20 09:26:19 · 4 answers · asked by jrgreenfield1 2 in Computers & Internet Programming & Design

I want it to happen automatically and remain permenent so other users can see that that 'task' has been completed

2006-07-20 09:32:42 · update #1

4 answers

That is actually pretty complicated.
Basically, give the checkbox a value like value='box1checked' and name it something like name='checkbox1'
Then, have the submit button reload the page.
The $_POST['checkbox1'] will have the value 'box1checked' or it could be an empty variable.
Now, within your html, embed the following:

Hey, if you can't figure this out, send me an EMail and I will whip an example up for you when I get home tonight.

***Your gonna need to implement MySQL to save any permanent data. that is a whole'nother story.

2006-07-20 09:36:32 · answer #1 · answered by Anonymous · 0 0

do you want this to happen automatically on the page, or have an update in the database?

If you want it to happen in the page itself, without going back, updating the db, and requesting a new page you need to use javascript like:
text to bold later

If you want the back end to control it, just use php to set a timestamp in the db related to that task (depends on how you have the database set up) and if that field is filled on a request surround the copy with a tag.

To disable a text field in html just include 'disabled = "disabled"' in the tag.

You can make it do both, or just turn the act of clicking the checkbox into a submit by adding onclick = "this.form.submit()" to the checkbox input tag. It will then go back to the back end, updated the db, and request the page like I described.

2006-07-20 09:29:28 · answer #2 · answered by John J 6 · 0 0

eliminate the mailto area purely go away it at then the values entered will be saved as variables that you'll use contained in the subsequent web page it truly is for now thenewpage.personal living house web page (you could change that) playstation : gime ideal answer if it quite works lol.. thx !

2016-12-02 00:25:42 · answer #3 · answered by jerklin 3 · 0 0

if(isset($_POST['submit_form']) {
$time = time();
}

echo "text - $time";
?>

Didn't catch your update. If you want to save this information you'll need a database and need to do a query as such.

if(isset($_POST['submit_form']) {
$time = time();
$u = mysql_query("UPDATE table SET time='$time' WHERE task_id='".$_GET['id']."'") or die("error! ".mysql_error());
}
?>

2006-07-20 09:33:25 · answer #4 · answered by Anonymous · 0 0

fedest.com, questions and answers