Permalink
Browse files

Fix type issues with check_selected in view_filter_page.php

  • Loading branch information...
1 parent 0028eff commit 6e86190e59745a8456a84a39deb64bb49d7930a1 @dregad dregad committed Jan 31, 2014
Showing with 8 additions and 8 deletions.
  1. +8 −8 core/filter_api.php
View
@@ -4302,28 +4302,28 @@ function print_filter_custom_field_date( $p_field_num, $p_field_id ) {
echo "\n<table cellspacing=\"0\" cellpadding=\"0\"><tr><td>\n";
echo "<select size=\"1\" name=\"custom_field_" . $p_field_id . "_control\">\n";
echo '<option value="' . CUSTOM_FIELD_DATE_ANY . '"';
- check_selected( $t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_ANY );
+ check_selected( (int)$t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_ANY );
echo '>' . lang_get( 'any' ) . '</option>' . "\n";
echo '<option value="' . CUSTOM_FIELD_DATE_NONE . '"';
- check_selected( $t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_NONE );
+ check_selected( (int)$t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_NONE );
echo '>' . lang_get( 'none' ) . '</option>' . "\n";
echo '<option value="' . CUSTOM_FIELD_DATE_BETWEEN . '"';
- check_selected( $t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_BETWEEN );
+ check_selected( (int)$t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_BETWEEN );
echo '>' . lang_get( 'between_date' ) . '</option>' . "\n";
echo '<option value="' . CUSTOM_FIELD_DATE_ONORBEFORE . '"';
- check_selected( $t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_ONORBEFORE );
+ check_selected( (int)$t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_ONORBEFORE );
echo '>' . lang_get( 'on_or_before_date' ) . '</option>' . "\n";
echo '<option value="' . CUSTOM_FIELD_DATE_BEFORE . '"';
- check_selected( $t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_BEFORE );
+ check_selected( (int)$t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_BEFORE );
echo '>' . lang_get( 'before_date' ) . '</option>' . "\n";
echo '<option value="' . CUSTOM_FIELD_DATE_ON . '"';
- check_selected( $t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_ON );
+ check_selected( (int)$t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_ON );
echo '>' . lang_get( 'on_date' ) . '</option>' . "\n";
echo '<option value="' . CUSTOM_FIELD_DATE_AFTER . '"';
- check_selected( $t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_AFTER );
+ check_selected( (int)$t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_AFTER );
echo '>' . lang_get( 'after_date' ) . '</option>' . "\n";
echo '<option value="' . CUSTOM_FIELD_DATE_ONORAFTER . '"';
- check_selected( $t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_ONORAFTER );
+ check_selected( (int)$t_filter['custom_fields'][$p_field_id][0], CUSTOM_FIELD_DATE_ONORAFTER );
echo '>' . lang_get( 'on_or_after_date' ) . '</option>' . "\n";
echo '</select>' . "\n";

0 comments on commit 6e86190

Please sign in to comment.