Location: PHPKode > projects > MembersGear > membersgear/templates/user_default_page.tpl
<center>
 {if $msg neq ''}
                <div {if $err eq 'true'} class="errormsg" {else} class="succmsg" {/if}>
                  <center> {if $msg neq ''}{$msg}{/if}</center>
                </div>
            
    {/if}
{*  <table border="0" align="center"  cellspacing="0" cellpadding="0" id="ctl00_ContentPlaceHolder1_UpdatePanel1" style="width:650px%;height:35px;">
     <tr>
        <td>
            <table border="0" align="center"  cellspacing="0" cellpadding="0" style="width:100%;display:none;" id="ctl00_ContentPlaceHolder1_UpdateProgress1">
               <tr>
                   <td>
                         <center>
                            <div style="width:450px;">
                            <div style="width:45px;float:left"><img src="{$ADMIN_IMAGE_DIR}/DBRestoreloader.gif" align="absmiddle"></div>
                            <div style="width:400px;float:left;padding-top:7px;text-align:left;font-size:12px" class="Lable" id="ctl00_ContentPlaceHolder1_UpdatePanelProgressLoading1_lblmessage">&nbsp;&nbsp;<b>Please wait while your request is being processed..</b></div>
                            </div>
                          </center>  
                      
                    </td>
                </tr>
             </table>            
        </td>
     </tr>
   </table>    *}        
