#include ../../../../includes/wp-spa-header.iphtml #include ../includes/abstract_header.iphtml remote_user(); print "

$society Electronic Poster Submission

"; my %States=0; my $Current_Screen=0; %States = ( 'Default' => \&first_page, 'Submit my Poster(s)' => \&upload_page, ); $Current_Screen = $main::cgi->param('Submit') || "Default"; die "No screen for $Current_Screen" unless $States{$Current_Screen}; print start_form(-name=>'emailsubmit', -enctype=>'multipart/form-data'); while (my($screen_name, $function) = each %States) { $function->($screen_name eq $Current_Screen); } print end_form(); sub first_page { my $active = shift; return unless $active; $SQL = "select concat(poster_prefix,\"-\",poster_number) as pn, chair_abstracts.title, poster_submission.submitted, chair_abstracts.abstractid from chair_abstracts,sessions,session_info,primary_contacts,abstracts,poster_submission where abstracts.abstractID=chair_abstracts.abstractid and abstracts.abstractID=sessions.abstractID and chair_abstracts.abstractid=sessions.abstractID and chair_abstracts.abstractid=poster_submission.abstractID and sessions.sessionID=session_info.session_id and accepted=\"Yes\" and primary_contacts.username=abstracts.contactID and primary_contacts.username=\"$user\" order by pn"; my $cursor = $main::dbh->prepare($SQL); $cursor->execute; my @fields; my $access = 0; my $loopcount=0; while (@fields = $cursor->fetchrow) { if ($fields[0]) { $access = 1; if (!$loopcount) { ######### Page header / instructions goes here print ""; } } print ""; } if ($fields[2] eq "y") { print "Poster has been submitted - Thank you!
"; print "Click here to view your submitted poster file
"; print "If you wish to replace this file, please enter it below:
"; print "Upload replacement file:
Only enter a file if you wish to REPLACE the file previously uploaded!"; } $loopcount++; } $cursor->finish; undef(@fields); if (!$access) { print "You did not submit any abstracts that were accepted for this meeting. Please contact the Abstract Administrator with any questions."; } else { print "
"; print qq {

DIGITAL POSTER REQUIREMENTS

  • Submission deadline is February 13, 2017
  • You MUST create your poster in PowerPoint (or other program) using the 16:9 aspect ratio resolution setting in landscape format.
  • Save your poster slide as a one-page .PDF file that includes the author's name, last name first, and poster title.
  • The filename of your PDF will be auto-converted to the poster number once it is uploaded, but please make sure that your file's name starts with a letter or a number (no symbols) and ends in .pdf or .PDF for the upload system to recognize it.

DIGITAL POSTER SUGGESTIONS

  • Use a Sans Serif Font (Arial, Calibri, Tahoma, Verdana) with a point size no smaller than 5.
  • Avoid long sections of text.
  • Be sure that all graphs, charts, and images are readable.
  • Click here for a sample poster

Your accepted abstract(s) with poster number(s) are below. Please upload your poster files associated with each abstract if you have not already done so.

You do not need to upload all posters at once if you have more than one to submit - you will be able to return to this upload page. }; print "


".$fields[0]." - ".$fields[1]."
" ; if ($fields[2] eq "n") { print "Poster has not been submitted yet - please enter a file below:
"; print "Upload poster file:
"; print p{align=>'center'},(to_page("Submit my Poster(s)")); } } sub upload_page { my $active = shift; return unless $active; if($ENV{REQUEST_METHOD} eq 'POST' && $ENV{CONTENT_LENGTH} > $maxbytes) { print "

Error: The files you are attempting to upload exceed the total maximum allowable file size of $maxmb MB."; } else { $SQL = "select concat(poster_prefix,\"-\",poster_number) as pn, chair_abstracts.abstractid, submitted from chair_abstracts,sessions,session_info,primary_contacts,abstracts,poster_submission where abstracts.abstractID=chair_abstracts.abstractid and abstracts.abstractID=sessions.abstractID and chair_abstracts.abstractid=sessions.abstractID and chair_abstracts.abstractid=poster_submission.abstractID and sessions.sessionID=session_info.session_id and accepted=\"Yes\" and primary_contacts.username=abstracts.contactID and primary_contacts.username=\"$user\" order by pn"; my $cursor = $main::dbh->prepare($SQL); $cursor->execute; my @fields; while (@fields = $cursor->fetchrow) { if ($main::cgi->param('file-' . $fields[0])) { my $bytesread; my $buffer; my $length; my $fp; my $upload_error=0; my $filename=$main::cgi->param('file-' . $fields[0]); ###Check for legal filename # print "FILENAME: $filename"; $filename =~ s/[^\w.-]/_/g; if ( $filename =~ /^(\w[\w.-]*(\.pdf$|\.PDF$))/) { $filename = $1; } else { print "

Error: File for abstract $fields[0] is not in PDF format or filename does not start with a letter or number.
"; $upload_error=1; } my $newfilename = $fields[1]."--".$fields[0] . ".pdf"; unlink("./uploads/$newfilename"); ### Actualy upload the file if (!$upload_error) { # if no errors upload file open (OUTFILE, ">./uploads/$newfilename") or die("Cannot Open File: ./uploads/$newfilename"); flock(OUTFILE, 2); $fp=$main::cgi->upload('file-' . $fields[0]); # while ($bytesread=read($filename,$buffer,1024)) while ($bytesread=read($fp, $buffer, 1024)) { print OUTFILE $buffer; $length += $bytesread; # if ($length>3000000) { # print "
Error: File for abstract $fields[0] is too large
"; # unlink "./uploads/$filename"; # $upload_error=1; # } # last if ($length>3000000); } close OUTFILE; print "
File for abstract $fields[0] uploaded successfully
"; my $SQL2 = "update poster_submission set submitted=\"y\" where abstractID=\"".$fields[1]."\""; my $cursor2 = $main::dbh->prepare($SQL2); $cursor2->execute; $cursor2->finish; } } else { if ($fields[2] eq "n") { print "
No file specified for abstract ".$fields[0]."
"; } } } $cursor->finish; undef(@fields); } print "
Click here to go back to the poster upload page
"; } sub to_page { submit(-NAME => "Submit", -VALUE => shift) } # $main::dbh->disconnect; !> #include ../includes/abstract_footer.iphtml #include ../../../../includes/wp-spa-footer.iphtml