How to escape single quote in SQL?

I’m using the Page_Unload in list page and insert some user date between table so it fills in First, Last, Email Address etc.I have a variable$FIRST_NAME = CurrentUserInfo(“first_name”);And insert it into another table. The problem is if user enter something like Mark’s or other single quotes.I tried $FIRST_NAME = mysqli_real_escape_string($FIRST_NAME); did not work.Is there something that PHPMaker can do to sanitize?Thank you

There are some tricks to do it, you may Google “php escape single quote”.

If you use v2024, you may simply use ORM.