I have a language.inc
file which has a email template that looks like this:
$lang["email_templete"] = '
<style type="text/css">
*....more stylings here...*
</style>
<div>
<table>
*....more elements....*
%s
</table>
</div>
';
My problem is that whenever I'm trying to insert contents into my template using sprintf, it always hits the error "Too few arguments". I've tried removing all the excessive html codes and replaced it with a more simple html code and it works. Do you have any clue on this problem?
function add_to_email_template($pTargetEmail, $pSubject, $pContent) {
global $lang;
$vMessage = sprintf($lang["email_templete"], $pContent);
send_email($pTargetEmail, $pSubject, $vMessage);
}