Sostituisci:

Codice PHP:
...
$p = (string) $a->ns2:HotelListResponse->customerSessionId
... 
con:

Codice PHP:
...
$p $a->customerSessionId
...