I have found a solution :     If the username for HC2 is "[email protected]" then the string defining username in php script has to be entered as    $username = "user%40mail.com"   simly @ had to replaced with %40