Function __global->ecom_details_url

Definitions

sources/ecommerce.php

  • Generate a URL to view the details of an order / invoice / subscription.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: object

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$type_code ID_TEXT No No required parameter N/A N/A The product type code
$id ID_TEXT No No Blank (empty string) N/A N/A The ID to view (order ID for orders / catalogues, invoice ID for invoices, else transaction ID) (blank: no ID available, therefore do not link)
$member_id ?MEMBER No No Null N/A N/A The member viewing this (null: unknown)
$page_link ?ID_TEXT No No Null N/A N/A The page_link from which we are viewing (zone:page:type) (null: look it up)

Returns

  • The build_url Tempcode (null: no details link available)
  • Type: ?Tempcode
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Generate a URL to view the details of an order / invoice / subscription.
 *
 * @param  ID_TEXT $type_code The product type code
 * @param  ID_TEXT $id The ID to view (order ID for orders / catalogues, invoice ID for invoices, else transaction ID) (blank: no ID available, therefore do not link)
 * @param  ?MEMBER $member_id The member viewing this (null: unknown)
 * @param  ?ID_TEXT $page_link The page_link from which we are viewing (zone:page:type) (null: look it up)
 * @return ?Tempcode The build_url Tempcode (null: no details link available)
 */

function ecom_details_url(string $type_code, string $id = '', ?int $member_id = null, ?string $page_link = null) : ?object