Revision 296 (by ahitrov, 2013/03/26 17:59:01) Promosite (anthill) project source
% if ( $m->comp_exists ("/comps/$prj/header.msn") ) {
<& "/comps/$prj/header.msn", alias => 'main' &>
% } else {
<& "/comps/header.msn", alias => 'main' &>
% }


<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr valign="top"><td style="padding:0 32px 0 18px;" width="1%" nowrap>
<!--Menus-->
% if ( $m->comp_exists ("/comps/$prj/left.msn") ) {
<& "/comps/$prj/left.msn" &>
% }
<!--/Menus-->
</td>

<td width="1%"><img src="/i/<% $prj %>/diaton_device.png" width="84" height="334" alt="DIATON tonometer"></td>
<td style="padding:0 30px 20px;" width="98%">
<!--Information-->
<h2><% ref $document ? $document->name : $section->name %></h2>


% if ( ref $document ) {
%	my $video = $document->get_image('file');
%	if ( ref $video && exists $video->{filename} ) {
%		if ( $video->{ext} eq 'avi' || $document->attype eq 'avi' ) {
<div style="padding:10px 20px;">
<OBJECT id=NSPlay codeBase=http://www.microsoft.com/netshow/download/en/nsasfinf.cab#Version=2,0,0,912 
classid=CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95 width="480" height="404" VIEWASTEXT>
<PARAM NAME="ControlType" VALUE="0">
<PARAM NAME="filename" VALUE="<% $video->{filename} %>">
<PARAM NAME="AutoStart" VALUE="false">
<PARAM NAME="AnimationStart" VALUE="true">
<PARAM NAME="TransparentAtStart" VALUE="false">
<PARAM NAME="AutoRewind" VALUE="false">
<PARAM NAME="ShowControls" VALUE="true">
<!--NETSCAPE PLUG-IN STARTS HERE--><embed type="video/x-ms-asf-plugin" src="videos/bg_small.avi" 
pluginspage="http://www.microsoft.com/windows/mediaplayer/download/default.asp"
controltype="1" autostart="false" transparentatstart="false"
animationatstart="true" autorewind="false" width="480" height="404"
filename="<% $video->{filename} %>" animationstart="true" showcontrols="true"></embed>
</OBJECT>
</div>
%		}
%	}
% }


<!--/Information-->
</td></tr>
</table>



% ### Футер
% ##############################################
% if ( $m->comp_exists ("/comps/$prj/footer.msn") ) {
<& "/comps/$prj/footer.msn" &>
% } else {
<& "/comps/footer.msn" &>
% }
% ### /Футер
<%args>

        $p      => 1
        $id     => undef

</%args>
<%init>

  my $prj = $request->{project};
  my $profile = $request->{project_profile};
  my $root = $request->{project_section};
  &abort404     if $id && $id !~ /^\d+$/;

  my $document;
  my ($section) = $keeper->get_sections (
		s	=> $root->id,
		class	=> 'promosuite::MultimediaSection',
		alias	=> 'video',
		limit	=> 1,
		status	=> 1,
	);
  if ( ref $section ) {
	($document) = $keeper->get_documents (
		s	=> $section->id,
		class	=> 'promosuite::Multimedia',
		status	=> 1,
		limit	=> 1,
        );
  }
</%init>