Exemplo n.º 1
0
header('Last-Modified: ' . date('r'));
header("Cache-Control: no-store, no-cache, must-revalidate");
header("Pragma: no-cache");
// Page gentime start
$starttime = explode(' ', microtime());
$starttime = $starttime[1] + $starttime[0];
// Load libs
include 'modules/engine/api.mysql.php';
include 'modules/engine/api.lightastral.php';
include 'modules/engine/api.compat.php';
include 'modules/engine/api.signup.php';
$dbConnect = new MySQLDB();
$signup = new SignupService($snConfig['confcache'], $snConfig['cachetimeout']);
//show form by default
if (!la_CheckPost(array('createrequest'))) {
    if (!la_CheckGet(array('success'))) {
        show_window('', $signup->renderForm());
    } else {
        show_window(__('Thank you'), __('Your inquiry will be dealt with in the shortest possible time, and you will be contacted by our representative for details of connection.'));
    }
} else {
    //or create request
    $request = $signup->createRequest();
    if ($request) {
        rcms_redirect("?success=yeah");
    } else {
        show_window(__('Error'), __('All fields marked with an asterisk (*) are required') . '. ' . la_Link('index.php', __('Try again')));
    }
}
if ($snConfig['debug']) {
    // Page gentime end
Exemplo n.º 2
0
 $userData = zbs_UserGetStargazerData($user_login);
 //Check for user active state
 if ($userData['Passive'] == 0 and $userData['Down'] == 0) {
     $megogo = new MegogoFrontend();
     $megogo->setLogin($user_login);
     //try subscribe service
     if (la_CheckGet(array('subscribe'))) {
         $subscribeResult = $megogo->pushSubscribeRequest($_GET['subscribe']);
         if (!$subscribeResult) {
             rcms_redirect('?module=megogo');
         } else {
             show_window(__('Sorry'), __($subscribeResult));
         }
     }
     //  try unsubscribe service
     if (la_CheckGet(array('unsubscribe'))) {
         $unsubscribeResult = $megogo->pushUnsubscribeRequest($_GET['unsubscribe']);
         if (!$unsubscribeResult) {
             rcms_redirect('?module=megogo');
         } else {
             show_window(__('Sorry'), __($unsubscribeResult));
         }
     }
     //view button if is some subscriptions here
     if ($megogo->haveSubscribtions()) {
         show_window(__('Your subscriptions'), $megogo->renderSubscribtions());
         show_window('', la_Link($megogo->getAuthButtonURL(), __('Go to MEGOGO'), true, 'mgviewcontrol'));
         show_window('', la_tag('br'));
     }
     //default sub/unsub form
     show_window(__('Available subscribtions'), $megogo->renderSubscribeForm());
Exemplo n.º 3
0
                        } else {
                            $userAgentData = array();
                        }
                        $documents->setCustomFields();
                        $templateData = array_merge($templateData, $documents->getCustomFields(), $userAgentData);
                        //parse document template
                        $docx = new DOCXTemplate($fullPath);
                        $docx->set($templateData);
                        $docx->saveAs($saveFullPath);
                        //register document
                        $documents->registerDocument($user_login, $templateId, $saveFileName);
                        //output
                        zbs_DownloadFile($saveFullPath, 'docx');
                    }
                } else {
                    show_window(__('Sorry'), __('This template is not accessible'));
                }
            } else {
                show_window(__('Sorry'), __('Not existing template'));
            }
        }
    }
    //show docs list
    show_window(__('Previous documents'), $documents->renderUserDocuments());
    //document downloading subroutine
    if (la_CheckGet(array('documentdownload'))) {
        $documents->downloadUserDocument($_GET['documentdownload']);
    }
} else {
    show_window(__('Sorry'), __('Unfortunately documents printing is now disabled'));
}