Smarty Forum Index Smarty
The discussions here are for Smarty, a template engine for the PHP programming language.

smarty with javascript display

 
Post new topic   Reply to topic    Smarty Forum Index -> Help Wanted (commercial)
View previous topic :: View next topic  
Author Message
jerrystar
Smarty n00b


Joined: 16 May 2009
Posts: 3

PostPosted: Wed Jul 22, 2009 12:19 pm    Post subject: smarty with javascript display Reply with quote

Hi

I am using the smarty tag

{html_select_date prefix="yocDate" time=$TIME start_year="-50" display_days=false}

to display the year and month, I want to display this field dynamically ,so using javascript i called this function as

val = '<td>{html_select_date prefix="yocDate" time=$TIME start_year="-50" display_days=false}</td>';


document.getElementById('divTable').innerHTML = val;


while using this i am getting same sentence as output

{html_select_date prefix="yocDate" time=$TIME start_year="-50" display_days=false}

how to call this function from javascript any help

thanks in advance...
Back to top
View user's profile Send private message
mohrt
Administrator


Joined: 16 Apr 2003
Posts: 7368
Location: Lincoln Nebraska, USA

PostPosted: Thu Jul 23, 2009 3:56 am    Post subject: Reply with quote

smarty is server side, javascript is client side. There is no smarty once the html is rendered to the browser. you would have to go back to the server to get something created with smarty.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Smarty Forum Index -> Help Wanted (commercial) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP