Sorting Product order in WP-Ecommerce with Short Code
This is a quick little snippet I am sharing because it helped me out alot and was VERY difficult to find actual documentation on it. I had been trying to sort the products on a client’s website for some time now and the built in product sorter on WP-Ecommerce was not working at all . The goal was to sort the products in alphabetical order starting from “A” and going down. For some reason the site had them in reverse alphabetical order and I do not know why. So, here is how to sort your products by using shortcode with WP-Ecommerce:
If your product shortcode looks like this: [wpsc_products category_id='2 ']
You will want to simply add this: order=’name’
So your final product would be [wpsc_products category_id='12 ' order='name']
That’s it! Should work. You may be able to use other “order” functions but I have not tried that out. Hope this helps!
Have you ever wanted to customize your WordPress admin login screen without using a plugin? Here is a very simple way to achieve this by only making changes to your functions file in your theme. By making the changes to the functions file you will avoid losing your customizations when WordPress makes its next update.
Step One: Create your WordPress login page images. If you want to replace the WordPress logo on the login screen with your own you should try and limit it in size. A good size to use to replace the WordPress logo would be about 320px X 65px.
Step two: Open up your functions.php file in your WordPress theme folder.
Step three: Insert the following snippet of code. Be sure to change where it says “your-image-here” and put the images in the themes image folder.
//Customizations For Login Screen for Admin (images must be in theme image folder)
}add_action(“login_head”, “my_login_head”);
function my_login_head() {
echo ”
<style>
body.login #login h1 a {
background: url(‘”.get_bloginfo(‘template_url’).”/images/your-image-here.png’) no-repeat scroll center top transparent;
height: 65px;
width: 320px;
}
html{background:url(‘”.get_bloginfo(‘template_url’).”/images/your-image-here.jpg’) no-repeat center #fbfbfb !important;}
</style>
“;
}
//End Customizations for Login Screen
That’s it! You should now have a customized WordPress login page!