Wakaba Extension

By O_Lawd Last update Aug 30, 2010 — Installed 8,864 times.

Sage and form data

in
Subscribe to Sage and form data 2 posts, 2 voices



Username User

Hi, I've made a massive board extension script once, and quicksage didn't break builtin form data storing. If this is still an issue in your script (can't be bothered to check), here's the solution: checkbox must have name identical to email name field, value should be "sage", and you don't have to do any extra processing for its events. If it's checked, postdata will contain "&mail=sage" and won't otherwise, which has an effect of empty mail parameter. Actually, the whole sage thing took 2 lines in my code and worked flawlessly:

if (config[0] && (url_[1] == 'res') && (elt = $n(host_strings.email[location.host])))
	elt.parentNode.innerHTML = '<label><input type="checkbox" name="' + host_strings.email[location.host] + '" value="sage" style="margin-left:0pt;padding-left:0pt"/> sage</label>';

 
O_Lawd Script's Author

Hi, Username.

Your solution sounds nice and sound. I avoid potential name conflicts whenever I make or manipulate forms, but it is a better alternative to losing form data. I'll fix it sometime in the next release.

Cross
Presentational HTML allowed.
Use <code> for inline code and <pre> for code blocks. Use &lt; and &gt; for literal < and >.
We help break paragraphs and link your links.
or cancel