[Tutor] Design suggestion - is a cookie the answer?

Adam Cripps kabads at gmail.com
Sun Jan 15 23:05:37 CET 2006


On 1/15/06, Simon Gerber <nequeo at gmail.com> wrote:
> > I'd recommend using client side JavaScript for this.
> > Create a submit function in JavaScript that will only
> > actually submit the form if all the questions have been
> > completed.
>
> I'm sure this is implied in Alan's post, but I'm going to point it out
> anyway as it's not always obvious if you're just starting to learn
> Javascript.
>
> To avoid further cheating you might want to sure there is no way to
> submit the form without javascript turned on. E.g. Don't have a submit
> button and a form with an 'onSubmit' validation. Which some examples
> do use. Otherwise, they can just turn off Javascript support in their
> browser and bypass your validation.
>
> Instead, have a plain old form button that uses the 'onClick' event to
> call a validation function, which also submits the form itself if
> everything works.
>
> Cheers,
>

Thanks Alan and Simon.

I must admit, I've been avoiding Javascript, but if this is the best
way of doing it, then so be it. Will the URL intervene in just
presenting a URL to the browser? One of the 'cheats' was just putting
the cursor within the URL bar and then pressing enter. Does Javascript
pick this up as well?

Many thanks again,

Adam

--
http://www.monkeez.org
PGP key: 0x7111B833


More information about the Tutor mailing list