HEX
Server: Apache
System: Linux server1.panigaletech.com 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64
User: ubuntu (1000)
PHP: 7.4.30
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/www/dev.captainschairit.com/wp-content/themes/captainschare/template-parts/pricing-msp.php
<?php
/**
 * Template Name: Pricing MSP
 */
get_header();
if (have_posts()) : while (have_posts()) : the_post();
// $banner_section = get_field('banner_section');
$content = get_field('content');
?>
  <section class="page-section msp-menu-top msp-page-section" id="CompanyInfo">
    <div class="container">
      <div class="row">
        <div class="col-lg-12 text-center">
          <h2 class="heading01 mb-5"><?php echo $page_heading; ?></h2>
        </div>
        <div class="col-sm-12">
          <div class="msp-tab">
            <?php require_once( trailingslashit( get_template_directory() ). 'template-parts/order-tabs.php' ); ?>
            <div class="msp-tab-body">
            <!-- Pricing Start -->
              <div class="ch-plan-tabs">
                <div class="tab-content">
                <p><?php echo $content; ?></p>
                
                <div class="panel-body">
                    <div class="table-responsive choose-price-plan">
                      <table class="table table-bordered table-striped mb-5">
                        <thead>
                          <tr>
                            <th class="light-gray-border-btn">&nbsp;</th>
                            <?php
                            $terms = get_terms( array(
                                'taxonomy' => 'cc-pricing-plans',
                                'hide_empty' => false,
                            ) );
                            // echo '<pre>'; print_r($terms);
                            foreach($terms as $term) {
                            ?>
                            <th class="light-orange-bg light-gray-border text-center text-nowrap light-gray-border-btn"><?php echo $term->name; ?></th>
                            <?php
                            } ?>
                          </tr>
                        </thead>
                        <tbody>
                        <?php
                          $args = array(
                              'post_type' => 'cc-pricings',
                              'order' => 'ASC',
                              'posts_per_page' => 12,
                              'post_status' => 'publish'
                              );
                              $loop = get_posts( $args );
                              // echo '<pre>'; print_r($loop);
                                $count = 1;
                            // $product = get_post( $loop );
                            
                            ?>
                            <?php 
                            $count = 1;
                            foreach($loop as $pricing) {
                              $crewman = get_field('crewman' , $pricing->ID);
                              $lieutenant = get_field('lieutenant' , $pricing->ID);
                              $captain = get_field('captain' , $pricing->ID);
                              ?>
                            <tr>
                            <?php if($crewman['text'] != '') { ?>
                              <td class="text-nowrap light-gray-border <?php echo ($count % 2 == 0)?'light-sky-bg':'light-blue-bg' ?>"><?php echo $pricing->post_title; ?></td>
                              <td class="text-center light-gray-border <?php echo ($count % 2 == 0)?'light-sky-bg':'light-blue-bg' ?> text-nowrap"><?php echo $crewman['text']; ?></td>
                              <td class="text-center light-gray-border <?php echo ($count % 2 == 0)?'light-sky-bg':'light-blue-bg' ?> text-nowrap"><?php echo $lieutenant['text']; ?></td>
                              <td class="text-center <?php echo ($count % 2 == 0)?'light-sky-bg':'light-blue-bg' ?> light-gray-border-btn text-nowrap"><?php echo $captain['text']; ?></td>
                            <?php
                            } else { ?>
                              <td class="text-nowrap light-gray-border light-gray-border-btn <?php echo ($count % 2 == 0)?'light-sky-bg':'light-blue-bg' ?>"><?php echo $pricing->post_title; ?></td>
                              <td class="orange-text text-center light-gray-border light-gray-border-btn <?php echo ($count % 2 == 0)?'light-sky-bg':'light-blue-bg' ?> text-nowrap"> <?php echo ($crewman['eligible'])?'<i class="fas fa-check"></i>':'<i class="fas fa-times"></i>'; ?></td>
                              <td class="orange-text text-center light-gray-border light-gray-border-btn <?php echo ($count % 2 == 0)?'light-sky-bg':'light-blue-bg' ?> text-nowrap"> <?php echo ($lieutenant['eligible'])?'<i class="fas fa-check"></i>':'<i class="fas fa-times"></i>'; ?></td>
                              <td class="orange-text text-center light-gray-border-btn <?php echo ($count % 2 == 0)?'light-sky-bg':'light-blue-bg' ?> text-nowrap"> <?php echo ($captain['eligible'])?'<i class="fas fa-check"></i>':'<i class="fas fa-times"></i>'; ?></td>
                            <?php
                            } ?>
                            </tr>
                          <?php
                          $count++;
                          } ?>
                        </tbody>
                      </table>
                    </div>
                  </div>
					<div class="pricing-top-part">
						<div class="text-center d-block clearfix col-sm">
						  <button type="button" onclick="window.location.href='<?php echo get_site_url() ?>/collect-data-for-msp?val=set'" class="btn btn-primary btn-rounded hvr-shutter-out-horizontal text-transform">Got It</button>
						</div>    
                  	</div>
                </div>
              </div>
            <!-- Pricing End -->
            </div>
          </div>
        </div>
      </div>
    </div>
  </section>


<!-- The Modal -->
<?php
endwhile;
endif;
get_footer();
?>