Hallo,
Ich hab ein Problem.
Ich möchte 2 Funktionen zusammenfügen und komm nicht weiter.
Und zwar geht es um einen Begrüssungstext wenn sich der User Eingeloggt hat.
Jetzt möchte ich das Personengruppe x und Personengruppe Y, die jeweils unterschiedliche Loginbereiche haben mit der gleichen Anweisung:
	
Begrüsst werden.
Dazu muss ich folgenden Code Kombinieren.
1:
	
2:
	
Wäre froh wenn mir jemand helfen könnte.
Gruss
							
						
					Ich hab ein Problem.
Ich möchte 2 Funktionen zusammenfügen und komm nicht weiter.
Und zwar geht es um einen Begrüssungstext wenn sich der User Eingeloggt hat.
Jetzt möchte ich das Personengruppe x und Personengruppe Y, die jeweils unterschiedliche Loginbereiche haben mit der gleichen Anweisung:
PHP Code:
	
	
<?php echo tep_customer_greeting(); ?>
Dazu muss ich folgenden Code Kombinieren.
1:
PHP Code:
	
	
  function tep_customer_greeting() { 
    global $affiliate_id, $affiliate_first_name; 
    if (tep_session_is_registered('affiliate_first_name') && tep_session_is_registered('affiliate_id')) { 
      $greeting_string = sprintf(TEXT_GREETING_PERSONAL, tep_output_string_protected($affiliate_first_name), tep_href_link(FILENAME_PRODUCTS_NEW)); 
    } else { 
      $greeting_string = sprintf(TEXT_GREETING_GUEST, tep_href_link(FILENAME_LOGIN, '', 'SSL'), tep_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL')); 
    } 
    return $greeting_string; 
  } 
2:
PHP Code:
	
	
function tep_customer_greeting() { 
    global $customer_id, $customer_first_name; 
    if (tep_session_is_registered('customer_first_name') && tep_session_is_registered('affiliate_id')) { 
      $greeting_string = sprintf(TEXT_GREETING_PERSONAL, tep_output_string_protected($customer_first_name), tep_href_link(FILENAME_PRODUCTS_NEW)); 
    } else { 
      $greeting_string = sprintf(TEXT_GREETING_GUEST, tep_href_link(FILENAME_LOGIN, '', 'SSL'), tep_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL')); 
    } 
    return $greeting_string; 
  } 
Gruss
							
						
          

							
						
 
, aber recht haste ja.
Comment