Skip to content

Instantly share code, notes, and snippets.

@sjaved87
Created January 1, 2017 15:46
Show Gist options
  • Save sjaved87/b0e8eeeb5f44fc728b989f116479ba8b to your computer and use it in GitHub Desktop.
Save sjaved87/b0e8eeeb5f44fc728b989f116479ba8b to your computer and use it in GitHub Desktop.
Display order number in edit order page for WPMU DEV MarketPress plugin. Just add the code in functions.php file of your child theme or use it as mu-plugin.
<?php
function wpmudev_mp_sho_order_number( $post ){
if( 'mp_order' != get_post_type( $post ) ) return $post;
echo '<h1 class=&quot;order_number&quot;> # ' .$post->post_title . '</h1>';
echo '<style>
h1.order_number{
margin-top: -42px;
margin-left: 104px;
}
</style>';
}
add_action('edit_form_top', 'wpmudev_mp_sho_order_number');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment