Index: /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/bootstrap.php
===================================================================
--- /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/bootstrap.php	(revision 4315)
+++ /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/bootstrap.php	(revision 4316)
@@ -15,8 +15,8 @@
 const REQUIRED_CAPABILITY = 'manage_options';
 
+require_once( __DIR__ . '/includes/common.php'      );
+require_once( __DIR__ . '/includes/html-badges.php' );
+
 if ( is_admin() ) {
-	require_once( __DIR__ . '/includes/common.php'          );
 	require_once( __DIR__ . '/includes/indesign-badges.php' );
 }
-
-require_once( __DIR__ . '/includes/html-badges.php' );
Index: /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/includes/common.php
===================================================================
--- /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/includes/common.php	(revision 4315)
+++ /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/includes/common.php	(revision 4316)
@@ -6,7 +6,11 @@
 defined( 'WPINC' ) or die();
 
-add_filter( 'camptix_menu_tools_tabs',   __NAMESPACE__ . '\add_badges_tab'     );
-add_action( 'camptix_menu_tools_badges', __NAMESPACE__ . '\render_badges_page' );
-add_action( 'admin_print_styles',        __NAMESPACE__ . '\print_admin_styles' );
+if ( is_admin() ) {
+	add_filter( 'camptix_menu_tools_tabs',   __NAMESPACE__ . '\add_badges_tab'     );
+	add_action( 'camptix_menu_tools_badges', __NAMESPACE__ . '\render_badges_page' );
+	add_action( 'admin_print_styles',        __NAMESPACE__ . '\print_admin_styles' );
+}
+
+add_filter( 'get_post_metadata', __NAMESPACE__ . '\add_dynamic_post_meta', 10, 3 );
 
 /**
@@ -58,2 +62,96 @@
 	<?php
 }
+
+/**
+ * Get the attendees
+ *
+ * @return array
+ */
+function get_attendees() {
+	$attendees = get_posts( array(
+		'post_type'      => 'tix_attendee',
+		'posts_per_page' => 12000,
+		'orderby'        => 'title',
+	) );
+
+	return $attendees;
+}
+
+/**
+ * Add dynamically-generated "post meta" to `\WP_Post` objects
+ *
+ * This makes it possible to access dynamic data related to a post object by simply referencing `$post->foo`.
+ * That keeps the calling code much cleaner than if it were to have to do something like
+ * `$foo = some_custom_logic( get_post_meta( $post->ID, 'bar', true ) ); echo esc_html( $foo )`.
+ *
+ * @param mixed  $value
+ * @param int    $post_id
+ * @param string $meta_key
+ *
+ * @return mixed
+ *      `null` to instruct `get_metadata()` to pull the value from the database
+ *      Any non-null value will be returned as if it were pulled from the database
+ */
+function add_dynamic_post_meta( $value, $post_id, $meta_key ) {
+	/** @global \CampTix_Plugin $camptix */
+	global $camptix;
+
+	$attendee = get_post( $post_id );
+
+	if ( 'tix_attendee' != $attendee->post_type ) {
+		return $value;
+	}
+
+	switch ( $meta_key ) {
+		case 'avatar_url':
+			$value = get_avatar_url( $attendee->tix_email, array( 'size' => 600 ) );
+			break;
+
+		case 'coupon':
+			if ( $attendee->tix_coupon_id ) {
+				$coupon = get_post( $attendee->tix_coupon_id );
+				$value  = $coupon->post_name;
+			}
+			break;
+
+		case 'css_classes':
+			$value = get_css_classes( $attendee );
+			break;
+
+		case 'formatted_name':
+			$value = $camptix->format_name_string(
+				'<span class="first-name">%first%</span>
+				 <span class="last-name">%last%</span>',
+				$attendee->tix_first_name,
+				$attendee->tix_last_name
+			);
+			break;
+
+		case 'ticket':
+			$ticket = get_post( $attendee->tix_ticket_id );
+			$value  = $ticket->post_name;
+			break;
+	}
+
+	return $value;
+}
+
+/**
+ * Get the CSS classes for an attendee element
+ *
+ * @param \WP_Post $attendee
+ *
+ * @return string
+ */
+function get_css_classes( $attendee ) {
+	$classes = array(
+		'attendee-' . $attendee->post_name,
+		'ticket-'   . $attendee->ticket
+	);
+
+	if ( $attendee->coupon ) {
+		$classes[] = 'coupon-' . $attendee->coupon;
+	}
+
+	return implode( ' ', $classes );
+}
Index: /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/includes/html-badges.php
===================================================================
--- /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/includes/html-badges.php	(revision 4315)
+++ /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/includes/html-badges.php	(revision 4316)
@@ -12,5 +12,4 @@
 add_action( 'wp_enqueue_scripts',    __NAMESPACE__ . '\enqueue_previewer_scripts',   999 );  // after remove_all_previewer_styles()
 add_filter( 'template_include',      __NAMESPACE__ . '\use_badges_template'              );
-add_filter( 'get_post_metadata',     __NAMESPACE__ . '\add_dynamic_post_meta', 10, 3     );
 
 /**
@@ -215,82 +214,7 @@
 	);
 
-	$attendees = get_posts( array(
-		'post_type'      => 'tix_attendee',
-		'posts_per_page' => -1,
-		'orderby'        => 'title',
-	) );
+	$attendees = Badge_Generator\get_attendees();
 
 	require( dirname( __DIR__ ) . '/views/html-badges/template-badges.php' );
-}
-
-/**
- * Add dynamically-generated "post meta" to `\WP_Post` objects
- *
- * This makes it possible to access dynamic data related to a post object by simply referencing `$post->foo`.
- * That keeps the calling code much cleaner than if it were to have to do something like
- * `$foo = some_custom_logic( get_post_meta( $post->ID, 'bar', true ) ); echo esc_html( $foo )`.
- *
- * @param mixed  $value
- * @param int    $post_id
- * @param string $meta_key
- *
- * @return mixed
- *      `null` to instruct `get_metadata()` to pull the value from the database
- *      Any non-null value will be returned as if it were pulled from the database
- */
-function add_dynamic_post_meta( $value, $post_id, $meta_key ) {
-	/** @global \CampTix_Plugin $camptix */
-	global $camptix;
-
-	$attendee = get_post( $post_id );
-
-	if ( 'tix_attendee' != $attendee->post_type ) {
-		return $value;
-	}
-
-	switch ( $meta_key ) {
-		case 'avatar_url':
-			$value = get_avatar_url( $attendee->tix_email, array( 'size' => 600 ) );
-			break;
-
-		case 'css_classes':
-			$value = get_css_classes( $attendee );
-			break;
-
-		case 'formatted_name':
-			$value = $camptix->format_name_string(
-				'<span class="first-name">%first%</span>
-				 <span class="last-name">%last%</span>',
-				$attendee->tix_first_name,
-				$attendee->tix_last_name
-			);
-			break;
-	}
-
-	return $value;
-}
-
-/**
- * Get the CSS classes for an attendee element
- *
- * @param \WP_Post $attendee
- *
- * @return string
- */
-function get_css_classes( $attendee ) {
-	// Name
-	$classes = array( 'attendee-' . $attendee->post_name );
-
-	// Ticket
-	$ticket    = get_post( $attendee->tix_ticket_id );
-	$classes[] = 'ticket-' . $ticket->post_name;
-
-	// Coupon
-	if ( $attendee->tix_coupon_id ) {
-		$coupon    = get_post( $attendee->tix_coupon_id );
-		$classes[] = 'coupon-' . $coupon->post_name;
-	}
-
-	return implode( ' ', $classes );
 }
 
Index: /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/views/html-badges/template-badges.php
===================================================================
--- /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/views/html-badges/template-badges.php	(revision 4315)
+++ /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/views/html-badges/template-badges.php	(revision 4316)
@@ -3,4 +3,10 @@
 namespace CampTix\Badge_Generator\HTML;
 defined( 'WPINC' ) or die();
+
+/**
+ * @global string   $template
+ * @var    array    $attendees
+ * @var    \WP_Post $attendee
+ */
 
 /*
Index: /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/views/indesign-badges/page-indesign-badges.php
===================================================================
--- /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/views/indesign-badges/page-indesign-badges.php	(revision 4315)
+++ /sites/trunk/wordcamp.org/public_html/wp-content/plugins/camptix-badge-generator/views/indesign-badges/page-indesign-badges.php	(revision 4316)
@@ -3,4 +3,8 @@
 namespace CampTix\Badge_Generator\InDesign;
 defined( 'WPINC' ) or die();
+
+/**
+ * @var string $html_customizer_url
+ */
 
 ?>
