Put things in folders and stuff

This commit is contained in:
Brian Miyaji
2014-01-06 22:32:15 +11:00
parent 4e53aa5424
commit 3ab4ea33bd
26 changed files with 574 additions and 528 deletions

View File

@@ -37,7 +37,7 @@ function sp_column_meta_init() {
}
function sp_column_details_meta( $post ) {
global $sportspress_config_formats;
$formats = sp_get_config_formats();
$equation = explode( ' ', get_post_meta( $post->ID, 'sp_equation', true ) );
$order = get_post_meta( $post->ID, 'sp_order', true );
@@ -55,7 +55,7 @@ function sp_column_details_meta( $post ) {
<p class="sp-format-selector">
<select name="sp_format">
<?php
foreach ( $sportspress_config_formats as $key => $value ):
foreach ( $formats as $key => $value ):
printf( '<option value="%s" %s>%s</option>', $key, selected( true, $key == $priority, false ), $value );
endforeach;
?>

View File

@@ -13,7 +13,7 @@ function sp_player_cpt_init() {
'register_meta_box_cb' => 'sp_player_meta_init',
'rewrite' => array( 'slug' => get_option( 'sp_player_slug', 'player' ) ),
'menu_icon' => 'dashicons-groups',
'capability_type' => 'sp_player'
'capability_type' => 'sp_player',
);
register_post_type( 'sp_player', $args );
}
@@ -25,7 +25,7 @@ function sp_player_edit_columns() {
'title' => __( 'Name', 'sportspress' ),
'sp_position' => __( 'Positions', 'sportspress' ),
'sp_team' => __( 'Teams', 'sportspress' ),
'sp_season' => __( 'Seasons', 'sportspress' )
'sp_season' => __( 'Seasons', 'sportspress' ),
);
return $columns;
}

View File

@@ -35,7 +35,7 @@ function sp_result_meta_init() {
}
function sp_result_details_meta( $post ) {
global $sportspress_config_formats;
$formats = sp_get_config_formats();
?>
<p><strong><?php _e( 'Key', 'sportspress' ); ?></strong></p>
<p>
@@ -45,7 +45,7 @@ function sp_result_details_meta( $post ) {
<p class="sp-format-selector">
<select name="sp_format">
<?php
foreach ( $sportspress_config_formats as $key => $value ):
foreach ( $formats as $key => $value ):
printf( '<option value="%s" %s>%s</option>', $key, selected( true, $key == $priority, false ), $value );
endforeach;
?>

View File

@@ -37,7 +37,7 @@ function sp_statistic_meta_init() {
}
function sp_statistic_equation_meta( $post ) {
global $sportspress_config_formats;
$formats = sp_get_config_formats();
$equation = explode( ' ', get_post_meta( $post->ID, 'sp_equation', true ) );
$order = get_post_meta( $post->ID, 'sp_order', true );
@@ -55,7 +55,7 @@ function sp_statistic_equation_meta( $post ) {
<p class="sp-format-selector">
<select name="sp_format">
<?php
foreach ( $sportspress_config_formats as $key => $value ):
foreach ( $formats as $key => $value ):
printf( '<option value="%s" %s>%s</option>', $key, selected( true, $key == $priority, false ), $value );
endforeach;
?>