Files
minisrv/zefie_wtvp_minisrv/ServiceVault/wtv-setup/get-settings.js
zefie df472ab91f v0.9.13
- wtv-cookie support
 - further development will be in dev branch (may rebase alot)
 - compression not yet ready, leave it disabled
 - update: do not delete WTVSec on last socket, instead recreate on prereg
 - update: clean up SSID session data only if client is not seen for 3 minutes
 - update: add shouldWeCompress() function
 - update: tweak lzpf (still corrupted)
 - update: rename wtv-setup:/get to wtv-setup:/get-settings
 - update: add additional headers to wtv-setup:/get-settings
 - update: add initial blank wtv-music:/get-playlist
 - update wtv-tricks system
   - Info now shows Guest Mode or Subscriber Info
   - Implemented wtv-tricks:/unregister
   - Implemented wtv-tricks:/register
   - Show correct link in wtv-tricks:/tricks based on Guest Mode status
 - config.json: enable compression by default
 - WTVP does not use \r, so swapping the internal header's usage for now. May remove internal header in future update
 - lzpf: this doesn't fix anything but doesn't break it more either :)
  - renamed some functions
  - fixed some param documentation
  - added ConvertToBuffer function
 - WTVSec Updates
  - optimize WordArray to Buffer functions
  - update documentation in WTVSec
  - update WTVSec barrowed function in WTVLzpf
  - removed NewRC4Session, was a pointless alias to SecureOn
2022-11-29 08:27:52 -05:00

36 lines
1.2 KiB
JavaScript

headers = `200 OK
wtv-backgroundmusic-load-playlist: wtv-music:/get-playlist
wtv-printer-model: -1,-1
wtv-printer-pen: 0,0,1,0
wtv-printer-setup: 0,0,1,0
wtv-language-header: en-US,en
Content-Type: text/html`
var settings_obj = new Array();
settings_obj["from-server"] = 1;
settings_obj["setup-advanced-options"] = 0;
settings_obj["setup-play-bgm"] = 0;
settings_obj["setup-bgm-tempo"] = -1;
settings_obj["setup-bgm-volume"] = 100;
settings_obj["setup-background-color"] = "c6c6c6";
settings_obj["setup-font-sizes"] = "medium";
settings_obj["setup-in-stereo"] = 1;
settings_obj["setup-keyboard"] = "alphabetical";
settings_obj["setup-link-color"] = "2222bb";
settings_obj["setup-play-songs"] = 1;
settings_obj["setup-play-sounds"] = 1;
settings_obj["setup-text-color"] = 0;
settings_obj["setup-visited-color"] = "8822bb";
settings_obj["setup-japan-keyboard"] = "roman";
settings_obj["setup-japan-softkeyboard"] = "norm"
settings_obj["setup-chat-access-level"] = 0;
settings_obj["setup-chat-on-nontrusted-pages"] = 1;
settings_obj["setup-tv-chat-level"] = 2;
data = "";
Object.keys(settings_obj).forEach(function (k, v) {
data += k + "=" + escape(settings_obj[k]) + "&";
});
data = data.substring(0, (data.length - 1));