############################################################################### # PROGRAM : DOPAYS # # VERSION : 2.64.87 # # AUTHOR : Dmitry Pereuda # # COPYRIGHTS : DOSWARE TEAM # # # # RELEASED BY : WDYL-WTN # ############################################################################### # All source code, images, programs, files included in this distribution # # Copyright (C)2003 DOSWARE TEAM. All Rights Reservded. # ############################################################################### # While we distribute the source code for our scripts and you are allowed to # # edit them to better suit your needs, we do not support modified code. # # Please see the license prior to changing anything. You must agree to the # # license terms before using this software package or any code contained # # herein. # ############################################################################### # Any redistribution without permission of Dmitry Pereuda (DOSWARE TEAM) is # # strictly forbidden. # ############################################################################### $data['PageName']='MERCHANT AREA (YOUR SUBSCRIPTIONS)'; $data['PageFile']='subscriptions'; ############################################################################### include('../config.htm'); ############################################################################### if(!$_SESSION['login']){ header("Location:{$data['Host']}/index.htm"); echo('ACCESS DENIED.'); exit; } if(is_info_empty($uid)){ header("Location:{$data['Host']}/members/profile.htm"); echo('ACCESS DENIED.'); exit; } ############################################################################### $post=select_info($uid, $post); if(!$post['step'])$post['step']=1; $post['Buttons']=get_files_list($data['SubBtnsPath']); ############################################################################### if($post['send']){ if($post['step']==1){ $post['step']++; }elseif($post['step']==2){ if(!$post['name']){ $data['Error']='Please enter name of product or service.'; }elseif(!$post['price']){ $data['Error']='Please enter valid price for a product or service.'; }elseif($post['price']<$data['PaymentMinSum']){ $data['Error']= "Price for product or service can not be less than". " {$data['Currency']}{$data['PaymentMinSum']}"; }elseif(!$post['period']){ $data['Error']='Please enter period value.'; }elseif($post['period']<=0){ $data['Error']='Period should be more than 0.'; }elseif(!$post['ureturn']){ $data['Error']='Please enter valid URL for return after transaction.'; }elseif(!$post['button']){ $data['Error']='Please choose the image for payment button.'; }else{ if(!$post['gid'])insert_product($uid, 1, $post); else update_product($post['gid'], $post); $post['step']--; } } }elseif($post['cancel'])$post['step']--; if($post['action']=='update'){ $product=select_products($uid, 1, $post['gid'], true); foreach($product[0] as $key=>$value)if(!$post[$key])$post[$key]=$value; $post['actn']='update'; $post['step']++; }elseif($post['action']=='delete'){ delete_product($post['gid']); }elseif($post['action']=='cancel'){ cancel_subscription($post['gid']); }elseif($post['action']=='generate'){ $product=select_products($uid, 0, $post['gid'], true); $product=$product[0]; $post['HtmlCode']=htmlspecialchars( "\n". "
\n". "", ENT_QUOTES ); $post['PostSent']=true; } if($post['step']==1){ $data['Products']=select_products($uid, 1); $data['Subscriptions']=select_subscriptions($uid); } ############################################################################### display('members'); ############################################################################### ?>