Subversion Repositories wpShopGermany4

Rev

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

Rev Author Line No. Line
3444 daniel 1
<div class="wpsg_mod_shippingadress">
2
 
3
	<h2><?php echo __('Gesonderte Lieferadresse', 'wpsg'); ?></h2>
4
 
3460 daniel 5
	<div class="wpsg_spacer"></div>
6
 
2783 daniel 7
	<div class="wpsg_inner">
3444 daniel 8
 
9
		<div class="wpsg_checkoutblock">
10
			<label for="act_checkout_shippingadress">
5867 daniel 11
				<input id="act_checkout_shippingadress" class="wpsg_checkout formfield_checkbox" type="checkbox" name="wpsg[checkout][diff_shippingadress]" value="" <?php echo ((wpsg_isSizedInt($_SESSION['wpsg']['checkout']['diff_shippingadress']))?'checked="checked"':'') ?> onclick="view_checkout_shippingadresss()" />
3444 daniel 12
				<?php echo __('Gesonderte Lieferadresse abweichend von der Rechnungsadresse verwenden', 'wpsg') ?>
13
			</label>
2783 daniel 14
		</div>
1221 david 15
 
2791 daniel 16
		<div class="wpsg_clear"></div>
17
 
2783 daniel 18
		<div class="checkout_shippingadress" style="display:none;">
1221 david 19
 
