public function ajax_url() {
		if ( empty( $this->structure ) ) {
			$url = esc_url( home_url( 'index.php', is_ssl() ? 'https' : 'http' ) );
		} else {
			$url = esc_url( home_url( '/papi-ajax/', is_ssl() ? 'https' : 'http' ) );
		}
		?>
		<script type="text/javascript">
			var papi = papi || {};
			papi.ajaxUrl = '<?php echo esc_html( $url ); ?>';
		</script>
		<?php
	}