$include $lib/gary'smufutils-lists $include $lib/gary'smufutils-misc $include $lib/alynna $include $lib/www_utils $include $lib/rp $include $muf/Scrp/registry $def .tell descr @ swap notify_descriptor $def VERSION prog "_version" getpropstr var cookies var player (-----------------------------------) (-------------VARIBLES=-------------) (-----------------------------------) lvar descr lvar user lvar host lvar params (-----------------------------------) (------------ACTUAL CODE------------) (-----------------------------------) $def }chunk }array "\r\n" array_join dup strlen itoh "\r\n" strcat swap "\r\n" strcat strcat descr @ notify_descriptor_nocr : load_info "|" explode pop atoi descr ! host ! user ! params ! ; : main (s -- ) load_info event_wait pop dup var! data "data" array_getitem "HeaderData" array_getitem "Cookie" array_getitem dup string? not if pop { }dict else "; " explode_array { swap foreach swap pop "=" split repeat }dict then cookies ! "" .tell rpsys { "Web Logins/" hash @ "/Last Connect" }cat systime setprop rpsys { "Web Logins/" hash @ "/Player" }cat getprop toint dup 0 = swap dbref dup player ! player? not or if "You should login to chat." .tell "Click Here" .tell ( exit ) random 5 % case 0 = when #7643 end 1 = when #7559 end 2 = when #7610 end 3 = when #7616 end 4 = when #7631 end endcase player ! rpsys { "Web Logins/" hash @ "/Player" }cat player @ setprop then params @ "Who" instring 1 = if "" .tell "" .tell "" .tell "" .tell online_array dup array_union foreach var! cur pop cur @ "@mcomm/Public" getpropstr "yes" smatch not if continue then cur @ descrleastidle descridle 600 > if continue then { cur @ name "
" }cat .tell repeat exit then params @ "Update" instring if "" .tell "" .tell "" .tell "" .tell ( "" "" .tell #0 "Web/Form Without Reload#" array_get_proplist foreach .tell pop repeat ( "" ) "
" ) 90 100 1 for var! x { #261 "Public#/" x @ intostr strcat getpropstr "" "^normal^" subst "" "^brown^" subst "" "^red^" subst "" "^green^" subst "" "^crimson^" subst "
" }cat dup "" strcat repeat .tell repeat systime var! time begin #261 "Public#/" 100 intostr strcat "/Timestamp" strcat getprop toint time @ > if systime time ! { #261 "Public#/" 100 intostr strcat getprop tostr "" "^normal^" subst "" "^brown^" subst "" "^red^" subst "" "^green^" subst "" "^crimson^" subst "
" }cat dup "" strcat repeat .tell "" .tell then 0 sleep repeat "" .tell exit then params @ "Message" instring if params @ "=" split swap pop "&Submit=Submit" split pop cleanup "Public " swap strcat dup "*&" smatch if dup strlen 1 - strcut pop then "(WEB)" strcat player @ swap force then #261 descr @ "Chat" wwwUtils.displayheader "
" .tell "" .tell "" .tell "" .tell "
" .tell "Message" .tell "
" .tell ( action=\"javascript:get(document.getElementById('form2'));\" ) "" .tell "" .tell ( "" .tell ) ( "" .tell ) "
" .tell "
" .tell player @ toint dbref "@Mcomm/Public" "yes" setprop descr @ wwwUtils.displayfooter ;