Difference between revisions of "VbzCart/v1/class/vcPageContent ckout/RenderContent"

from HTYP, the free directory anyone can edit if they can prove to me that they're not a spambot
Jump to navigation Jump to search
(Created page with "{{page/code/class/method}} ==Call Chains== * {{l/version/method|vcPageContent_ckout|Render}}() [public, events system] calls... ** {{hilite|{{l/version/method|vcPageContent_ck...")
(No difference)

Revision as of 20:41, 21 April 2019

Call Chains

Code

    /*----
      ACTION: 
      OUTPUT:
	$doBackBtn: if TRUE, show the BACK navigation button
	$doRefrBtn:
	$doNavCtrl:
    */
    protected function RenderContent() {
	$out = NULL;
	$this->SetShowNavigation(TRUE);	// default
	//$doNav = TRUE;

	$sKeyShow = $this->GetPageKey_forShow();
	switch ($sKeyShow) {
	  case KSQ_PAGE_CART:	// shopping cart
	    $this->SetShowBackButton(FALSE);
	    $this->SetShowRefreshButton(TRUE);
	    $htMain = $this->RenderCart();
	    break;
	  case KSQ_PAGE_SHIP:	// shipping information
	    $htMain = $this->RenderShippingPage();
	    break;
	  case KSQ_PAGE_PAY:	// billing information
	    $htMain = $this->RenderBillingPage();
	    break;
	  case KSQ_PAGE_CONF:	// confirm order
	    $this->SetShowNavigation(FALSE);
	    //$doNav = FALSE;
	    $htMain = $this->RenderConfirm();
	    break;
	  case KSQ_PAGE_RCPT:	// order receipt
	    $this->SetShowNavigation(FALSE);
	    //$doNav = FALSE;
	    $this->ReceiveOrder();		// mark order as received
	    $htMain = $this->RenderReceipt();	// display receipt & send by email
	    break;
	  default:
// The normal shopping cart does not specify a target within the checkout sequence
// ...so show the first page which follows the cart page:
	    $htMain = $this->RenderShippingPage();
	}
	
	//$htNavStatus = $this->RenderNavigationStatus();
	
	$out =
	  $this->RenderContentHeader()
	  //.$htNavStatus
	  .$htMain
	  //.$htNavButtons
	  .$this->RenderContentFooter()
	  ;
	return $out;
    }