Skip to content

Commit

Permalink
Fixes #14217: PHP error when attempting to save a filter
Browse files Browse the repository at this point in the history
1. Fixed the error that used to occur when rendering the save filter form.
2. Add an id to the form div.
3. Centered the save filter form using CSS.
  • Loading branch information
vboctor committed May 6, 2012
1 parent 7a45762 commit a7668f7
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
1 change: 0 additions & 1 deletion core/filter_api.php
Expand Up @@ -3369,7 +3369,6 @@ function filter_draw_selection_area2( $p_page_number, $p_for_screen = true, $p_e
<div class="submit-query"><input type="submit" name="filter" value="<?php echo lang_get( 'filter_button' )?>" /></div>
</form>
<?php
$t_stored_queries_arr = array();
$t_stored_queries_arr = filter_db_get_available_queries();

if( access_has_project_level( config_get( 'stored_query_create_threshold' ) ) ) { ?>
Expand Down
1 change: 1 addition & 0 deletions css/default.css
Expand Up @@ -312,6 +312,7 @@ select.tainted { background-color: #ffffff; color: red; }
.filter-box { margin: 0; padding: 0; font-size: .9em; }
.filter-box table { margin: 0; padding: 0; }
.filter-links { padding: .5em; }
div#save-filter { text-align: center; }
.stored-queries select { font-size: .9em; }
#error-msg { clear: both; }
.error-msg { color: red; text-align: center; }
Expand Down
4 changes: 2 additions & 2 deletions query_store_page.php
Expand Up @@ -57,7 +57,7 @@
html_page_top();
?>
<br />
<div>
<div id="save-filter">
<?php
$t_query_to_store = filter_db_get_filter( gpc_get_cookie( config_get( 'view_all_cookie' ), '' ) );
$t_query_arr = filter_db_get_available_queries();
Expand Down Expand Up @@ -88,7 +88,7 @@
print '<br />';
}
?>
<input type="checkbox" name="all_projects" value="on" <?php check_checked( ALL_PROJECTS == helper_get_current_project() ) ?> >
<input type="checkbox" name="all_projects" value="on" <?php check_checked( ALL_PROJECTS == helper_get_current_project() ) ?> />
<?php print lang_get( 'all_projects' ); ?><br /><br />
<input type="submit" class="button" value="<?php print lang_get( 'save_query' ); ?>" />
</form>
Expand Down

0 comments on commit a7668f7

Please sign in to comment.