#!/usr/bin/perl -I../../../.. package Pos::Webtop::Web::OEM::1; use strict; use Pos::Webtop::Toolbox (); use Pos::Webtop::OcxLauncher(); use POSIX; # --------------------------------------------------------------- # OEM #1 # Positive Networks HTML Framework # --------------------------------------------------------------- sub new { my $this = shift; my $class = ref($this) || $this; my $self; my ($oemId) = @{{@_}}{qw/oemId/}; if ( not defined $self ) { $self = {}; bless($self,$class); } $self->{'oemId'} = $oemId; return $self; } sub setOemInformation { my $self = shift; my ($id, $name, $rebrandName, $short, $vpnProductName, $webtopProductName, $customerServiceUrl, $customerServicePhone, $learnMoreUrl, $installerPath, $webtopUrl, $gettingStartedUrl, $helpUrl, $supportEmail, $domain, $webtopTutorialUrl, $clientTutorialUrl, $pmTutorialUrl, $oemWebtopContactUrl, $oemNetconInstallerPath, $oemNetworkConnectorName, $webtopSupportToolLink, $webtopInstallerPath) = @{{@_}}{qw/id name rebrandName short vpnProductName webtopProductName customerServiceUrl customerServicePhone learnMoreUrl installerPath webtopUrl gettingStartedUrl helpUrl supportEmail domain webtopTutorialUrl clientTutorialUrl pmTutorialUrl webtopContactUrl netconInstallerPath networkConnectorName webtopSupportToolLink webtopInstallerPath/}; $self->{'id'} = $id; $self->{'name'} = $name; $self->{'rebrandName'} = $rebrandName; $self->{'short'} = $short; $self->{'vpnProductName'} = $vpnProductName; $self->{'webtopProductName'} = $webtopProductName; $self->{'customerServiceUrl'} = $customerServiceUrl; $self->{'customerServicePhone'} = $customerServicePhone; $self->{'learnMoreUrl'} = $learnMoreUrl; $self->{'installerPath'} = $installerPath; $self->{'webtopUrl'} = $webtopUrl; $self->{'gettingStartedUrl'} = $gettingStartedUrl; $self->{'helpUrl'} = $helpUrl; $self->{'supportEmail'} = $supportEmail; $self->{'domain'} = $domain; $self->{'webtopTutorialUrl'} = $webtopTutorialUrl; $self->{'clientTutorialUrl'} = $clientTutorialUrl; $self->{'pmTutorialUrl'} = $pmTutorialUrl; $self->{'webtopContactUrl'} = $oemWebtopContactUrl; $self->{'netconInstallerPath'} = $oemNetconInstallerPath; $self->{'networkConnectorName'} = $oemNetworkConnectorName; $self->{'webtopSupportToolLink'} = $webtopSupportToolLink; $self->{'webtopInstallerPath'} = $webtopInstallerPath; return 1; } sub getSetting { my $self = shift; my $setting = @{{@_}}{qw/setting/}; return $self->{$setting}; } sub getHtmlHeader { my $self = shift; my ($title,$isLogin) = @{{@_}}{qw/title isLogin/}; my $tb; my $launcherJs = ""; if (not defined($title)) { $title = ""; } $isLogin = 0 unless defined $isLogin; if (!$isLogin) { $tb = Pos::Webtop::Toolbox->new(); $launcherJs = Pos::Webtop::OcxLauncher::getLauncherHtml( tb=>$tb ); } my $oemStylesheetFileVersion = Pos::Webtop::Web::OEMLoader::getStylesheetFileVersion(oemId=> $self->{'oemId'}); return "Content-type: text/html\n\n
";
}
sub printBodyContent
{
my $self = shift;
my ($mode,$desc,$b1,$isMobile) = @{{@_}}{qw/mode desc b1 isMobile/};
if( defined $mode and $mode eq 'vpn')
{
print "
Please sign on to download the PositivePRO VPN client software. "; } elsif( defined $mode and $mode eq 'netcon' ) { print " Please sign on to download the PositivePRO Network Connector software. "; } elsif( $isMobile ) { } else { print " "; } if ( defined $desc ) { print "$desc "; } !$isMobile and print $b1->getHeaderHtml(); if (!$isMobile) { print " "; } print " ";
if ( defined $err )
{
print "$err";
}
else
{
print "
Please enter your username and password.";
}
print " |
|||||||||||
|
|||||||||||
|
";
if ($isMobile)
{
my @menu = split(/\|/,$menu);
$ret .= "" . (defined($wmenu) ? "$wmenu" : "" ) . " $menu[0] | $menu[1] | $menu[2]"; } else { $ret .= "" . ( defined($wmenu) ? "$wmenu|" : "" ) . "$menu"; } $ret .=" |
\ \ $smenu |