Escape it with another %
:
$stringWithVariables="About to deduct 50%% of %s %s from your Top-Up account.";
More Related Contents:
- Prevent PHP parsing in strings [closed]
- Pass a PHP string to a JavaScript variable (and escape newlines) [duplicate]
- How to decode Unicode escape sequences like “\u00ed” to proper UTF-8 encoded characters?
- How to escape strings in SQL Server using PHP?
- Is there a PHP function that can escape regex patterns before they are applied?
- What does it mean to escape a string?
- Is mysql_real_escape_string() broken?
- Dollar ($) sign in password string treated as variable
- Escaping MySQL wild cards
- Escaping single quote in PHP when inserting into MySQL [duplicate]
- Why is PDO better for escaping MySQL queries/querystrings than mysql_real_escape_string?
- How to search for slash (\) in MySQL? and why escaping (\) not required for where (=) but for Like is required?
- Why are $_POST variables getting escaped in PHP?
- With “magic quotes” disabled, why does PHP/WordPress continue to auto-escape my POST data?
- How do I escape only single quotes?
- preg_replace: add number after backreference
- Rounding to nearest fraction (half, quarter, etc.)
- Escape string to use in mail()
- What literal characters should be escaped in a regex?
- PHP quotes inside quotes
- HTML,PHP – Escape ” symbols while echoing
- Do I need to escape backslashes in PHP?
- Pass a PHP variable to a JavaScript variable
- mysql_escape_string VS mysql_real_escape_string
- vsprintf or sprintf with named arguments, or simple template parsing in PHP
- Why use sprintf function in PHP?
- Why doesn’t sprintf() output anything?
- Escaping CURL @ symbol with PHP
- PHP: Escape RegEx pattern to prevent being applied?
- How to safely output HTML from a PHP program?