I'm using sprintf()
in PHP but it displays nothing on the page.
Here's what I'm doing:
$lang['request_paragraph']="Please check your email for a message from %s (%s). This message contains instructions for initiating the issuance of a new password for your participant number. If you did not receive the email message from %s within 10-15 minutes, please make sure that your email provider does not have a spam filter that is blocking our email from reaching your Inbox. You will not be able to receive email from us if your email provider is using a mail-blocking device. Click on the button below to send the validation email again if it appears to have been blocked or never received. You will only be able to re-send the validation email 3 more times.";
$company="Company Name";
$admin_email="admin@company.com";
sprintf($lang['request_paragraph'],$company,$admin_email,$company);
Doing an echo
on each individual string displays each string correctly, so what am I doing wrong?
I need to use sprintf()
because I'm working with language files and it makes it much more simple than splitting the paragraph into pieces in the language definitions.