View Issue Details

This bug affects 1 person(s).
 2
IDProjectCategoryView StatusLast Update
05011Bug reportsOtherpublic2011-04-11 11:32
Reporterbolero Assigned Totpartner  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version1.91RC4 
Fixed in Version1.91RC6 
Summary05011: "clear all" buttons breaks frames and iframes
Description

compare http://www.limesurvey.org/de/forum/development/57879-why-is-qclearallq-going-to-qtopq
I want to run a survey in an iframe and found one showstopper: the option to "leave and clear all" does a window.open to "_top". I'm not sure why that is done, but it spoils the experience if run within an iframe. I changed that to go to "_self" instead and that seems to work quite fine, including the actions you can do afterwards (except for closing the window, of course).

Steps To Reproduce

see above. call a survey in an iframe and then leave it with the "clear all" option. It goes to _top which means that the survey takes over all of the visible application. The same is probably going to happen if one calls the survey in a normal frame.

Additional Information

So far I haven't seen any ill effects of my change, it works as expected.
The change is in common_functions.php, line 3026:
$clearall .= "', '_self')}\" />";

I just notice I made another change to cater for frames:
//$linkreplace="<a href='{$thissurvey['surveyls_url']}'>{$thissurvey['surveyls_urldescription']}</a>";
// fix for running in an iframe ks 6. 3.2011
$linkreplace="<a target='_top' href='{$thissurvey['surveyls_url']}'>{$thissurvey['surveyls_urldescription']}</a>";
This change assures that at the end when you click the EndURL it doesn't open in the frame but to _top, so this is exactly the opposite. It assures that you don't open your application within your application. Theoretically, this change shouldn't do any harm to non-framed environments, so it should be harmless to add this as well.

TagsNo tags attached.
Bug heat2
Complete LimeSurvey version number (& build)9797
I will donate to the project if issue is resolvedNo
BrowserIE8
Database type & versionnot relevant
Server OS (if known)not relevant
Webserver software & version (if known)not relevant
PHP Versionnot relevant

Users monitoring this issue

There are no users monitoring this issue.

Activities

tpartner

tpartner

2011-03-09 13:52

partner   ~14355

I agree with both suggestions - fixed in revision 9878.

Thanks for the report bolero.

Issue History

Date Modified Username Field Change
2011-03-08 22:15 bolero New Issue
2011-03-09 13:42 tpartner Assigned To => tpartner
2011-03-09 13:42 tpartner Status new => assigned
2011-03-09 13:52 tpartner Note Added: 14355
2011-03-09 13:52 tpartner Status assigned => resolved
2011-03-09 13:52 tpartner Resolution open => fixed
2011-04-11 11:32 c_schmitz Status resolved => closed
2011-04-11 11:32 c_schmitz Fixed in Version => 1.91RC6