Skip to content

Commit

Permalink
added limit date
Browse files Browse the repository at this point in the history
  • Loading branch information
mdogadailo committed Mar 20, 2017
1 parent e7312f5 commit 5f641fb
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions feedback/feedback.php
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,8 @@ function plugin_feedback_showScreen($mode = 0, $errorText = '') {
}
$tEntry['options']['month'] = $opts;
$opts = $fInfo['required'] ? '' : '<option value="">--</option>';
for ($di = 1970; $di <= 2012; $di++) {
$yearLimit = date('Y');
for ($di = 1970; $di <= $yearLimit; $di++) {
$opts .= '<option value="' . $di . '"' . ($di == $setValueYear ? ' selected="selected"' : '') . '>' . $di . '</option>';
}
$tEntry['options']['year'] = $opts;
Expand Down Expand Up @@ -488,4 +489,4 @@ function plugin_feedback_post() {
),
);
$template['vars']['mainblock'] = $xt->render($tVars);
}
}

0 comments on commit 5f641fb

Please sign in to comment.