Inbox can't be displayed if sender ID contains "&"


we have a small problem with playsms and hope that you are able help us.

We are using playsms 1.3.1 (with smstools) only to receive texts, not send them. Its working very well, but we regularly get texts (SMS) from a certain company that uses a name instead of numbers as the sender id. In this case the name contains a & (e.g. M&M).

It looks like the “&” makes it impossible to view the complete inbox for this sender. The problem is that the "&"
is saved into the database unencoded (the original field value for playsms_tblSMSInbox.in_sender was "+M&M“ in our test case).

When we open the inbox page for M&M, the URL contains the unencoded "&“ for in_sender (e.g.: …&route=user_inbox&op=user_inbox&in_sender=%2BM&M) and fails to load texts for the user +M&M.

When I manually change the value of playsms_tblSMSInbox.in_sender in the playsms DB for one text message from +M&M to +M&M, the inbox loads the text message without any further problems.

This error only happens with texts, which where received by the smstools and then imported into the playsms database. The error doesn’t appear with simulated incoming sms texts.

Is this a bug in the import function? Or is there a configuration somewhere, that makes sure that the sender ID string doesn’t contain an unencoded „&“ before its being written into the database?

Thanks for your help!