Skip to content

Commit

Permalink
New Feature: (Idea #103) Gives the user the ability to preview questi…
Browse files Browse the repository at this point in the history
…on groups.

Dev Modified group.php to give it the ability to preview question groups.

git-svn-id: file:///Users/Shitiz/Downloads/lssvn/source/limesurvey_dev@9556 b72ed6b6-b9f8-46b5-92b4-906544132732
  • Loading branch information
Kshitij Parajulik committed Nov 30, 2010
1 parent c08b567 commit a05856f
Show file tree
Hide file tree
Showing 4 changed files with 392 additions and 312 deletions.
7 changes: 7 additions & 0 deletions admin/admin.php
Expand Up @@ -249,6 +249,13 @@
if(bHasSurveyPermission($surveyid,'surveycontent','read')) {include('preview.php');}
else { include('access_denied.php');}
}
elseif ($action == 'previewgroup')
{

require_once('../index.php');
exit;

}
elseif ($action=='addgroup' || $action=='editgroup' || $action=='ordergroups')
{
if(bHasSurveyPermission($surveyid,'surveycontent','read')) {$_SESSION['FileManagerContext']="edit:group:$surveyid"; include('questiongrouphandling.php');}
Expand Down
18 changes: 14 additions & 4 deletions admin/html.php
Expand Up @@ -811,10 +811,20 @@
// // CREATE BLANK SPACE FOR IMAGINARY BUTTONS
//
//
$groupsummary .= ""
. "<img src='$imageurl/blank.gif' alt='' width='54' height='20' />\n"
. "<img src='$imageurl/seperator.gif' alt='' />"
. "<img src='$imageurl/blank.gif' alt='' width='50' height='20' />";
$groupsummary .= ""
. "<img src='$imageurl/blank.gif' alt='' width='54' height='20' />\n";

if(bHasSurveyPermission($surveyid,'surveycontent','update'))
{
$groupsummary .= "<img src='$imageurl/seperator.gif' alt='' />\n"
. "<a href=\"#\" onclick=\"window.open('$scriptname?action=previewgroup&amp;sid=$surveyid&amp;gid=$gid','_blank')\""
. " title=\"".$clang->gTview("Preview current question group")."\">"
. "<img src='$imageurl/preview.png' alt='".$clang->gT("Preview current question group")."' name='PreviewGroup' /></a>\n" ;
}
else{
$groupsummary .= "<img src='$imageurl/seperator.gif' alt='' />\n";
}



// EDIT CURRENT QUESTION GROUP BUTTON
Expand Down

0 comments on commit a05856f

Please sign in to comment.