/app_old/membershipincludes/includes/subscription.form.php

  1. <?php 
  2. global $M_options; 
  3. ?> 
  4. <div id='membership-wrapper'> 
  5.  
  6. <fieldset> 
  7. <legend><?php _e( 'Select a Subscription', 'membership' ) ?></legend> 
  8. <p class="help-block"><?php _e('We have the following subscriptions available for our site. To join, simply click on the <strong>Sign Up</strong> button and then complete the registration details.', 'membership'); ?></p> 
  9.  
  10. <form class="form-membership" action="<?php echo get_permalink(); ?>" method="post"> 
  11. <div class="priceboxes"> 
  12. <?php 
  13. do_action( 'membership_subscription_form_before_subscriptions' ); 
  14.  
  15. $subs = $this->get_subscriptions(); 
  16.  
  17. $subs = apply_filters( 'membership_override_subscriptions', $subs ); 
  18.  
  19. foreach((array) $subs as $key => $sub) { 
  20.  
  21. $subscription = new M_Subscription($sub->id); 
  22.  
  23. ?> 
  24. <div class="pricebox subscriptionbox" id='subscriptionbox-<?php echo $subscription->id; ?>'> 
  25. <div class="topbar"><span class='title'><?php echo $subscription->sub_name(); ?></span></div> 
  26. <div class="pricedetails"><?php echo $subscription->sub_description(); ?></div> 
  27. <div class="bottombar"><span class='price'><?php echo $subscription->sub_pricetext(); ?></span> 
  28. <?php 
  29. $pricing = $subscription->get_pricingarray(); 
  30.  
  31. if($pricing) { 
  32. ?> 
  33. <span class='link'> 
  34. <?php 
  35.  
  36. if(isset($M_options['formtype']) && $M_options['formtype'] == 'new') { 
  37. // pop up form 
  38. $link = admin_url( 'admin-ajax.php' ); 
  39. $link .= '?action=buynow&subscription=' . (int) $sub->id; 
  40. $class = 'popover'; 
  41. } else { 
  42. // original form 
  43. $link = '?action=registeruser&subscription=' . (int) $sub->id; 
  44. $class = ''; 
  45.  
  46. if(empty($linktext)) { 
  47. $linktext = apply_filters('membership_subscription_signup_text', __('Sign Up', 'membership')); 
  48.  
  49. $html = "<a href='" . $link . "' class='button " . $class . " " . apply_filters('membership_subscription_button_color', 'blue') . "'>" . $linktext . "</a>"; 
  50. echo $html; 
  51. ?> 
  52. </span> 
  53. <?php 
  54. ?> 
  55. </div> 
  56. </div> 
  57.  
  58.  
  59. <?php 
  60. do_action( 'membership_subscription_form_after_subscriptions' ); 
  61. ?> 
  62. </div> <!-- price boxes --> 
  63. </form> 
  64. </fieldset> 
  65. </div> 
  66. <?php 
  67. ?> 
.