scratchpad size + moved templates to textdb

This commit is contained in:
psyc://psyced.org/~lynX 2010-02-22 21:51:14 +01:00
parent 9585321ecf
commit 791f671bf4
4 changed files with 13 additions and 8 deletions

View File

@ -558,6 +558,9 @@ _request_open_page_edit
|Zur Bearbeitung der Einstellungen bitte folgende Seite aufrufen:
|[_page_edit]
_notice_update_scratchpad
|[_page_scratchpad] wurde verändert ([_size_scratchpad] bytes).
_request_call_link
|Anruf von [_nick]: Annehmen durch Klick auf [_page_call].

View File

@ -1352,9 +1352,8 @@ _PAGES_start_description
|<script>
|var longer = 44
|
|function cmd(wish, dest) {
|function cmd(wish) {
| Pef.cmd.value = wish
| Pef.dest.value = dest || ''
| Pef.submit()
| longer = 44
| return false

View File

@ -553,6 +553,9 @@ _request_description_vCard
_request_friendship_implied
|## no output
_notice_update_scratchpad
|[_page_scratchpad] has changed ([_size_scratchpad] bytes).
_request_call_link
|[_nick] would like to speak to you. Use [_page_call] to answer the call.

View File

@ -453,7 +453,7 @@ htget(prot, query, headers, qs, data, noprocess) {
# ifdef PLACE_SCRATCHPAD
sTextPath(query["layout"] || MYNICK, query["lang"], "html");
if (!noprocess && (!qs || query["scratchpad"])) {
string rand, buf;
string rand, buf, len;
// microscopic wiki functionality .. cheap imitation of tobi's save.pike
//
// things one could add:
@ -475,7 +475,7 @@ htget(prot, query, headers, qs, data, noprocess) {
// his changes first.. well. might not happen.
// TODO: prefix id with epoch?
if (stringp(query["scratchpad"])
&& strlen(query["scratchpad"]) > 1
&& (len = strlen(query["scratchpad"])) > 1
//
// id logic serves the purpose of not changing the scratchpad while going
// "back" in the browser history. only a new "post" should change it.
@ -499,14 +499,14 @@ htget(prot, query, headers, qs, data, noprocess) {
// call_out(#'m_delete, 86400 /* 24 hours */,
// used, query["id"]);
castmsg(ME, "_notice_update_scratchpad",
"The [_page_scratchpad] has changed.", ([
castmsg(ME, "_notice_update_scratchpad", 0, ([
"_size_scratchpad": len,
#ifdef PRO_PATH // __TLS__
"_page_scratchpad":
"_page_scratchpad":
((tls_available() && HTTPS_URL) || HTTP_URL)
#else
// problem with POST over https apparently..
"_page_scratchpad": (HTTP_URL)
"_page_scratchpad": (HTTP_URL)
#endif
// TODO: use psycName() here instead
+"/@"+ MYNICK +"?scratchpad"