Muzes pouzit javascript pro upravy a na konci to nechat ulozit. Odesle to do php, ktere prepise stranku. Ale urcite tam pridej historii, aby bylo mozne obnovit predesle verze.
A nebo tam muzes napojit nejaky wysiwyg editor, treba ckeditor a jine.
A nebo to muzes cele zplacat zrovna v nejakem redakcnim systemy (joomla, wordpress, drupal ...)
A nebo muzes pouzit hosting, ktery umoznuje editac stranek. Kde si ale pak za moznost editace priplati. Tusim, ze tohle se mi zdalo jako privetive pro admina
http://www.web-rychle.cz/
<body>
<br>a)
<br>
<br>html 1
<div id=b></div>
<br>editor 1
<br><textarea id=a>text</textarea>
<input type=button onclick="f();" value=refresh>
<script>
function o(id) {return document.getElementById(id);}
function f() {o('b').innerHTML = o('a').value;}
setInterval('f()',300);
</script>
<br>
<br>
<br>b)
<br>
<br>html2
<br><span onclick="edit(this);">klikni na text</span>
<br>
<br>editor2
<br><textarea id="editor" onkeyup="modify();"></textarea>
<br><form action="edit.php" onsubmit="return sendPage();" method="post"><input type="hidden" name="page" id="page"><input type="submit"></form>
<script>
mem = {};
mem.obj = {};
mem.obj.body = document.getElementsByTagName('BODY')[0];
mem.obj.page = document.getElementById('page');
mem.obj.editor = document.getElementById('editor');
mem.obj.text = null
//alert(mem.obj.toSource());
function edit(obj) {
mem.obj.text = obj;
mem.obj.editor.value = mem.obj.text.innerHTML;
mem.obj.editor.focus();
}
function modify(obj) {
mem.obj.text.innerHTML = mem.obj.editor.value; // mozna pridat escape()
}
function sendPage(obj) {
mem.obj.page.value = mem.obj.body.innerHTML; // ale kdo vi, co to udela, kdyz tam pridas znaky < > a spatne tagy a pod
alert(mem.obj.page.value);
return false;
//return true;
}
</script>
</body>
Tam je treba zmenit to return false na true, aby to odeslalo. Ted to proste zobrazi cely html dokument ve Firefoxu.
Ale osobne si myslim, ze by stacilo proste uzivateli zobrazit html kod, at si to opravi.