now with pepe($host,$user....) the
function works perfectly.
By the way . . .
I would tend not to put that in each file, but rather have the login details (host,user,pass) in your common.inc or another file.
Reasons:
1) normailisation, updating password only dneeds be done in one place!
2) SECURITY ! ! ! If someone else updates your webpage or such, they will have access to this info.
IF your server allows shall access (SSH or Telnet) then other users will possibly be able to read the file as it has to be chmod world readable to be displayed over the internet.
Conclusion:
PUT THE LOGIN INFO IN A SEPARATE FILE WHICH YOU DO NOT GIVE OTHERS ACCESS TO!
All the best,
Tim