I am trying to get a specific company which has an ampersand in its name. The reqeust is being sent with mautic api-library to the companies endpoint with a custom query which looks something like this:
$qb = new QueryBuilder();
$qb->setSelect(“SELECT * FROM companies”);
$qb->addWhere($qb->expr()->eq(‘companyname’, “MY COMPANY & NAME”));
This works as intended as long as there is no ampsersand in the company name. The URL for the query gets encoded like this but does not return any matches even though it should:
Hello,
I am using curl.
First, I replace spaces with %20 in the name of the company.
I also tried to replace & with %26, but with no success. As long as the name doesn’t contain “&” it works perfectly.