Subversion Repositories wpShopGermany4

Rev

Rev 7824 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1233 daniel 1
<?php
2
 
3
	/**
1623 daniel 4
	 * Template für die Integration der Produktvariablen in das Template
1233 daniel 5
	 */
6
 
7
?>
7849 daniel 8
 
1233 daniel 9
<div class="wpsg_mod_productvars">
10
	<?php foreach ($this->view['wpsg_mod_productvars']['data'] as $pv) { ?>
11
	<div class="wpsg_mod_productvars_row">
12
		<div class="wpsg_mod_productvars_label">
13
			<?php echo __($pv['name'], 'wpsg'); ?> <?php if ($pv['pflicht'] == '1') { ?><span class="wpsg_required">*</span><?php } ?>:
14
		</div>
15
		<div class="wpsg_mod_productvars_input">
16
			<?php if ($pv['typ'] == '1') { // Auswahlfeld ?>
17
			<select name="wpsg_mod_productvars[<?php echo $pv['id']; ?>]">
18
				<option value="not_set"><?php echo __('Bitte wählen', 'wpsg'); ?></option>
19
				<?php foreach ((array)$pv['auswahl'] as $option) { ?>
4889 daniel 20
				<option <?php echo ((wpsg_isSizedString($pv['value'], wpsg_hspc($option)))?'selected="selected"':''); ?> value="<?php echo wpsg_hspc($option); ?>"><?php echo wpsg_hspc($option); ?></option>
1233 daniel 21
				<?php } ?>
22
			</select>
23
			<?php } else if ($pv['typ'] == '2') { // Textfeld ?>
4889 daniel 24
			<input type="text" name="wpsg_mod_productvars[<?php echo $pv['id']; ?>]" value="<?php echo wpsg_hspc(wpsg_getStr($pv['value'])); ?>" />
1233 daniel 25
			<?php } else if ($pv['typ'] == '3') { // Checkbox ?>
26
			<input type="hidden" value="0" name="wpsg_mod_productvars[<?php echo $pv['id']; ?>]" />
4889 daniel 27
			<input <?php echo ((wpsg_isSizedString($pv['value'], '1'))?'checked="checked"':''); ?> type="checkbox" value="1" name="wpsg_mod_productvars[<?php echo $pv['id']; ?>]" />
7824 daniel 28
			<?php } else if ($pv['typ'] == '4') { // Mehrzeiliges Textfeld ?>
29
                <textarea rows="5" name="wpsg_mod_productvars[<?php echo $pv['id']; ?>]"><?php echo wpsg_hspc(wpsg_getStr($pv['value'])); ?></textarea>
30
            <?php } ?>
1233 daniel 31
		</div>
32
	</div>
33
	<?php } ?>
34
</div>