Skip to content

Commit

Permalink
Fixed issue #4183: Notices at Printable Survey if there are no answer…
Browse files Browse the repository at this point in the history
…s/label set set for a question

git-svn-id: file:///Users/Shitiz/Downloads/lssvn/source/limesurvey@8463 b72ed6b6-b9f8-46b5-92b4-906544132732
  • Loading branch information
c-schmitz committed Mar 8, 2010
1 parent df2f87c commit e23899d
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions admin/printablesurvey.php
Expand Up @@ -1516,14 +1516,24 @@ function star_replace($input)
{
$column_headings[] = $frow['title'];
}
$col_width = round(80 / count($column_headings));
if (count($column_headings)>0)
{
$col_width = round(80 / count($column_headings));

}
else
{
$heading='This question shas';
}

$question['ANSWER'] .= "\n<table>\n\t<thead>\n\t\t<tr>\n";
$question['ANSWER'] .= "\t\t\t<td>&nbsp;</td>\n";
foreach($column_headings as $heading)
$question['ANSWER'] .= "\t\t\t<th style=\"width:$col_width%;\">$heading</th>\n";
$pdfoutput[0][$i] = $heading;
$i++;
{
$question['ANSWER'] .= "\t\t\t<th style=\"width:$col_width%;\">$heading</th>\n";
}
$pdfoutput[0][$i] = $heading;
$i++;
$question['ANSWER'] .= "\t\t</tr>\n\t</thead>\n\n\t<tbody>\n";
$counter = 1;
$rowclass = 'array1';
Expand Down

0 comments on commit e23899d

Please sign in to comment.