Magento – redirect product add to cart button to checkout page instead of cart page

checkoutmagento-1onepage-checkout

I have BuyNow button on my product page when I clicked on button it should redirect to checkout page and product should be added to cart page, please tell me proper solution over this how to do this.

Best Answer

Swash_nam, Goto cartcontroller (app>code>core>Mage>Checkout>controllers>CartController.php)'s function goback

$this->_redirect('checkout/cart');

Go to Admin>Configuration>Sales>Checkout>Shopping Cart>After Adding a Product Redirect to Shopping Cart and make it yes