Захват значения HTML-тега в smarty
Im not so good in smarty so I need help, When I submit this form using ajax : <form accept-charset="UTF-8" method="post" onSubmit="return validate()"> <input type="text" name="code" maxlength="15" class="input-text" id="code" value="" placeholder="code"> <input type="submit" class="button-alt-gray top1px" name="code" value="Apply" onClick="search_code()"> <br> </form> <div id="cool_number" /> this `<div id="cool_number" />` gives me (prints on screen) a value lets say 10 and I want to pass or capture this value to a an smarty tag , I tried this: does not work {$p.total = "<div id="cool_number" />"} does not work {$p.total = "<div id='cool_number' />"} does not work {$p.total = "<div id=\"cool_number\" />\n"}
Что я уже пробовал:
Я попробовал это:
не действовать
{$p. total = "& lt;div id= "cool_number" />"}
не действовать
{$p. total = "& lt;div id= 'cool_number' />"}
не действовать
{$p. total = "& lt;div id=\ "cool_number\" />\n"}