Completed
Branch FET-9707-scroll-to-ticket-sele... (81b79f)
by
unknown
107:16 queued 91:01
created
modules/ticket_selector/templates/ticket_selector_chart.template.php 1 patch
Spacing   +144 added lines, -144 removed lines patch added patch discarded remove patch
@@ -8,34 +8,34 @@  discard block
 block discarded – undo
8 8
 
9 9
 $row = 1;
10 10
 $max = 1;
11
-$ticket_count = count( $tickets );
11
+$ticket_count = count($tickets);
12 12
 
13
-if ( ! $ticket_count ) {
13
+if ( ! $ticket_count) {
14 14
 	return;
15 15
 }
16 16
 
17 17
 $required_ticket_sold_out = FALSE;
18
-$template_settings = isset ( EE_Registry::instance()->CFG->template_settings->EED_Ticket_Selector )
18
+$template_settings = isset (EE_Registry::instance()->CFG->template_settings->EED_Ticket_Selector)
19 19
 	? EE_Registry::instance()->CFG->template_settings->EED_Ticket_Selector
20 20
 	: new EE_Ticket_Selector_Config();
21 21
 
22 22
 ob_start();
23 23
 
24
-foreach ( $tickets as $TKT_ID => $ticket ) {
25
-	if ( $ticket instanceof EE_Ticket ) {
24
+foreach ($tickets as $TKT_ID => $ticket) {
25
+	if ($ticket instanceof EE_Ticket) {
26 26
 		$max = $ticket->max();
27 27
 		$min = 0;
28 28
 		$remaining = $ticket->remaining();
29
-		if ( $ticket->is_on_sale() && $ticket->is_remaining() ) {
29
+		if ($ticket->is_on_sale() && $ticket->is_remaining()) {
30 30
 			// offer the number of $tickets_remaining or $max_atndz, whichever is smaller
31
-			$max = min( $remaining, $max_atndz );
31
+			$max = min($remaining, $max_atndz);
32 32
 			// but... we also want to restrict the number of tickets by the ticket max setting,
33 33
 			// however, the max still can't be higher than what was just set above
34
-			$max = $ticket->max() > 0 ? min( $ticket->max(), $max ) : $max;
34
+			$max = $ticket->max() > 0 ? min($ticket->max(), $max) : $max;
35 35
 			// and we also want to restrict the minimum number of tickets by the ticket min setting
36 36
 			$min = $ticket->min() > 0 ? $ticket->min() : 0;
37 37
 			// and if the ticket is required, then make sure that min qty is at least 1
38
-			$min = $ticket->required() ? max( $min, 1 ) : $min;
38
+			$min = $ticket->required() ? max($min, 1) : $min;
39 39
 		} else {
40 40
 			// set flag if ticket is required (flag is set to start date so that future tickets are not blocked)
41 41
 			$required_ticket_sold_out = $ticket->required() && ! $remaining ? $ticket->start_date() : $required_ticket_sold_out;
@@ -44,41 +44,41 @@  discard block
 block discarded – undo
44 44
 		$ticket_price = $ticket->get_ticket_total_with_taxes();
45 45
 		$ticket_bundle = FALSE;
46 46
 		// for ticket bundles, set min and max qty the same
47
-		if ( $ticket->min() != 0 && $ticket->min() == $ticket->max() ) {
47
+		if ($ticket->min() != 0 && $ticket->min() == $ticket->max()) {
48 48
 			$ticket_price = $ticket_price * $ticket->min();
49 49
 			$ticket_bundle = TRUE;
50 50
 		}
51
-		$ticket_price = apply_filters( 'FHEE__ticket_selector_chart_template__ticket_price', $ticket_price, $ticket );
51
+		$ticket_price = apply_filters('FHEE__ticket_selector_chart_template__ticket_price', $ticket_price, $ticket);
52 52
 		// if a previous required ticket with the same sale start date is sold out, then mark this ticket as sold out as well.
53 53
 		// tickets that go on sale at a later date than the required ticket  will NOT be affected
54 54
 		$tkt_status = $required_ticket_sold_out !== FALSE && $required_ticket_sold_out === $ticket->start_date() ? EE_Ticket::sold_out : $ticket->ticket_status();
55 55
 		$tkt_status = $event_status === EE_Datetime::sold_out ? EE_Ticket::sold_out : $tkt_status;
56 56
 		// check ticket status
57
-		switch ( $tkt_status ) {
57
+		switch ($tkt_status) {
58 58
 			// sold_out
59 59
 			case EE_Ticket::sold_out :
60
-				$ticket_status = '<span class="ticket-sales-sold-out">' . $ticket->ticket_status( TRUE ) . '</span>';
60
+				$ticket_status = '<span class="ticket-sales-sold-out">'.$ticket->ticket_status(TRUE).'</span>';
61 61
 				$status_class = 'ticket-sales-sold-out lt-grey-text';
62 62
 			break;
63 63
 			// expired
64 64
 			case EE_Ticket::expired :
65
-				$ticket_status = '<span class="ticket-sales-expired">' . $ticket->ticket_status( TRUE ) . '</span>';
65
+				$ticket_status = '<span class="ticket-sales-expired">'.$ticket->ticket_status(TRUE).'</span>';
66 66
 				$status_class = 'ticket-sales-expired lt-grey-text';
67 67
 			break;
68 68
 			// archived
69 69
 			case EE_Ticket::archived :
70
-				$ticket_status = '<span class="archived-ticket">' . $ticket->ticket_status( TRUE ) . '</span>';
70
+				$ticket_status = '<span class="archived-ticket">'.$ticket->ticket_status(TRUE).'</span>';
71 71
 				$status_class = 'archived-ticket hidden';
72 72
 			break;
73 73
 			// pending
74 74
 			case EE_Ticket::pending :
75
-				$ticket_status = '<span class="ticket-pending">' . $ticket->ticket_status( TRUE ) . '</span>';
75
+				$ticket_status = '<span class="ticket-pending">'.$ticket->ticket_status(TRUE).'</span>';
76 76
 				$status_class = 'ticket-pending';
77 77
 			break;
78 78
 			// onsale
79 79
 			case EE_Ticket::onsale :
80 80
 			default :
81
-				$ticket_status = '<span class="ticket-on-sale">' . $ticket->ticket_status( TRUE ) . '</span>';
81
+				$ticket_status = '<span class="ticket-on-sale">'.$ticket->ticket_status(TRUE).'</span>';
82 82
 				$status_class = 'ticket-on-sale';
83 83
 			break;
84 84
 		}
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
             "tckt-slctr-tkt-details-{$EVT_ID}-{$TKT_ID}"
119 119
         );
120 120
 	?>
121
-				<tr class="tckt-slctr-tbl-tr <?php echo $status_class . ' ' . espresso_get_object_css_class( $ticket ); ?>">
121
+				<tr class="tckt-slctr-tbl-tr <?php echo $status_class.' '.espresso_get_object_css_class($ticket); ?>">
122 122
 		<?php
123 123
 		/**
124 124
 		 * Allow plugins to hook in and abort the generation and display of the contents of this
@@ -130,24 +130,24 @@  discard block
 block discarded – undo
130 130
 		 *
131 131
 		 * @var string|bool
132 132
 		 */
133
-		if ( false !== ( $new_row_cells_content = apply_filters( 'FHEE__ticket_selector_chart_template__do_ticket_inside_row', false, $ticket, $max, $min, $required_ticket_sold_out, $ticket_price, $ticket_bundle, $ticket_status, $status_class ) ) ) {
133
+		if (false !== ($new_row_cells_content = apply_filters('FHEE__ticket_selector_chart_template__do_ticket_inside_row', false, $ticket, $max, $min, $required_ticket_sold_out, $ticket_price, $ticket_bundle, $ticket_status, $status_class))) {
134 134
 			echo $new_row_cells_content;
135 135
 			echo '</tr>';
136 136
 			continue;
137 137
 		}
138 138
 		?>
139 139
 					<td class="tckt-slctr-tbl-td-name">
140
-						<b><?php echo $ticket->get_pretty('TKT_name');?></b>
141
-						<?php if ( $template_settings->show_ticket_details ) : ?>
142
-							<a id="display-<?php echo $ticket_details_css_id; ?>" class="display-tckt-slctr-tkt-details display-the-hidden lt-grey-text smaller-text hide-if-no-js" rel="<?php echo $ticket_details_css_id; ?>" title="<?php echo esc_attr( apply_filters( 'FHEE__ticket_selector_chart_template__show_ticket_details_link_title', __( 'click to show additional ticket details', 'event_espresso' )) ); ?>">
143
-								<?php echo sprintf( __( 'show%1$sdetails%1$s+', 'event_espresso' ), '&nbsp;' ); ?>
140
+						<b><?php echo $ticket->get_pretty('TKT_name'); ?></b>
141
+						<?php if ($template_settings->show_ticket_details) : ?>
142
+							<a id="display-<?php echo $ticket_details_css_id; ?>" class="display-tckt-slctr-tkt-details display-the-hidden lt-grey-text smaller-text hide-if-no-js" rel="<?php echo $ticket_details_css_id; ?>" title="<?php echo esc_attr(apply_filters('FHEE__ticket_selector_chart_template__show_ticket_details_link_title', __('click to show additional ticket details', 'event_espresso'))); ?>">
143
+								<?php echo sprintf(__('show%1$sdetails%1$s+', 'event_espresso'), '&nbsp;'); ?>
144 144
 							</a>
145
-							<a id="hide-<?php echo $ticket_details_css_id; ?>" class="hide-tckt-slctr-tkt-details hide-the-displayed lt-grey-text smaller-text hide-if-no-js" rel="<?php echo $ticket_details_css_id; ?>" title="<?php echo esc_attr( apply_filters( 'FHEE__ticket_selector_chart_template__hide_ticket_details_link_title', __( 'click to hide additional ticket details', 'event_espresso' )) ); ?>" style="display:none;">
146
-								<?php echo sprintf( __( 'hide%1$sdetails%1$s-', 'event_espresso' ), '&nbsp;' ); ?>
145
+							<a id="hide-<?php echo $ticket_details_css_id; ?>" class="hide-tckt-slctr-tkt-details hide-the-displayed lt-grey-text smaller-text hide-if-no-js" rel="<?php echo $ticket_details_css_id; ?>" title="<?php echo esc_attr(apply_filters('FHEE__ticket_selector_chart_template__hide_ticket_details_link_title', __('click to hide additional ticket details', 'event_espresso'))); ?>" style="display:none;">
146
+								<?php echo sprintf(__('hide%1$sdetails%1$s-', 'event_espresso'), '&nbsp;'); ?>
147 147
 							</a>
148 148
 						<?php endif; //end show details check ?>
149
-					<?php if ( $ticket->required() ) { ?>
150
-						<p class="ticket-required-pg"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_required_message', __( 'This ticket is required and must be purchased.', 'event_espresso' )); ?></p>
149
+					<?php if ($ticket->required()) { ?>
150
+						<p class="ticket-required-pg"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_required_message', __('This ticket is required and must be purchased.', 'event_espresso')); ?></p>
151 151
 					<?php } ?>
152 152
 					<?php
153 153
 //	echo '<br/><b>$max_atndz : ' . $max_atndz . '</b>';
@@ -161,63 +161,63 @@  discard block
 block discarded – undo
161 161
 //	echo '<br/><b> $ticket->required() : ' .  $ticket->uses() . '</b>';
162 162
 					?>
163 163
 					</td>
164
-					<?php if ( apply_filters( 'FHEE__ticket_selector_chart_template__display_ticket_price_details', TRUE )) { ?>
165
-					<td class="tckt-slctr-tbl-td-price jst-rght"><?php echo EEH_Template::format_currency( $ticket_price ); ?>&nbsp;<span class="smaller-text no-bold"><?php
166
-						if ( $ticket_bundle ) {
167
-							echo apply_filters( 'FHEE__ticket_selector_chart_template__per_ticket_bundle_text', __( ' / bundle', 'event_espresso' ));
164
+					<?php if (apply_filters('FHEE__ticket_selector_chart_template__display_ticket_price_details', TRUE)) { ?>
165
+					<td class="tckt-slctr-tbl-td-price jst-rght"><?php echo EEH_Template::format_currency($ticket_price); ?>&nbsp;<span class="smaller-text no-bold"><?php
166
+						if ($ticket_bundle) {
167
+							echo apply_filters('FHEE__ticket_selector_chart_template__per_ticket_bundle_text', __(' / bundle', 'event_espresso'));
168 168
 						} else {
169
-							echo apply_filters( 'FHEE__ticket_selector_chart_template__per_ticket_text', __( '', 'event_espresso' ));
169
+							echo apply_filters('FHEE__ticket_selector_chart_template__per_ticket_text', __('', 'event_espresso'));
170 170
 						}?></span>&nbsp;</td>
171 171
 					<?php } ?>
172 172
 					<td class="tckt-slctr-tbl-td-qty cntr">
173 173
 					<?php
174 174
 					$hidden_input_qty = $max_atndz > 1 ? TRUE : FALSE;
175 175
 					// sold out or other status ?
176
-					if ( $tkt_status == EE_Ticket::sold_out || $remaining == 0 ) {
176
+					if ($tkt_status == EE_Ticket::sold_out || $remaining == 0) {
177 177
 					?>
178
-						<span class="sold-out"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_sold_out_msg', __( 'Sold&nbsp;Out', 'event_espresso' ));?></span>
178
+						<span class="sold-out"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_sold_out_msg', __('Sold&nbsp;Out', 'event_espresso')); ?></span>
179 179
 					<?php
180
-					} else if ( $tkt_status == EE_Ticket::expired || $tkt_status == EE_Ticket::archived ) {
180
+					} else if ($tkt_status == EE_Ticket::expired || $tkt_status == EE_Ticket::archived) {
181 181
 						echo $ticket_status;
182
-					} else if ( $tkt_status == EE_Ticket::pending ) {
182
+					} else if ($tkt_status == EE_Ticket::pending) {
183 183
 					?>
184 184
 					<div class="ticket-pending-pg">
185
-						<span class="ticket-pending"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_goes_on_sale_msg', __( 'Goes&nbsp;On&nbsp;Sale', 'event_espresso' )); ?></span><br/>
186
-						<span class="small-text"><?php echo $ticket->get_i18n_datetime( 'TKT_start_date', apply_filters( 'FHEE__EED_Ticket_Selector__display_goes_on_sale__date_format', $date_format ) ); ?></span>
185
+						<span class="ticket-pending"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_goes_on_sale_msg', __('Goes&nbsp;On&nbsp;Sale', 'event_espresso')); ?></span><br/>
186
+						<span class="small-text"><?php echo $ticket->get_i18n_datetime('TKT_start_date', apply_filters('FHEE__EED_Ticket_Selector__display_goes_on_sale__date_format', $date_format)); ?></span>
187 187
 					</div>
188 188
 					<?php
189 189
 					// min qty purchasable is less than tickets available
190
-					} else if ( $ticket->min() > $remaining ) {
190
+					} else if ($ticket->min() > $remaining) {
191 191
 					?>
192 192
 					<div class="archived-ticket-pg">
193
-						<span class="archived-ticket small-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_not_available_msg', __( 'Not Available', 'event_espresso' )); ?></span><br/>
193
+						<span class="archived-ticket small-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_not_available_msg', __('Not Available', 'event_espresso')); ?></span><br/>
194 194
 					</div>
195 195
 					<?php
196 196
 					// if only one attendee is allowed to register at a time
197
-					} else if ( $max_atndz  == 1 ) {
197
+					} else if ($max_atndz == 1) {
198 198
 						// display submit button since we have tickets available
199
-						add_filter( 'FHEE__EE_Ticket_Selector__display_ticket_selector_submit', '__return_true' );
199
+						add_filter('FHEE__EE_Ticket_Selector__display_ticket_selector_submit', '__return_true');
200 200
 				?>
201
-					<input type="radio" name="tkt-slctr-qty-<?php echo $EVT_ID; ?>" id="ticket-selector-tbl-qty-slct-<?php echo $EVT_ID . '-' . $row; ?>" class="ticket-selector-tbl-qty-slct" value="<?php echo $row . '-'; ?>1" <?php echo $row == 1 ? ' checked="checked"' : ''; ?>  title=""/>
201
+					<input type="radio" name="tkt-slctr-qty-<?php echo $EVT_ID; ?>" id="ticket-selector-tbl-qty-slct-<?php echo $EVT_ID.'-'.$row; ?>" class="ticket-selector-tbl-qty-slct" value="<?php echo $row.'-'; ?>1" <?php echo $row == 1 ? ' checked="checked"' : ''; ?>  title=""/>
202 202
 			<?php
203 203
 						$hidden_input_qty = FALSE;
204 204
 
205
-					} else if ( $max_atndz  == 0 ) {
206
-						echo '<span class="sold-out">' . apply_filters( 'FHEE__ticket_selector_chart_template__ticket_closed_msg', __( 'Closed', 'event_espresso' )) . '</span>';
207
-					} elseif ( $max > 0 ) {
205
+					} else if ($max_atndz == 0) {
206
+						echo '<span class="sold-out">'.apply_filters('FHEE__ticket_selector_chart_template__ticket_closed_msg', __('Closed', 'event_espresso')).'</span>';
207
+					} elseif ($max > 0) {
208 208
 						// display submit button since we have tickets available
209
-						add_filter( 'FHEE__EE_Ticket_Selector__display_ticket_selector_submit', '__return_true' );
209
+						add_filter('FHEE__EE_Ticket_Selector__display_ticket_selector_submit', '__return_true');
210 210
 
211 211
 				?>
212
-					<select name="tkt-slctr-qty-<?php echo $EVT_ID; ?>[]" id="ticket-selector-tbl-qty-slct-<?php echo $EVT_ID . '-' . $row; ?>" class="ticket-selector-tbl-qty-slct" title="">
212
+					<select name="tkt-slctr-qty-<?php echo $EVT_ID; ?>[]" id="ticket-selector-tbl-qty-slct-<?php echo $EVT_ID.'-'.$row; ?>" class="ticket-selector-tbl-qty-slct" title="">
213 213
 					<?php
214 214
 						// this ensures that non-required tickets with non-zero MIN QTYs don't HAVE to be purchased
215
-						if ( ! $ticket->required() && $min !== 0 ) {
215
+						if ( ! $ticket->required() && $min !== 0) {
216 216
 					?>
217 217
 						<option value="0">&nbsp;0&nbsp;</option>
218 218
 					<?php }
219 219
 						// offer ticket quantities from the min to the max
220
-						for ( $i = $min; $i <= $max; $i++) {
220
+						for ($i = $min; $i <= $max; $i++) {
221 221
 					?>
222 222
 						<option value="<?php echo $i; ?>">&nbsp;<?php echo $i; ?>&nbsp;</option>
223 223
 					<?php } ?>
@@ -227,7 +227,7 @@  discard block
 block discarded – undo
227 227
 
228 228
 					}
229 229
 					// depending on group reg we need to change the format for qty
230
-					if ( $hidden_input_qty ) {
230
+					if ($hidden_input_qty) {
231 231
 					?>
232 232
 					<input type="hidden" name="tkt-slctr-qty-<?php echo $EVT_ID; ?>[]" value="0" />
233 233
 					<?php
@@ -237,33 +237,33 @@  discard block
 block discarded – undo
237 237
 
238 238
 					</td>
239 239
 				</tr>
240
-				<?php if ( $template_settings->show_ticket_details ) : ?>
241
-					<tr class="tckt-slctr-tkt-details-tr <?php echo espresso_get_object_css_class( $ticket, '', 'details' );?>">
240
+				<?php if ($template_settings->show_ticket_details) : ?>
241
+					<tr class="tckt-slctr-tkt-details-tr <?php echo espresso_get_object_css_class($ticket, '', 'details'); ?>">
242 242
 						<td class="tckt-slctr-tkt-details-td" colspan="3" >
243 243
 							<div id="<?php echo $ticket_details_css_id; ?>-dv" class="tckt-slctr-tkt-details-dv" style="display: none;">
244 244
 
245 245
 								<section class="tckt-slctr-tkt-details-sctn">
246
-									<h3><?php _e( 'Details', 'event_espresso' ); ?></h3>
246
+									<h3><?php _e('Details', 'event_espresso'); ?></h3>
247 247
 									<p><?php echo $ticket->description(); ?></p>
248 248
 
249
-									<?php if ( $ticket_price != 0 && apply_filters( 'FHEE__ticket_selector_chart_template__display_ticket_price_details', TRUE )) { ?>
249
+									<?php if ($ticket_price != 0 && apply_filters('FHEE__ticket_selector_chart_template__display_ticket_price_details', TRUE)) { ?>
250 250
 									<section class="tckt-slctr-tkt-price-sctn">
251
-										<h5><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_price_breakdown_heading', __( 'Price', 'event_espresso' )); ?></h5>
251
+										<h5><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_price_breakdown_heading', __('Price', 'event_espresso')); ?></h5>
252 252
 										<div class="tckt-slctr-tkt-details-tbl-wrap-dv">
253 253
 											<table class="tckt-slctr-tkt-details-tbl">
254 254
 												<thead>
255 255
 													<tr>
256
-														<th class="ee-third-width"><span class="small-text"><?php _e( 'Name', 'event_espresso' ); ?></span></th>
257
-														<th class="jst-cntr"><span class="small-text"><?php _e( 'Description', 'event_espresso' ); ?></span></th>
258
-														<th class="ee-fourth-width jst-rght"><span class="small-text"><?php _e( 'Amount', 'event_espresso' ); ?></span></th>
256
+														<th class="ee-third-width"><span class="small-text"><?php _e('Name', 'event_espresso'); ?></span></th>
257
+														<th class="jst-cntr"><span class="small-text"><?php _e('Description', 'event_espresso'); ?></span></th>
258
+														<th class="ee-fourth-width jst-rght"><span class="small-text"><?php _e('Amount', 'event_espresso'); ?></span></th>
259 259
 													</tr>
260 260
 												</thead>
261 261
 												<tbody>
262
-										<?php if ( $ticket->base_price() instanceof EE_Price ) { ?>
262
+										<?php if ($ticket->base_price() instanceof EE_Price) { ?>
263 263
 													<tr>
264
-														<td data-th="<?php _e( 'Name', 'event_espresso' ); ?>" class="small-text"><b><?php echo $ticket->base_price()->name(); ?></b></td>
265
-														<td data-th="<?php _e( 'Description', 'event_espresso' ); ?>" class="small-text"><?php echo $ticket->base_price()->desc(); ?></td>
266
-														<td data-th="<?php _e( 'Amount', 'event_espresso' ); ?>" class="jst-rght small-text"><?php echo $ticket->base_price()->pretty_price(); ?></td>
264
+														<td data-th="<?php _e('Name', 'event_espresso'); ?>" class="small-text"><b><?php echo $ticket->base_price()->name(); ?></b></td>
265
+														<td data-th="<?php _e('Description', 'event_espresso'); ?>" class="small-text"><?php echo $ticket->base_price()->desc(); ?></td>
266
+														<td data-th="<?php _e('Amount', 'event_espresso'); ?>" class="jst-rght small-text"><?php echo $ticket->base_price()->pretty_price(); ?></td>
267 267
 													</tr>
268 268
 													<?php
269 269
 															$running_total = $ticket->base_price()->amount();
@@ -271,44 +271,44 @@  discard block
 block discarded – undo
271 271
 															$running_total = 0;
272 272
 														}
273 273
 														// now add price modifiers
274
-														foreach ( $ticket->price_modifiers() as $price_mod ) { ?>
274
+														foreach ($ticket->price_modifiers() as $price_mod) { ?>
275 275
 													<tr>
276
-														<td data-th="<?php _e( 'Name', 'event_espresso' ); ?>" class="jst-rght small-text"><?php echo $price_mod->name(); ?></td>
277
-													<?php if ( $price_mod->is_percent() ) { ?>
278
-														<td data-th="<?php _e( 'Description', 'event_espresso' ); ?>" class="small-text"><?php echo $price_mod->desc(); ?> <?php echo $price_mod->amount(); ?>%</td>
276
+														<td data-th="<?php _e('Name', 'event_espresso'); ?>" class="jst-rght small-text"><?php echo $price_mod->name(); ?></td>
277
+													<?php if ($price_mod->is_percent()) { ?>
278
+														<td data-th="<?php _e('Description', 'event_espresso'); ?>" class="small-text"><?php echo $price_mod->desc(); ?> <?php echo $price_mod->amount(); ?>%</td>
279 279
 														<?php
280
-															$new_sub_total = $running_total * ( $price_mod->amount() / 100 );
280
+															$new_sub_total = $running_total * ($price_mod->amount() / 100);
281 281
 															$new_sub_total = $price_mod->is_discount() ? $new_sub_total * -1 : $new_sub_total;
282 282
 														?>
283 283
 													<?php } else { ?>
284 284
 														<?php $new_sub_total = $price_mod->is_discount() ? $price_mod->amount() * -1 : $price_mod->amount(); ?>
285
-														<td data-th="<?php _e( 'Description', 'event_espresso' ); ?>" class="small-text"><?php echo $price_mod->desc(); ?></td>
285
+														<td data-th="<?php _e('Description', 'event_espresso'); ?>" class="small-text"><?php echo $price_mod->desc(); ?></td>
286 286
 														<?php $new_sub_total = $price_mod->is_discount() ? $price_mod->amount() * -1 : $price_mod->amount(); ?>
287 287
 													<?php } ?>
288
-														<td data-th="<?php _e( 'Amount', 'event_espresso' ); ?>" class="jst-rght small-text"><?php echo EEH_Template::format_currency( $new_sub_total ); ?></td>
288
+														<td data-th="<?php _e('Amount', 'event_espresso'); ?>" class="jst-rght small-text"><?php echo EEH_Template::format_currency($new_sub_total); ?></td>
289 289
 														<?php $running_total += $new_sub_total; ?>
290 290
 													</tr>
291 291
 												<?php } ?>
292
-												<?php if ( $ticket->taxable() ) { ?>
292
+												<?php if ($ticket->taxable()) { ?>
293 293
 													<?php //$ticket_subtotal =$ticket->get_ticket_subtotal(); ?>
294 294
 													<tr>
295
-														<td colspan="2" class="jst-rght small-text sbttl"><b><?php _e( 'subtotal', 'event_espresso' ); ?></b></td>
296
-														<td data-th="<?php _e( 'subtotal', 'event_espresso' ); ?>" class="jst-rght small-text"><b><?php echo  EEH_Template::format_currency( $running_total ); ?></b></td>
295
+														<td colspan="2" class="jst-rght small-text sbttl"><b><?php _e('subtotal', 'event_espresso'); ?></b></td>
296
+														<td data-th="<?php _e('subtotal', 'event_espresso'); ?>" class="jst-rght small-text"><b><?php echo  EEH_Template::format_currency($running_total); ?></b></td>
297 297
 													</tr>
298 298
 
299
-													<?php foreach ( $ticket->get_ticket_taxes_for_admin() as $tax ) { ?>
299
+													<?php foreach ($ticket->get_ticket_taxes_for_admin() as $tax) { ?>
300 300
 													<tr>
301
-														<td data-th="<?php _e( 'Name', 'event_espresso' ); ?>" class="jst-rght small-text"><?php echo $tax->name(); ?></td>
302
-														<td data-th="<?php _e( 'Description', 'event_espresso' ); ?>" class="jst-rght small-text"><?php echo $tax->amount(); ?>%</td>
303
-														<?php $tax_amount = $running_total * ( $tax->amount() / 100 ); ?>
304
-														<td data-th="<?php _e( 'Amount', 'event_espresso' ); ?>" class="jst-rght small-text"><?php echo EEH_Template::format_currency( $tax_amount ); ?></td>
301
+														<td data-th="<?php _e('Name', 'event_espresso'); ?>" class="jst-rght small-text"><?php echo $tax->name(); ?></td>
302
+														<td data-th="<?php _e('Description', 'event_espresso'); ?>" class="jst-rght small-text"><?php echo $tax->amount(); ?>%</td>
303
+														<?php $tax_amount = $running_total * ($tax->amount() / 100); ?>
304
+														<td data-th="<?php _e('Amount', 'event_espresso'); ?>" class="jst-rght small-text"><?php echo EEH_Template::format_currency($tax_amount); ?></td>
305 305
 														<?php $running_total += $tax_amount; ?>
306 306
 													</tr>
307 307
 													<?php } ?>
308 308
 												<?php } ?>
309 309
 													<tr>
310
-														<td colspan="2" class="jst-rght small-text ttl-lbl-td"><b><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_total_price', __( 'Total', 'event_espresso' )); ?></b></td>
311
-														<td data-th="<?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_total_price', __( 'Total', 'event_espresso' )); ?>" class="jst-rght small-text"><b><?php echo EEH_Template::format_currency( $running_total ); ?></b></td>
310
+														<td colspan="2" class="jst-rght small-text ttl-lbl-td"><b><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_total_price', __('Total', 'event_espresso')); ?></b></td>
311
+														<td data-th="<?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_total_price', __('Total', 'event_espresso')); ?>" class="jst-rght small-text"><b><?php echo EEH_Template::format_currency($running_total); ?></b></td>
312 312
 													</tr>
313 313
 												</tbody>
314 314
 											</table>
@@ -318,106 +318,106 @@  discard block
 block discarded – undo
318 318
 									<?php } ?>
319 319
 
320 320
 									<section class="tckt-slctr-tkt-sale-dates-sctn">
321
-										<h5><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_sales_date_heading', __( 'Sale Dates', 'event_espresso' )); ?></h5>
322
-										<span class="drk-grey-text small-text no-bold"> - <?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_dates_available_message', __( 'The dates when this option is available for purchase.', 'event_espresso' )); ?></span><br/>
323
-										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_goes_on_sale', __( 'Goes On Sale:', 'event_espresso' )); ?></span><span class="dashicons dashicons-calendar"></span><?php echo $ticket->get_i18n_datetime( 'TKT_start_date', $date_format) . ' &nbsp; '; ?><span class="dashicons dashicons-clock"></span><?php echo $ticket->get_i18n_datetime( 'TKT_start_date',  $time_format ) ; ?><br/>
324
-										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_sales_end', __( 'Sales End:', 'event_espresso' )); ?></span><span class="dashicons dashicons-calendar"></span><?php echo $ticket->get_i18n_datetime( 'TKT_end_date', $date_format ) . ' &nbsp; '; ?><span class="dashicons dashicons-clock"></span><?php echo $ticket->get_i18n_datetime( 'TKT_end_date', $time_format ) ; ?><br/>
321
+										<h5><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_sales_date_heading', __('Sale Dates', 'event_espresso')); ?></h5>
322
+										<span class="drk-grey-text small-text no-bold"> - <?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_dates_available_message', __('The dates when this option is available for purchase.', 'event_espresso')); ?></span><br/>
323
+										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_goes_on_sale', __('Goes On Sale:', 'event_espresso')); ?></span><span class="dashicons dashicons-calendar"></span><?php echo $ticket->get_i18n_datetime('TKT_start_date', $date_format).' &nbsp; '; ?><span class="dashicons dashicons-clock"></span><?php echo $ticket->get_i18n_datetime('TKT_start_date', $time_format); ?><br/>
324
+										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_sales_end', __('Sales End:', 'event_espresso')); ?></span><span class="dashicons dashicons-calendar"></span><?php echo $ticket->get_i18n_datetime('TKT_end_date', $date_format).' &nbsp; '; ?><span class="dashicons dashicons-clock"></span><?php echo $ticket->get_i18n_datetime('TKT_end_date', $time_format); ?><br/>
325 325
 									</section>
326 326
 									<br/>
327 327
 
328
-									<?php do_action( 'AHEE__ticket_selector_chart_template__after_ticket_date', $ticket ); ?>
328
+									<?php do_action('AHEE__ticket_selector_chart_template__after_ticket_date', $ticket); ?>
329 329
 
330
-									<?php if ( $ticket->min() &&$ticket->max() ) { ?>
330
+									<?php if ($ticket->min() && $ticket->max()) { ?>
331 331
 									<section class="tckt-slctr-tkt-quantities-sctn">
332
-										<h5><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_heading', __( 'Purchasable Quantities', 'event_espresso' )); ?></h5>
333
-										<span class="drk-grey-text small-text no-bold"> - <?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_message', __( 'The number of tickets that can be purchased per transaction (if available).', 'event_espresso' )); ?></span><br/>
334
-										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_min_qty', __( 'Minimum Qty:', 'event_espresso' )); ?></span><?php echo $ticket->min() > 0 ? $ticket->min() : 0; ?>
335
-										<?php if ( $ticket->min() > $remaining ) { ?> &nbsp; <span class="important-notice small-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_min_qty_message', __( 'The Minimum Quantity purchasable for this ticket exceeds the number of spaces remaining', 'event_espresso' )); ?></span><?php } ?><br/>
332
+										<h5><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_heading', __('Purchasable Quantities', 'event_espresso')); ?></h5>
333
+										<span class="drk-grey-text small-text no-bold"> - <?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_message', __('The number of tickets that can be purchased per transaction (if available).', 'event_espresso')); ?></span><br/>
334
+										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_min_qty', __('Minimum Qty:', 'event_espresso')); ?></span><?php echo $ticket->min() > 0 ? $ticket->min() : 0; ?>
335
+										<?php if ($ticket->min() > $remaining) { ?> &nbsp; <span class="important-notice small-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_min_qty_message', __('The Minimum Quantity purchasable for this ticket exceeds the number of spaces remaining', 'event_espresso')); ?></span><?php } ?><br/>
336 336
 										<?php //$max = min( $max, $max_atndz );?>
337
-										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_max_qty', __( 'Maximum Qty:', 'event_espresso' )); ?></span><?php echo $ticket->max() === EE_INF ? __( 'no limit', 'event_espresso' ) : max( $ticket->max(), 1 ); ?><br/>
337
+										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_purchasable_quantities_max_qty', __('Maximum Qty:', 'event_espresso')); ?></span><?php echo $ticket->max() === EE_INF ? __('no limit', 'event_espresso') : max($ticket->max(), 1); ?><br/>
338 338
 									</section>
339 339
 									<br/>
340 340
 									<?php } ?>
341 341
 
342
-									<?php if ( $ticket->uses() !== EE_INF && ( ! defined( 'EE_DECAF' ) || EE_DECAF !== TRUE )) { ?>
342
+									<?php if ($ticket->uses() !== EE_INF && ( ! defined('EE_DECAF') || EE_DECAF !== TRUE)) { ?>
343 343
 									<section class="tckt-slctr-tkt-uses-sctn">
344
-										<h5><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_date_ticket_uses_heading', __( 'Event Date Ticket Uses', 'event_espresso' )); ?></h5>
344
+										<h5><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_date_ticket_uses_heading', __('Event Date Ticket Uses', 'event_espresso')); ?></h5>
345 345
 										<span class="drk-grey-text small-text no-bold"> - <?php
346 346
 											echo apply_filters(
347 347
 												'FHEE__ticket_selector_chart_template__ticket_details_event_date_ticket_uses_message',
348 348
 												sprintf(
349
-													__( 'The number of separate event datetimes (see table below) that this ticket can be used to gain admittance to.%1$s%2$sAdmission is always one person per ticket.%3$s', 'event_espresso' ),
349
+													__('The number of separate event datetimes (see table below) that this ticket can be used to gain admittance to.%1$s%2$sAdmission is always one person per ticket.%3$s', 'event_espresso'),
350 350
 													'<br/>',
351 351
 													'<strong>',
352 352
 													'</strong>'
353 353
 												)
354 354
 											);
355 355
 											?></span><br/>
356
-										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_date_number_datetimes', __( '# Datetimes:', 'event_espresso' )); ?></span><?php  echo $ticket->uses();?><br/>
356
+										<span class="ticket-details-label-spn drk-grey-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_date_number_datetimes', __('# Datetimes:', 'event_espresso')); ?></span><?php  echo $ticket->uses(); ?><br/>
357 357
 									</section>
358 358
 									<?php } ?>
359 359
 
360 360
 									<?php
361
-									$datetimes = $ticket->datetimes_ordered( $event_is_expired, FALSE );
361
+									$datetimes = $ticket->datetimes_ordered($event_is_expired, FALSE);
362 362
 									$chart_column_width = $template_settings->show_ticket_sale_columns ? ' ee-fourth-width' : ' ee-half-width';
363
-									if ( ! empty( $datetimes )) { ?>
363
+									if ( ! empty($datetimes)) { ?>
364 364
 									<section class="tckt-slctr-tkt-datetimes-sctn">
365
-										<h5><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_heading', __( 'Access', 'event_espresso' )); ?></h5>
366
-										<span class="drk-grey-text small-text no-bold"> - <?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_message', __( 'This option allows access to the following dates and times.', 'event_espresso' )); ?></span>
365
+										<h5><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_heading', __('Access', 'event_espresso')); ?></h5>
366
+										<span class="drk-grey-text small-text no-bold"> - <?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_message', __('This option allows access to the following dates and times.', 'event_espresso')); ?></span>
367 367
 										<div class="tckt-slctr-tkt-details-tbl-wrap-dv">
368 368
 											<table class="tckt-slctr-tkt-details-tbl">
369 369
 												<thead>
370 370
 													<tr>
371 371
 														<th class="tckt-slctr-tkt-details-date-th">
372
-															<span class="dashicons dashicons-calendar"></span><span class="small-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_event_date', __( 'Date ', 'event_espresso' )); ?></span>
372
+															<span class="dashicons dashicons-calendar"></span><span class="small-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_event_date', __('Date ', 'event_espresso')); ?></span>
373 373
 														</th>
374 374
 														<th class="tckt-slctr-tkt-details-time-th <?php echo $chart_column_width; ?>">
375
-															<span class="dashicons dashicons-clock"></span><span class="small-text"><?php _e( 'Time ', 'event_espresso' ); ?></span>
375
+															<span class="dashicons dashicons-clock"></span><span class="small-text"><?php _e('Time ', 'event_espresso'); ?></span>
376 376
 														</th>
377
-														<?php if ( $template_settings->show_ticket_sale_columns ) : ?>
377
+														<?php if ($template_settings->show_ticket_sale_columns) : ?>
378 378
 															<th class="tckt-slctr-tkt-details-this-ticket-sold-th ee-fourth-width cntr">
379
-																<span class="smaller-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_this_ticket_sold', sprintf( __( 'Sold', 'event_espresso' ), '<br/>' )); ?></span>
379
+																<span class="smaller-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_this_ticket_sold', sprintf(__('Sold', 'event_espresso'), '<br/>')); ?></span>
380 380
 															</th>
381 381
 															<th class="tckt-slctr-tkt-details-this-ticket-left-th ee-fourth-width cntr">
382
-																<span class="smaller-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_this_ticket_left', sprintf( __( 'Remaining', 'event_espresso' ), '<br/>' )); ?></span>
382
+																<span class="smaller-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_this_ticket_left', sprintf(__('Remaining', 'event_espresso'), '<br/>')); ?></span>
383 383
 															</th>
384 384
 															<th class="tckt-slctr-tkt-details-total-tickets-sold-th ee-fourth-width cntr">
385
-																<span class="smaller-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_total_ticket_sold', sprintf( __( 'Total%sSold', 'event_espresso' ), '<br/>' )); ?></span>
385
+																<span class="smaller-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_total_ticket_sold', sprintf(__('Total%sSold', 'event_espresso'), '<br/>')); ?></span>
386 386
 															</th>
387 387
 															<th class="tckt-slctr-tkt-details-total-tickets-left-th ee-fourth-width cntr">
388
-																<span class="smaller-text"><?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_total_ticket_left', sprintf( __( 'Total Spaces%sLeft', 'event_espresso' ), '<br/>' )); ?></span>
388
+																<span class="smaller-text"><?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_total_ticket_left', sprintf(__('Total Spaces%sLeft', 'event_espresso'), '<br/>')); ?></span>
389 389
 															</th>
390 390
 														<?php endif; //end $template_settings->show_ticket_sale_columns conditional ?>
391 391
 													</tr>
392 392
 												</thead>
393 393
 												<tbody>
394 394
 											<?php
395
-												foreach ( $datetimes as $datetime ) {
396
-													if ( $datetime instanceof EE_Datetime ) {
395
+												foreach ($datetimes as $datetime) {
396
+													if ($datetime instanceof EE_Datetime) {
397 397
 											?>
398 398
 
399 399
 												<tr>
400
-													<td data-th="<?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_event_date', __( 'Event Date ', 'event_espresso' )); ?>" class="small-text">
400
+													<td data-th="<?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_event_date', __('Event Date ', 'event_espresso')); ?>" class="small-text">
401 401
 														<?php $datetime_name = $datetime->name(); ?>
402
-														<?php echo ! empty( $datetime_name ) ? '<b>' . $datetime_name . '</b><br/>' : ''; ?>
403
-														<?php echo $datetime->date_range( $date_format, __( ' to  ', 'event_espresso' )); ?>
402
+														<?php echo ! empty($datetime_name) ? '<b>'.$datetime_name.'</b><br/>' : ''; ?>
403
+														<?php echo $datetime->date_range($date_format, __(' to  ', 'event_espresso')); ?>
404 404
 													</td>
405
-													<td data-th="<?php _e( 'Time ', 'event_espresso' ); ?>" class="cntr small-text">
406
-														<?php echo $datetime->time_range( $time_format, __( ' to  ', 'event_espresso' )); ?>
405
+													<td data-th="<?php _e('Time ', 'event_espresso'); ?>" class="cntr small-text">
406
+														<?php echo $datetime->time_range($time_format, __(' to  ', 'event_espresso')); ?>
407 407
 													</td>
408
-													<?php if ( $template_settings->show_ticket_sale_columns ) : ?>
409
-														<td data-th="<?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_this_ticket_sold', __( 'Sold', 'event_espresso' )); ?>" class="cntr small-text">
408
+													<?php if ($template_settings->show_ticket_sale_columns) : ?>
409
+														<td data-th="<?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_this_ticket_sold', __('Sold', 'event_espresso')); ?>" class="cntr small-text">
410 410
 															<?php echo $ticket->sold(); ?>
411 411
 														</td>
412
-														<td data-th="<?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_this_ticket_left', __( 'Remaining', 'event_espresso' )); ?>" class="cntr small-text">
413
-															<?php echo $ticket->qty() === EE_INF ? '<span class="smaller-text">' .  __( 'unlimited ', 'event_espresso' ) . '</span>' : $ticket->qty() - $ticket->sold(); ?>
412
+														<td data-th="<?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_this_ticket_left', __('Remaining', 'event_espresso')); ?>" class="cntr small-text">
413
+															<?php echo $ticket->qty() === EE_INF ? '<span class="smaller-text">'.__('unlimited ', 'event_espresso').'</span>' : $ticket->qty() - $ticket->sold(); ?>
414 414
 														</td>
415
-														<td data-th="<?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_total_ticket_sold', __( 'Total Sold', 'event_espresso' )); ?>" class="cntr small-text">
415
+														<td data-th="<?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_total_ticket_sold', __('Total Sold', 'event_espresso')); ?>" class="cntr small-text">
416 416
 															<?php echo $datetime->sold(); ?>
417 417
 														</td>
418
-												<?php $tkts_left = $datetime->sold_out() ? '<span class="sold-out smaller-text">' . __( 'Sold&nbsp;Out', 'event_espresso' ) . '</span>' : $datetime->spaces_remaining(); ?>
419
-														<td data-th="<?php echo apply_filters( 'FHEE__ticket_selector_chart_template__ticket_details_event_access_table_total_ticket_left', __( 'Total Spaces Left', 'event_espresso' )); ?>" class="cntr small-text">
420
-															<?php echo $tkts_left === EE_INF ? '<span class="smaller-text">' .  __( 'unlimited ', 'event_espresso' ) . '</span>' : $tkts_left; ?>
418
+												<?php $tkts_left = $datetime->sold_out() ? '<span class="sold-out smaller-text">'.__('Sold&nbsp;Out', 'event_espresso').'</span>' : $datetime->spaces_remaining(); ?>
419
+														<td data-th="<?php echo apply_filters('FHEE__ticket_selector_chart_template__ticket_details_event_access_table_total_ticket_left', __('Total Spaces Left', 'event_espresso')); ?>" class="cntr small-text">
420
+															<?php echo $tkts_left === EE_INF ? '<span class="smaller-text">'.__('unlimited ', 'event_espresso').'</span>' : $tkts_left; ?>
421 421
 														</td>
422 422
 													<?php endif; //end $template_settings->show_ticket_sale_columns conditional ?>
423 423
 												</tr>
@@ -435,7 +435,7 @@  discard block
 block discarded – undo
435 435
 							</div>
436 436
 						</td>
437 437
 					</tr>
438
-				<?php endif;  //end template_settings->show_ticket_details check?>
438
+				<?php endif; //end template_settings->show_ticket_details check?>
439 439
 	<?php
440 440
 			$row++;
441 441
 		}
@@ -444,18 +444,18 @@  discard block
 block discarded – undo
444 444
 $ticket_row_html = ob_get_clean();
445 445
 // if there is only ONE ticket with a max qty of ONE, and it is free... then not much need for the ticket selector
446 446
 $hide_ticket_selector = $ticket_count == 1 && $max == 1 && $ticket->is_free() ? true : false;
447
-$hide_ticket_selector = apply_filters( 'FHEE__ticket_selector_chart_template__hide_ticket_selector', $hide_ticket_selector, $EVT_ID );
447
+$hide_ticket_selector = apply_filters('FHEE__ticket_selector_chart_template__hide_ticket_selector', $hide_ticket_selector, $EVT_ID);
448 448
 // EEH_Debug_Tools::printr( $ticket_count, '$ticket_count', __FILE__, __LINE__ );
449 449
 // EEH_Debug_Tools::printr( $max, '$max', __FILE__, __LINE__ );
450 450
 // EEH_Debug_Tools::printr( $hide_ticket_selector, '$hide_ticket_selector', __FILE__, __LINE__ );
451 451
 //EEH_Debug_Tools::printr( $table_style, '$table_style', __FILE__, __LINE__ );
452 452
 remove_filter(
453 453
 	'FHEE__EE_Ticket_Selector__after_ticket_selector_submit',
454
-	array( 'EED_Ticket_Selector', 'no_tkt_slctr_end_dv' )
454
+	array('EED_Ticket_Selector', 'no_tkt_slctr_end_dv')
455 455
 );
456 456
 remove_filter(
457 457
 	'FHEE__EE_Ticket_Selector__after_view_details_btn',
458
-	array( 'EED_Ticket_Selector', 'no_tkt_slctr_end_dv' )
458
+	array('EED_Ticket_Selector', 'no_tkt_slctr_end_dv')
459 459
 );
460 460
 /**
461 461
 * Filters the anchor ID used when redirecting to the Ticket Selector if no quantity selected
@@ -465,20 +465,20 @@  discard block
 block discarded – undo
465 465
 * @param string '#tkt-slctr-tbl-' . $EVT_ID The html ID to anchor to
466 466
 * @param int $EVT_ID The Event ID
467 467
 */
468
-$anchor_id = apply_filters( 'FHEE__EE_Ticket_Selector__redirect_anchor_id', '#tkt-slctr-tbl-' . $EVT_ID, $EVT_ID );
469
-if ( ! $hide_ticket_selector ) {
468
+$anchor_id = apply_filters('FHEE__EE_Ticket_Selector__redirect_anchor_id', '#tkt-slctr-tbl-'.$EVT_ID, $EVT_ID);
469
+if ( ! $hide_ticket_selector) {
470 470
 ?>
471 471
 <div id="tkt-slctr-tbl-wrap-dv-<?php echo $EVT_ID; ?>" class="tkt-slctr-tbl-wrap-dv">
472 472
 
473
-	<?php do_action( 'AHEE__ticket_selector_chart__template__before_ticket_selector', $event ); ?>
473
+	<?php do_action('AHEE__ticket_selector_chart__template__before_ticket_selector', $event); ?>
474 474
 
475 475
 	<table id="tkt-slctr-tbl-<?php echo $EVT_ID; ?>" class="tkt-slctr-tbl">
476 476
 		<thead>
477 477
 			<tr>
478 478
 				<th scope="col" class="ee-ticket-selector-ticket-details-th">
479
-					<?php echo esc_html( apply_filters( 'FHEE__ticket_selector_chart_template__table_header_available_tickets', '', $EVT_ID ) ); ?>
479
+					<?php echo esc_html(apply_filters('FHEE__ticket_selector_chart_template__table_header_available_tickets', '', $EVT_ID)); ?>
480 480
 				</th>
481
-				<?php if ( apply_filters( 'FHEE__ticket_selector_chart_template__display_ticket_price_details', TRUE )) { ?>
481
+				<?php if (apply_filters('FHEE__ticket_selector_chart_template__display_ticket_price_details', TRUE)) { ?>
482 482
 				<th scope="col" class="ee-ticket-selector-ticket-price-th cntr">
483 483
 					<?php
484 484
 						/**
@@ -489,7 +489,7 @@  discard block
 block discarded – undo
489 489
 						 * @param string 'Price' The translatable text to display in the table header for price
490 490
 						 * @param int $EVT_ID The Event ID
491 491
 						 */
492
-						echo esc_html( apply_filters( 'FHEE__ticket_selector_chart_template__table_header_price', __( 'Price', 'event_espresso' ), $EVT_ID ) );
492
+						echo esc_html(apply_filters('FHEE__ticket_selector_chart_template__table_header_price', __('Price', 'event_espresso'), $EVT_ID));
493 493
 					?>
494 494
 				</th>
495 495
 				<?php } ?>
@@ -503,24 +503,24 @@  discard block
 block discarded – undo
503 503
 						* @param string 'Qty*' The translatable text to display in the table header for the Quantity of tickets
504 504
 						* @param int $EVT_ID The Event ID
505 505
 						*/
506
-						echo esc_html( apply_filters( 'FHEE__ticket_selector_chart_template__table_header_qty', __( 'Qty*', 'event_espresso' ), $EVT_ID ) );
506
+						echo esc_html(apply_filters('FHEE__ticket_selector_chart_template__table_header_qty', __('Qty*', 'event_espresso'), $EVT_ID));
507 507
 					?>
508 508
 				</th>
509 509
 			</tr>
510 510
 		</thead>
511 511
 		<tbody>
512
-			<?php echo $ticket_row_html;?>
512
+			<?php echo $ticket_row_html; ?>
513 513
 		</tbody>
514 514
 	</table>
515 515
 
516 516
 	<input type="hidden" name="noheader" value="true" />
517
-	<input type="hidden" name="tkt-slctr-return-url-<?php echo $EVT_ID ?>" value="<?php echo EEH_URL::filter_input_server_url() . $anchor_id; ?>" />
517
+	<input type="hidden" name="tkt-slctr-return-url-<?php echo $EVT_ID ?>" value="<?php echo EEH_URL::filter_input_server_url().$anchor_id; ?>" />
518 518
 	<input type="hidden" name="tkt-slctr-rows-<?php echo $EVT_ID; ?>" value="<?php echo $row - 1; ?>" />
519 519
 	<input type="hidden" name="tkt-slctr-max-atndz-<?php echo $EVT_ID; ?>" value="<?php echo $max_atndz; ?>" />
520 520
 	<input type="hidden" name="tkt-slctr-event-id" value="<?php echo $EVT_ID; ?>" />
521 521
 
522 522
 <?php
523
-if ( $max_atndz > 0 && ! $hide_ticket_selector ) {
523
+if ($max_atndz > 0 && ! $hide_ticket_selector) {
524 524
 	echo apply_filters(
525 525
 		'FHEE__ticket_selector_chart_template__maximum_tickets_purchased_footnote',
526 526
 		''
@@ -528,39 +528,39 @@  discard block
 block discarded – undo
528 528
 }
529 529
 ?>
530 530
 
531
-	<?php do_action( 'AHEE__ticket_selector_chart__template__after_ticket_selector', $EVT_ID, $event ); ?>
531
+	<?php do_action('AHEE__ticket_selector_chart__template__after_ticket_selector', $EVT_ID, $event); ?>
532 532
 
533 533
 </div>
534
-<?php } else if ( isset( $TKT_ID ) ) { ?>
534
+<?php } else if (isset($TKT_ID)) { ?>
535 535
 <input type="hidden" name="tkt-slctr-qty-<?php echo $EVT_ID; ?>[]" value="1"/>
536 536
 <input type="hidden" name="tkt-slctr-ticket-id-<?php echo $EVT_ID; ?>[]" value="<?php echo $TKT_ID; ?>"/>
537 537
 <input type="hidden" name="noheader" value="true"/>
538
-<input type="hidden" name="tkt-slctr-return-url-<?php echo $EVT_ID ?>" value="<?php echo EEH_URL::filter_input_server_url() . $anchor_id; ?>"/>
538
+<input type="hidden" name="tkt-slctr-return-url-<?php echo $EVT_ID ?>" value="<?php echo EEH_URL::filter_input_server_url().$anchor_id; ?>"/>
539 539
 <input type="hidden" name="tkt-slctr-rows-<?php echo $EVT_ID; ?>" value="<?php echo $row - 1; ?>"/>
540 540
 <input type="hidden" name="tkt-slctr-max-atndz-<?php echo $EVT_ID; ?>" value="<?php echo $max_atndz; ?>"/>
541 541
 <input type="hidden" name="tkt-slctr-event-id" value="<?php echo $EVT_ID; ?>"/>
542 542
 <?php
543
-	if ( $ticket instanceof EE_Ticket ) {
544
-		do_action( 'AHEE__ticket_selector_chart__template__before_ticket_selector', $event );
543
+	if ($ticket instanceof EE_Ticket) {
544
+		do_action('AHEE__ticket_selector_chart__template__before_ticket_selector', $event);
545 545
 		$ticket_description = $ticket->description();
546 546
 ?>
547 547
 <div id="no-tkt-slctr-ticket-dv-<?php echo $EVT_ID; ?>" class="no-tkt-slctr-ticket-dv">
548 548
 	<div class="no-tkt-slctr-ticket-content-dv">
549 549
 		<h5><?php echo $ticket->name(); ?></h5>
550
-		<?php if ( ! empty( $ticket_description ) ) { ?>
550
+		<?php if ( ! empty($ticket_description)) { ?>
551 551
 		<p><?php echo $ticket_description; ?></p>
552 552
 		<?php } ?>
553 553
 	</div>
554 554
 <?php
555 555
 		add_filter(
556 556
 			'FHEE__EE_Ticket_Selector__after_ticket_selector_submit',
557
-			array( 'EED_Ticket_Selector', 'no_tkt_slctr_end_dv' )
557
+			array('EED_Ticket_Selector', 'no_tkt_slctr_end_dv')
558 558
 		);
559 559
 		add_filter(
560 560
 			'FHEE__EE_Ticket_Selector__after_view_details_btn',
561
-			array( 'EED_Ticket_Selector', 'no_tkt_slctr_end_dv' )
561
+			array('EED_Ticket_Selector', 'no_tkt_slctr_end_dv')
562 562
 		);
563
-		do_action( 'AHEE__ticket_selector_chart__template__after_ticket_selector', $EVT_ID, $event );
563
+		do_action('AHEE__ticket_selector_chart__template__after_ticket_selector', $EVT_ID, $event);
564 564
 	}
565 565
 }
566 566
 ?>
Please login to merge, or discard this patch.