</center>   
  
 <div id="formlayout"> 
      <div id="formlayout-top">
      {*<div style="text-align:center;vertical-align:top;padding-top:7px;">*}
           <div id="divmemberslinkheader"> 
                <ul>
                   {*<li><a href="{$WEB_URL}/member/user_logout.php">Logout</a></li>*}
                             <li><a href="{$WEB_URL}/member/user_default_page.php" class="selected" >Main Area</a></li>
                             <li><a href="{$WEB_URL}/member/user_edit_profile.php" >Edit Profile</a></li>
                            {if $MEMBER_SHOW_AFFILIATE eq 'true'}
                              <li><a href="{$WEB_URL}/member/affiliateSettings.php">{$affiliate_text}</a></li>
                             {/if} 
                             <li><a href="{$WEB_URL}/member/user_change_password.php">Change Password</a></li>
                             <li><a href="{$WEB_URL}/member/user_support.php">Support</a></li>
                             <li><a href="{$WEB_URL}/member/user_rotete_logout.php?url={$WEB_URL}/member/user_logout.php">Logout</a></li>
                 </ul>
            </div>
        
      </div>
      
             <div id="formlayout-bg">
                {*<div style="width:98%;margin:0px auto;">*}
                <div id="divmaindefaultpagecss">
                     
                    <table cellpadding="0" cellspacing="20" width="100%" id="defaulttableheader">
                         <tr>
                             <td align="left" colspan="2">{*<h1 style="margin-top:8px;">*}<h1>{php}echo "Welcome    ".$_SESSION[SESSION_PREFIX.'UserName'];{/php}</h1>
                             </td>
                               {* <td align="right">
                        
                                </td>*}
                         </tr> 
                     </table> 
                    {* <table cellpadding="10" cellspacing="20" width="100%">
                         <tr>
                            <td> 
                               <div style="border-bottom:solid 1px #ccc;width:100%;height:1px;overflow:hidden;clear:both;">
                               </div>
                            </td>
                         </tr>
                     </table>        *}
                    
                     <table width="97%" cellspacing="0" cellpadding="0" id="defaulttablecontent">
                       <tr>
                            <td id="defaulttablesubcontent1">
                               <form name="frmUnsubscribe" id="frmUnsubscribe"  {if $emailsubscription eq "0"}  action="user_unsubscribe_mailing.php?action=unsubscribe"{else}action="user_unsubscribe_mailing.php?action=subscribe"{/if} method="post">
                                   <table cellspacing="0" cellpadding="0" width="98%">
                                         <tr>
                                             <td class="TdPaddingAddRenewSubscriptionMemberDefaultPage">
                                                   <h3>Your Subscriptions</h3>  
                                             </td> 
                                     
                                         </tr>
                                          <tr>
                                              <td class="TdPaddingAddRenewSubscriptionMemberDefaultPage" >
                                                 <div class="Ulset" valign="top">
                                                     <ul id="divdefaultpagesubscriptionul"> 
                                                        {section name=sec loop=$subscribedProduct}
                                                        
                                                           {if $subscribedProduct[sec].is_produc_visible eq 'true'}
                                                            <li id="divdefaultpagesubscriptionli">
                                                                   {if $subscribedProduct[sec].is_product_link_visible eq 'true'}<a  href="{$WEB_URL}{$subscribedProduct[sec].protectedurl}" {if $subscribedProduct[sec].protectedurl eq '/forum/'} target="_new" {/if}>{$subscribedProduct[sec].name}</a>
                                                                   {else}
                                                                        <span>{$subscribedProduct[sec].name}</span>
                                                                   {/if}
                                                                                
                                                            </li>   
                                                           <li id="divdefaultpagesubscriptiondripli" class="divdefaultpagesubscriptiondripli">
                                                           {*$subscribedDrips|@print_r*}
                                                            <ol> 
                                                            {*assign var="action" value="update"*}
                                                               
                                                            {section name=sec1 loop=$subscribedDrips}
                                                               {if $subscribedDrips[sec1].expired eq 'no' 
                                                                  and $subscribedDrips[sec1].showondefaultpage neq '0' 
                                                                  and $subscribedDrips[sec1].status neq '0' 
                                                                  and $subscribedProduct[sec].id==  $subscribedDrips[sec1].product_id}
                                                                        
                                                                         <li>
                                                                                &nbsp;&nbsp;<a  href="{$WEB_URL}{$subscribedDrips[sec1].fileurl}" >{$subscribedDrips[sec1].filename}{*--{$subscribedDrips[sec1].name}*}</a>
                                                                         </li>                                
                                                                 
                                                               
                                                               
                                                                 
                                                               {/if}
                                                               
                                                            {/section}    
                                                              </ol>   
                                                             </li>  
                                                           {/if}                             
                                                        {sectionelse}
                                                            No Subscription Found 
                                                        {/section}          
                                                        </ul>
                                                 </div>  
                                              </td>
                                         </tr>
                                    {*      <tr>
                                             <td class="TdPaddingAddRenewSubscriptionMemberDefaultPage" >
                                                   <h3 style="margin-top:20px;">Your Drip files </h3>  
                                             </td> 
                                     
                                         </tr>
                                        <tr>
                                              <td class="TdPaddingAddRenewSubscriptionMemberDefaultPage"   >
                                                 <div class="Ulset" valign="top">
                                                     <ul> 
                                                              {section name=sec1 loop=$subscribedDrips}
                                                                 {if $subscribedDrips[sec1].expired eq 'no' and $subscribedDrips[sec1].showondefaultpage neq '0' and $subscribedDrips[sec1].status neq '0' }
                                                                        <li style="margin:1px;">
                                                                                &nbsp;&nbsp;<a target="_blank" href="{$WEB_URL}{$subscribedDrips[sec1].fileurl}" ><b>{$subscribedDrips[sec1].filename}</b>--{$subscribedDrips[sec1].name}</a>
                                                                         </li>
                                                                  {/if}       
                                                                {sectionelse}
                                                                 No Drip Subscription Found 
                                                    
                                                                {/section}          
                                                        </ul>
                                                 </div>  
                                              </td>
                                         </tr>*}
                                         
                                          
                                          
                                          <tr>
                                              <td>&nbsp;
                                                     
                                              </td>   
                                          </tr>
                                           <tr>
                                              <td class="TdPaddingAddRenewSubscriptionMemberDefaultPage">
                                                  <h3>Newsletter Subscriptions</h3>
                                              </td>
                                           </tr>
                                            <tr>
                                              <td>&nbsp;
                                                   
                                              </td>   
                                            </tr>
                                           <tr>
                                              <td>
                                                  {if $emailsubscription eq "0"}
                                                        <table cellpadding="0" cellspacing="0" id="defaulttablemailsubscribe">
                                                             <tr>
                                                                 <td class="">
                                                                     <input type="checkbox"  class="chkcss" value="on" name="unsubscribechk" id="unsubscribechk"/> 
                                                                     <input type="hidden" name="username" value="{$username}" id="username">
                                               
                                                                 </td>
                                                                 <td  class="">
                                                                     <label for="unsubscribechk"><strong>Unsubscribe from all Email Messages</strong></label>
                                                                 </td>
                                                             </tr>
                                                        </table>
                                                  {else}
                                                     <table cellpadding="0" cellspacing="0" id="defaulttablemailsubscribe">
                                                       <tr>
                                                            <td  class="">
                                                                 <input type="checkbox" class="chkcss"  value="on" name="subscribechk" id="subscribechk"/> 
                                                                  <input type="hidden" name="username" value="{$username}" id="username">
                                                   
                                                            </td>
                                                            <td  class="TdPaddingAddRenewSubscriptionMemberDefaultPage">
                                                                 <label for="subscribechk"><strong>Subscribe all Email Messages</strong></label>
                                                            </td>
                                                       </tr>
                                                   </table>
                                               {/if}    
                                          </td>
                                       </tr>
                               
                                        <tr>
                                           <td>&nbsp;
                                            
                                           </td>   
                                       </tr>
                             
                                       <tr>
                                         <td class="TdPaddingAddRenewSubscriptionMemberDefaultPage">
                                            <input type="submit" value="Update subscriptions" class="bigger-button"/>
                                        </td>
                                     </tr>
                             </table>
                         </form>
                      </td>
                    
                      <td class="noTDpadding" id="defaulttablesubcontent2">
                          <form name="frmvalidatorMember"  id="frmvalidatorMember" action="user_subscribe_product.php" method="post">
                           <table cellspacing="0" cellpadding="0">
                               <tr>
                                   <td class="TdPaddingAddRenewSubscriptionMemberDefaultPage">
                                       <h3>Add/Renew Subscription</h3>
                                   </td>
                               </tr> 
                          
                                <tr>
                                  <td>
                                     <table cellpadding="0" cellspacing="0"  >
                                        <tr valign="top">
                                          <td class="TdPaddingAddRenewSubscriptionMemberDefaultPage" valign="top">
                                                <table cellpadding="0" cellspacing="4">
                                                       {section name=product loop=$products}  
                                                                 <tr>
                                                               
                                                                    <td class="noTDpadding" valign="top">
                                                                        <input type="radio" class="chkcss" value="{$products[product].id}" id="{$products[product].id}"  name="products" {if $post.products eq $products[product].id } checked
                                                                       {/if} onclick="checkAgreement(this.value)">  
                                                                   </td>
                                                              
                                                                    <td class="TDLitepadding"> 
                                                                        <label for="{$products[product].id}"><strong>{$products[product].name}&nbsp;{if $MEMBER_SHOWPRICE_MEMBERDEFAULT_PAGE eq 'true'}(${$products[product].price|string_format:"%.2f"}) {/if}</strong></label> 
                                                             
                                                                    </td>
                                                                                                        
                                                                   </tr>
                                                           {sectionelse}
                                                                     <tr>
                                                                        <td>
                                                                            <b>No additional products for sale at this time.</b>
                                                                        </td>
                                                                     </tr>
                                                           {/section}   
                                                  </table>
                                            </td>
                                         </tr>
                                      </table>
                                 </td>
                              </tr>
                          </table>
                      </td>
                     </tr>
                  </table>
                
                 {*<table cellpadding="10" cellspacing="0" width="100%">
                   <tr>
                      <td> <div style="border-bottom:solid 1px #ccc;width:100%;height:1px;overflow:hidden;clear:both;"></div></td>
                  </tr>
                 </table>*}
               
                  <table width="100%" cellpadding="0" cellspacing="0"  id="defaulttableAgreement">
                          <tr style="display:none" id="tragdisp">
                            <td><div id="agdisp" style="display:none"><label><b>Agreement </b><label class="star">*</label></label></div></td>
                          </tr>
                           <tr style="display:none" id="trdispAgree">
                                 <td>
                                      <div style="display:none;" id="agreement">
                                                    {php}
                                                        $filename=PHYSICAL_DIR."/templates/agreement.html";
                                                        if(file_exists($filename))
                                                          $handle=fopen($filename, 'r') or die('can not open file to read file');
                                                          while(!feof($handle))
                                                              {
                                                              if("\n"!=$handle || "\r\n"!=$handle)
                                                                echo fgets($handle);
                                                              }
                                                            fclose($handle);
                                                    {/php}
                                          </div>
                                                  
                                           <div id="dispAgree" style="display:none;"> <input type="radio"  class="chkcss" value="Agree" checked name="agreements" id="agreements"><strong>I Agree</strong>&nbsp;
                                                        <input type="radio" name="agreements"  class="chkcss" value="dotagree" id="agreements"><strong>Don't Agree</strong>
                                           </div>
                                               
                                  </td>
                          </tr>
                          <tr align="center">
                               <td>
                                    {if $productlen>0}<input class="normal-button" type="submit" id="submit"   name="submit" value="Subscribe">{/if}
                                          
                                </td>
                          </tr> 
                  </table>
               </form> 
            <br> 
                <center><h3>Your Payment History</h3></center>
            <br>
                 <table width="98%" align="center" cellpadding="3" cellspacing="0"  class="gridPayment">
                    <tbody>
                       <tr>    
                          <th>Product</th>
                          <th colspan="3" class="payment">Period</th>
                          <th style="display:none;">Payment System</th>
                          <th>Amount</th>
                       </tr>
                       {section name=paymentid loop=$payment}
                          <tr class="gridPaymenttr">
                              <td class="gridPaymentnametd">{$payment[paymentid].name}
                              </td>
                               <td nowrap="nowrap" class="gridPaymentPeriodDatetd">{$payment[paymentid].fromdate|date_format:"%Y/%m/%d "}</td>
                               <td nowrap="nowrap" class="gridPaymentPeriodTOtd">To</td>
                                <td nowrap="nowrap" class="gridPaymentPeriodLifetimetd">{if $payment[paymentid].islifetime eq '1'}LIFETIME{else} {$payment[paymentid].uptodate|date_format:"%Y/%m/%d "}{/if}</td>
                                <td style="display:none;">
                                       {$payment[paymentid].paygear_paymentgetway|default:'N/A'}
                                </td>
                                <td class="gridPaymentPricetd">${$payment[paymentid].amount|string_format:"%.2f"}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </td>

                            </tr>
                       {sectionelse}
                          <tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>No Data found</td><td>&nbsp;</td></tr>
                       {/section} 
                      </tbody>
                  </table> 
         </div>
      </div>
      <div id="formlayout-bottom"></div>
          
 </div>  
   
 {literal} 
   <script language="JavaScript" type="text/javascript">
      var $j = jQuery.noConflict();  
      var subscriptionstatus='{/literal}{$emailsubscription}{literal}';
      var productsLen='{/literal}{$productlen}{literal}'; 
      
      var frmunscubValidation =new Validator("frmUnsubscribe");
      frmunscubValidation.EnableMsgsTogether();
      if(subscriptionstatus=="0")
            frmunscubValidation.addValidation("unsubscribechk","shouldselchk=on","Please select unsubscribe.");  
      else
          frmunscubValidation.addValidation("subscribechk","shouldselchk=on","Please select subscribe.");  
           
     if(productsLen>0)
     {
        var frmvalidatorMember  = new Validator("frmvalidatorMember");
       frmvalidatorMember.EnableMsgsTogether();
       frmvalidatorMember.addValidation("products","selone_radio","Please select product.");  
     }
      function checkAgreement(product)
               {
                       document.getElementById('agreements').checked = false;

                       var dataString = 'products='+ product;
                       var products=product;
                       
                       var web_url='{/literal}{$WEB_URL}{literal}';    
                       $j.ajax({
                           type: "POST",
                           url: web_url+"/includes/agreementavailableMember.php",
                           datatype: 'html',
                           data: dataString,
                           success: function(msg)
                           {
                               var filtermsg=ltrim(rtrim(msg));
                               
                               if(filtermsg=='yes')
                                {
                                 
                                       $j('#tragdisp').show();
                                      $j('#trdispAgree').show();
                                       $j('#agreement').show(); 
                                       $j('#agdisp').show(); 
                                       $j('#dispAgree').show(); 
                                       frmvalidatorMember.addValidation("agreements","shouldselchk=Agree","Please read the agreement and click on I Agree.");   
                                
                                
                                } 
                              else if(filtermsg=='no')
                               {
                                       document.getElementById('agreements').checked=true;
                                       
                                       $j('#tragdisp').hide();
                                       $j('#trdispAgree').hide();
                                       $j('#agreement').hide(); 
                                       $j('#agdisp').hide(); 
                                       $j('#dispAgree').hide(); 
                                       


                               
                               }   
                             
                          }
                     
                     
                       });  
                        
                 
                 
               
               }   
        
        
         $j(document).ajaxStart($j.blockUI).ajaxStop($j.unblockUI);           
      
                
         function EnabledDisableForm(pFormName, ElementsToExclude)
            {
                          var mySplitResult = ElementsToExclude.split(","); 
                          var frm=document.getElementById(pFormName);
                           for (i=0; i<frm.length; i++)
                            {            
                                        doc = frm.elements[i]; 
                                        var type = doc.type;
                                        for(j = 0; j < mySplitResult.length; j++){
                                            if(mySplitResult[j]==type)
                                            {
                                                 doc.disabled=true;
                                                 if(mySplitResult[j]=="button" || mySplitResult[j]=="submit")
                                                  {
                                                     doc.className='btndisabled';
                                                  }  
                                               }
                                        }
                                 
                                  }
                                  
                           return true;               
                       
            } 
            
      
                   
            
     </script>          
 {/literal}                
Return current item: MembersGear