| @@ 610-621 (lines=12) @@ | ||
| 607 | return tep_session_is_registered('OSCOM_Braintree_Alerts'); |
|
| 608 | } |
|
| 609 | ||
| 610 | function addAlert($message, $type) { |
|
| 611 | global $OSCOM_Braintree_Alerts; |
|
| 612 | ||
| 613 | if ( in_array($type, array('error', 'warning', 'success')) ) { |
|
| 614 | if ( !tep_session_is_registered('OSCOM_Braintree_Alerts') ) { |
|
| 615 | $OSCOM_Braintree_Alerts = array(); |
|
| 616 | tep_session_register('OSCOM_Braintree_Alerts'); |
|
| 617 | } |
|
| 618 | ||
| 619 | $OSCOM_Braintree_Alerts[$type][] = $message; |
|
| 620 | } |
|
| 621 | } |
|
| 622 | ||
| 623 | function getAlerts() { |
|
| 624 | global $OSCOM_Braintree_Alerts; |
|
| @@ 662-673 (lines=12) @@ | ||
| 659 | return tep_session_is_registered('OSCOM_PayPal_Alerts'); |
|
| 660 | } |
|
| 661 | ||
| 662 | function addAlert($message, $type) { |
|
| 663 | global $OSCOM_PayPal_Alerts; |
|
| 664 | ||
| 665 | if ( in_array($type, array('error', 'warning', 'success')) ) { |
|
| 666 | if ( !tep_session_is_registered('OSCOM_PayPal_Alerts') ) { |
|
| 667 | $OSCOM_PayPal_Alerts = array(); |
|
| 668 | tep_session_register('OSCOM_PayPal_Alerts'); |
|
| 669 | } |
|
| 670 | ||
| 671 | $OSCOM_PayPal_Alerts[$type][] = $message; |
|
| 672 | } |
|
| 673 | } |
|
| 674 | ||
| 675 | function getAlerts() { |
|
| 676 | global $OSCOM_PayPal_Alerts; |
|