6872 hartmut 20
			<?php if ($this->view['pflicht']['firma'] != '2') { ?>
2783 daniel 21
			<div class="wpsg_checkoutblock">
7361 thomas 22
				<label for="shipping_firma" class="wpsg_checkout"><?php echo __("Firma:", "wpsg"); ?>
6371 hartmut 23
					<?php if ($this->view['pflicht']['firma'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>
24
				</label>
25
				<input class="<?php echo (($this->view['pflicht']['firma'] != '1')?'validate[required]':''); ?> wpsg_checkout <?php echo ((in_array("name", (array)$this->view['error']))?'wpsg_error':''); ?>" type="text" id="shipping_name" name="wpsg[checkout][shipping_firma]" value="<?php echo wpsg_hspc(wpsg_getStr($this->view['basket']['checkout']['shipping_firma'])); ?>" />
2783 daniel 26
			</div>
6872 hartmut 27
			<?php } ?>
1221 david 28
 
6872 hartmut 29
			<?php if ($this->view['pflicht']['anrede'] != '2') { ?>
2783 daniel 30
			<div class="wpsg_checkoutblock">
7361 thomas 31
				<label for="shipping_title" class="wpsg_checkout"><?php echo __("Anrede:", "wpsg"); ?>
6371 hartmut 32
					<?php if ($this->view['pflicht']['anrede'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>
2783 daniel 33
				</label>
6371 hartmut 34
				<select class="<?php echo (($this->view['pflicht']['anrede'] != '1')?'validate[required_shipping]':''); ?> wpsg_checkout <?php echo ((in_array("title", (array)$this->view['error']))?'wpsg_error':''); ?>" type="select" id="shipping_title" name="wpsg[checkout][shipping_title]">
35
				<option value="-1"><?php echo __('Bitte auswählen', 'wpsg'); ?></option>
6107 hartmut 36
				<?php $i=0; foreach (explode("|", $this->view['pflicht']['anrede_auswahl']) as $t) { ?>
7987 daniel 37
				<option value="<?php echo $i; /*wpsg_hspc($t);*/ ?>" <?php echo ((($this->view['basket']['checkout']['shipping_title']??'') === strval($i))?'selected="selected"':''); ?>><?php echo $t; ?></option>
38
				<?php $i++; } ?>
2783 daniel 39
				</select>
40
			</div>
6872 hartmut 41
			<?php } ?>
2330 daniel 42
 
6872 hartmut 43
			<?php if ($this->view['pflicht']['vname'] != '2') { ?>
2783 daniel 44
			<div class="wpsg_checkoutblock">
7361 thomas 45
				<label for="shipping_vname" class="wpsg_checkout"><?php echo __("Vorname:", "wpsg"); ?>
6371 hartmut 46
					<?php if ($this->view['pflicht']['vname'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>
2783 daniel 47
				</label>
6371 hartmut 48
				<input class="<?php echo (($this->view['pflicht']['vname'] != '1')?'validate[required_shipping]':''); ?> wpsg_checkout <?php echo ((in_array("shipping_vname", (array)$this->view['error']))?'wpsg_error':''); ?>" type="text" id="shipping_vname" name="wpsg[checkout][shipping_vname]" value="<?php echo wpsg_hspc(wpsg_getStr($this->view['basket']['checkout']['shipping_vname'])); ?>" />
2783 daniel 49
			</div>
6872 hartmut 50
			<?php } ?>
2783 daniel 51
 
6872 hartmut 52
			<?php if ($this->view['pflicht']['name'] != '2') { ?>
2783 daniel 53
			<div class="wpsg_checkoutblock">
7361 thomas 54
				<label for="shipping_name" class="wpsg_checkout"><?php echo __("Name:", "wpsg"); ?>
6371 hartmut 55
					<?php if ($this->view['pflicht']['name'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>:
2783 daniel 56
				</label>
6371 hartmut 57
				<input class="<?php echo (($this->view['pflicht']['name'] != '1')?'validate[required_shipping]':''); ?> wpsg_checkout <?php echo ((in_array("shipping_name", (array)$this->view['error']))?'wpsg_error':''); ?>" type="text" id="shipping_name" name="wpsg[checkout][shipping_name]" value="<?php echo wpsg_hspc(wpsg_getStr($this->view['basket']['checkout']['shipping_name'])); ?>" />
2783 daniel 58
			</div>
6872 hartmut 59
			<?php } ?>
2783 daniel 60
 
6872 hartmut 61
			<?php if ($this->view['pflicht']['strasse'] != '2') { ?>
7247 daniel 62
 
63
				<?php if ($this->view['pflicht']['wpsg_showNr'] === '1') { ?>
64
 
65
					<div class="wpsg_checkoutblock" id="wpsg_streetnr">
7361 thomas 66
						<label for="shipping_strasse" class="street wpsg_checkout"><?php echo __('Straße:', 'wpsg'); ?>
7247 daniel 67
							<?php if ($this->view['pflicht']['strasse'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>
68
							<input class="<?php echo (($this->view['pflicht']['strasse'] != '1')?'validate[required_shipping]':''); ?> wpsg_checkout <?php echo ((in_array("shipping_strasse", (array)$this->view['error']))?'wpsg_error':''); ?>" type="text" id="shipping_strasse" name="wpsg[checkout][shipping_strasse]" value="<?php echo htmlspecialchars(wpsg_getStr($this->view['basket']['checkout']['shipping_strasse'])); ?>" />
69
						</label>
7361 thomas 70
						<label for="shipping_nr" class="nr wpsg_checkout"><?php echo __('Nr:', 'wpsg'); ?>
7247 daniel 71
							<?php if ($this->view['pflicht']['strasse'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>
72
							<input class="<?php echo (($this->view['pflicht']['strasse'] != '1')?'validate[required_shipping]':''); ?> wpsg_checkout <?php echo ((in_array("shipping_nr", (array)$this->view['error']))?'wpsg_error':''); ?>" type="text" id="shipping_nr" name="wpsg[checkout][shipping_nr]" value="<?php echo htmlspecialchars(wpsg_getStr($this->view['basket']['checkout']['shipping_nr'])); ?>" />
73
						</label>
74
					</div>
75
 
76
				<?php } else { ?>
77
 
78
					<div class="wpsg_checkoutblock">
7361 thomas 79
						<label for="shipping_strasse" class="wpsg_checkout"><?php echo __("Straße, Nr.:", "wpsg"); ?>
7247 daniel 80
							<?php if ($this->view['pflicht']['strasse'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>
81
						</label>
82
						<input class="<?php echo (($this->view['pflicht']['strasse'] != '1')?'validate[required_shipping]':''); ?> wpsg_checkout <?php echo ((in_array("shipping_strasse", (array)$this->view['error']))?'wpsg_error':''); ?>" type="text" id="shipping_strasse" name="wpsg[checkout][shipping_strasse]" value="<?php echo wpsg_hspc(wpsg_getStr($this->view['basket']['checkout']['shipping_strasse'])); ?>" />
83
					</div>
84
 
85
				<?php } ?>
86
 
6872 hartmut 87
			<?php } ?>
7247 daniel 88
 
6872 hartmut 89
			<?php if ($this->view['pflicht']['plz'] != '2') { ?>
2783 daniel 90
			<div class="wpsg_checkoutblock">
7361 thomas 91
				<label for="shipping_plz" class="wpsg_checkout"><?php echo __("Postleitzahl:", "wpsg"); ?>
6371 hartmut 92
					<?php if ($this->view['pflicht']['plz'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>
2783 daniel 93
				</label>
6371 hartmut 94
				<input class="<?php echo (($this->view['pflicht']['plz'] != '1')?'validate[required_shipping]':''); ?> wpsg_checkout <?php echo ((in_array("shipping_plz", (array)$this->view['error']))?'wpsg_error':''); ?>" type="text" id="shipping_plz" name="wpsg[checkout][shipping_plz]" value="<?php echo wpsg_hspc(wpsg_getStr($this->view['basket']['checkout']['shipping_plz'])); ?>" />
2783 daniel 95
			</div>
6872 hartmut 96
			<?php } ?>
2783 daniel 97
 
6872 hartmut 98
			<?php if ($this->view['pflicht']['ort'] != '2') { ?>
2783 daniel 99
			<div class="wpsg_checkoutblock">
7361 thomas 100
				<label for="shipping_ort" class="wpshopgermany_checkout"><?php echo __("Ort:", "wpsg"); ?>
6371 hartmut 101
					<?php if ($this->view['pflicht']['ort'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>
2783 daniel 102
				</label>
6371 hartmut 103
				<input class="<?php echo (($this->view['pflicht']['ort'] != '1')?'validate[required_shipping]':''); ?> wpsg_checkout <?php echo ((in_array("shipping_ort", (array)$this->view['error']))?'wpsg_error':''); ?>" type="text" id="shipping_ort" name="wpsg[checkout][shipping_ort]" value="<?php echo wpsg_hspc(wpsg_getStr($this->view['basket']['checkout']['shipping_ort'])); ?>" />
2783 daniel 104
			</div>
6872 hartmut 105
			<?php } ?>
2783 daniel 106
 
6872 hartmut 107
			<?php if ($this->view['pflicht']['land'] != '2') { ?>
2783 daniel 108
			<div class="wpsg_checkoutblock">
6803 hartmut 109
				<label for="shipping_land" class="wpsg_checkout"><?php echo __("Land:", "wpsg"); ?>
6371 hartmut 110
					<?php if ($this->view['pflicht']['land'] != '1') { ?><span class="wpsg_required">*</span><?php } ?>
7253 daniel 111
				</label>
6371 hartmut 112
				<select name="wpsg[checkout][shipping_land]" class="<?php echo (($this->view['pflicht']['land'] != '1')?'validate[required_shipping]':''); ?> wpsg_checkout <?php echo ((in_array("shipping_land", (array)$this->view['error']))?'wpsg_error':''); ?>" id="shipping_land">
2783 daniel 113
					<option value="-1"><?php echo __('Bitte auswählen', 'wpsg'); ?></option>
114
					<?php foreach ($this->view['laender'] as $l) { ?>
115
					<option value="<?php echo $l['id']; ?>" <?php echo (($l['id'] == $this->view['basket']['checkout']['shipping_land'])?'selected="selected"':''); ?>><?php echo wpsg_hspc($l['name']); ?></option>
116
					<?php } ?>
117
				</select>
118
			</div>
6872 hartmut 119
			<?php } ?>
2783 daniel 120
 
121
			<script type="text/javascript">/* <![CDATA[ */
122
 
123
				function view_checkout_shippingadresss()
124
				{
3224 daniel 125
 
126
					if (jQuery('#act_checkout_shippingadress').prop('checked') != true)
2783 daniel 127
					{
2791 daniel 128
 
2783 daniel 129
						jQuery('.checkout_shippingadress').attr('style', 'display:none;');
130
						jQuery('#act_checkout_shippingadress').attr('value', null);
2791 daniel 131
 
132
						<?php if ($this->get_option('wpsg_form_validation') == '2') { ?>
133
						jQuery.validator.removeClassRules('validate[required_shipping]', { cRequired: true } );
134
						<?php } ?>
135
 
2783 daniel 136
					}
2330 daniel 137
 
3224 daniel 138
					if (jQuery('#act_checkout_shippingadress').prop('checked') == true)
2783 daniel 139
					{
2791 daniel 140
 
2783 daniel 141
						jQuery('.checkout_shippingadress').attr('style', 'display:display;');
142
						jQuery('#act_checkout_shippingadress').attr('value', 1);
2791 daniel 143
 
144
						<?php if ($this->get_option('wpsg_form_validation') == '2') { ?>
145
						jQuery.validator.addClassRules('validate[required_shipping]', { cRequired: true } );
146
						<?php } ?>
147
 
2783 daniel 148
					}
149
 
150
					return false;
151
 
152
				}
1221 david 153
 
2783 daniel 154
				jQuery(document).ready(function()
155
				{
156
 
157
					view_checkout_shippingadresss();
6803 hartmut 158
 
7253 daniel 159
					land = <?php if (wpsg_isSizedInt($this->view['basket']['checkout']['shipping_land'])) echo $this->view['basket']['checkout']['shipping_land'];
6803 hartmut 160
					else echo $this->get_option('wpsg_defaultland'); ?>;
161
					jQuery('#shipping_land').val(land);
2783 daniel 162
 
163
				});
164
 
165
			/* ]]> */</script>
166
		</div>
167
	</div>
1221 david 168
</div>