{include file="$gentemplates/_header.tpl" pagetitle="$module"}
{include file="$gentemplates/_navi.tpl" pagetitle="$module"}

	<form name="form1" action="index.php" method="post" enctype="multipart/form-data">

	<input type="hidden" name="{$SESSIONNAME}" value="{$SESSIONID}">			
	<input type="hidden" name="module" value="{$modulename}">			
    <input type="hidden" name="option" value="{$optionname}">		
        
	<table border="0" cellpadding="0" cellspacing="0" width="100%">
		{foreach from=$moduleSettings item=curr_item key=curr_option}
           	{* dirty hack by kip *}	
           	{if ($curr_option|truncate:5:"")=="spacer"}
   				<tr><td class="formhead"><img src="{$imgpathmaster}/space.gif" alt="" width="50" height="{math equation="x / y" x=$curr_item y=2}" hspace="0" vspace="0" border="0"></td></tr>
            	<tr><td height="1" width="1" colspan="4" class="content"><img src="{$imgpathmaster}/space.gif" alt="" width="1" height="1" hspace="0" vspace="0" border="0"></td></tr>
                <tr><td class="formhead"><img src="{$imgpathmaster}/space.gif" alt="" width="50" height="{math equation="x / y" x=$curr_item y=2}" hspace="0" vspace="0" border="0"></td></tr>
                {assign var="lastItemWasSpacer" value=1}
            {else}
            	{if $lastItemWasSpacer!=1}
                	<tr><td class="lines" height="1" width="1" colspan="4"><img src="{$imgpathmaster}/space.gif" alt="" width="1" height="1" hspace="0" vspace="0" border="0"></td></tr>
    			{/if}
                {assign var="lastItemWasSpacer" value=0}
                <tr align="left">
                	<td width="100%" class="formhead">
                        <table border="0" cellpadding="6" cellspacing="0" width="100%">
                        	<tr valign="top">
                            	<td width="50" class="formhead"></td>
        						<td class="formhead" width="300">
                    				{$curr_item.optionName}:
                    			</td>
                    			<td class="formhead" width="280">
                                    {if $curr_item.layout eq 1}{assign var="lo" value=1}{else}{assign var="lo" value=0}{/if}
                   			    	{include file="input.tpl" data=$curr_item.optionChoices optionName=$curr_option method=$curr_item.optionMethod layout=$lo}
                                    {if $curr_item.optionMethod eq "multicheckbox"}
                                    	<input type="hidden" name="{$curr_option}_multi" value="1">
                                    {/if}
                    			</td>
        			            <td class="formhead">
                    				{$curr_item.optionNote}
                    			</td>
    							<td>&nbsp;&nbsp;&nbsp;</td>
        					</tr>
                    	</table>
                    </td>
    	        </tr>
  			{/if}
        {/foreach}
        <tr align="left">
			<td class="formhead" align="center">
            	<table border="0" cellspacing="4" cellpadding="0" width="150">
            		<tr>
                    	<td>
                        	<input type="submit" name="savesettings" value="{$save}" class="submit">
                        </td>
                        <td>
            				<a class="edit" href="index.php?{$SESSION}">{$abort}</a>
                        </td>
                    </tr>
                </table>
            </td>
		</tr>
	</table>
	
	</form>

{include file="$gentemplates/_footer.tpl" aktUser=$username}