View Issue Details

This issue affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
06860Bug reportsTheme editorpublic2021-10-22 12:24
Reporterjweberhofer Assigned Togalads  
PrioritynormalSeveritypartial_block 
Status closedResolutionfixed 
Product Version2.00+ 
Summary06860: Add some java-script to prevent users using the backward key by accident
Description

Especially in long surveys the usage of the backward key may cause issues on data entering. Therefore I'd suggest the following JS-code on each site:

window.onbeforeunload = function(e) {
return 'Do you want to tleave the survey? If not, use the cancel button.';
};

Mozilla will not display the text but only a standard text. A full documentation for the function is here: https://developer.mozilla.org/en-US/docs/DOM/window.onbeforeunload

TagsNo tags attached.
Bug heat6
Complete LimeSurvey version number (& build)120924
I will donate to the project if issue is resolvedNo
Browser
Database type & versionMySQL 5.5.25
Server OS (if known)opensuse 12.1
Webserver software & version (if known)Apache/2.2.21
PHP Version5.3.8
Git branch / Pull Request URL

Users monitoring this issue

There are no users monitoring this issue.

Activities

DenisChenu

DenisChenu

2012-11-14 10:30

developer   ~22136

Last edited: 2012-11-14 10:30

Think it's better to use some iframe to do this.

An iframe is not affected by backward.

PS: and then leave like this.

sammousa

sammousa

2012-11-26 22:25

reporter   ~22557

I think this would be a good addition.

Use jQuery to hook the event though, this will make it cross browser and will separate layout from functionality.

tpartner

tpartner

2013-01-25 18:27

partner   ~23816

Er...do we really want to add another alert?

Shouldn't this be something for the user to add to template.js?

Issue History

Date Modified Username Field Change
2012-11-12 22:52 jweberhofer New Issue
2012-11-13 00:21 c_schmitz Project Bug reports => @10@
2012-11-14 10:30 DenisChenu Note Added: 22136
2012-11-14 10:30 DenisChenu Note Edited: 22136
2012-11-26 22:25 sammousa Note Added: 22557
2013-01-25 18:27 tpartner Note Added: 23816
2015-12-11 14:40 c_schmitz Category Templates => Theme editor
2021-10-22 12:24 galads Assigned To => galads
2021-10-22 12:24 galads Status new => closed
2021-10-22 12:24 galads Resolution open => fixed