I'm trying to pass a username with domain in PHP, and am having issues with backslashes either being completely stripped or "doubled up". I've tried a ton of different fixes, and nothing is working.
$domain = "domain";
$username = "username";
$adfs = stripslashes($domain.'\\'.$username);
$dynamicsClient = new dynamicsClient($adfs, $password, $URL, 1);
What I want as the end result is domain\username.
Seems simple enough, but because of escaping, I can't get this to work. I'm new to PHP, so there must be a fix.
Please help.