Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

Smarty Loop post value to input box,

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> General
View previous topic :: View next topic  
Author Message
anandlall12
Smarty Rookie


Joined: 05 Mar 2014
Posts: 8

PostPosted: Wed Mar 05, 2014 3:31 pm    Post subject: Smarty Loop post value to input box, Reply with quote

Hi Everyone, I am new to smarty and learning everyday as I go by. currently I am having a small problem and not sure if one of you pros can help me. I have a loop in my tpl file, I created a onclick even that toggles a form when I click no any row. how can I get the ID of the row into an hidden input box so I can post it to MYSQL.

this is what my code looks like.\

{section name=w loop=$test}
<tr>
<td class="menu1" align="center">{$test[w].ID}</td>
<td class="menu1" align="center">{$test[w].FIRST_NAME}</td>
<td class="menu1" align="center">{$test[w].LAST_NAME}</td>
<td class="menu1" align="center">{$test[w].GENDER}</td>
<td class="menu1" align="center"><a href="#" onclick="showOrderform('2');">Select</a></td>
{/section}

Thanks in advance
Back to top
View user's profile Send private message
anandlall12
Smarty Rookie


Joined: 05 Mar 2014
Posts: 8

PostPosted: Fri Mar 07, 2014 2:02 pm    Post subject: got it figured out Reply with quote

Used javascript tp get this working
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> General 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