commerce_checkout_progress_init() needs to go away because it overrides $_GET['q']. This is ugly. See #1296218: Commerce Checkout Progress comment #3.
The issue is that the first checkout page doesn't display the page id. Every other page does. The path for the first checkout page is 'checkout/1'. The problem comes when setting the pages to display the block on. We need a way of telling the block to only show on the first checkout pages and not the others. How do we tell a block to only show on that page when the number is always changing? Something like 'checkout/*' will display on every sub-page like 'checkout/1/payment'. I'd like to be able to set a visibility setting like 'checkout/*/' but that doesn't work.
The easy solution is to use a drupal_goto within the commerce_checkout_progress_commerce_checkout_router() function. But that seems ugly to.
Comments
Comment #1
webmasterkai commentedThe thing is, it's just not actually that big of a deal.
commerce/modules/checkout/commerce_checkout.module line 13
commerce/modules/checkout/includes/commerce_checkout.pages.inc line 12
This module uses hook_init() to do the following
I don't really see how it's much different.
Comment #2
webmasterkai commentedIn talking with Andy T (thehong) we talked about setting the page visibility settings with "checkout/*" and then checking a variable for what pages NOT to display the block on within the
commerce_checkout_progress_block_view()function.Comment #3
thehong commentedFixed: http://drupalcode.org/sandbox/webmasterkai/1291268.git/commit/883c88b
Comment #4
thehong commentedComment #5
webmasterkai commentedEverything is working well for me. I removed the redirect via drupal_goto().