?
Solved

Calling .pm files on Windows server

Posted on 2006-05-31
27
Medium Priority
?
566 Views
Last Modified: 2012-05-05
I am asking the exact question that has already been asked under the same title:  "Calling .pm files on Windows server."

I have tried the solution given, appropriately adjusting the path to my own specifications.  And now I get this error message:

Software error:

Can't locate jcgi.pm in @INC (@INC contains: d:Websiteswww.(edited).calendar2 D:/Perl/lib D:/Perl/site/lib .) at D:\Websites\www.(edited).ca\calendar2\index.cgi line 6.

The script is running on Windows 2003 ASP.NET 1.0/2.0 server with IIS is 5.2.



0
Comment
Question by:piano_fantasy
  • 11
  • 7
  • 4
  • +3
27 Comments
 
LVL 9

Expert Comment

by:Suhas .
ID: 16796753
Hi piano_fantasy,

add the path where you stored jcgi.pm in @INC


Cheers!
Suhas
0
 

Author Comment

by:piano_fantasy
ID: 16796756
I think I had the slashes the wrong way... fixed that!  Now I get this:

----------------------------
CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers.
------------------------------

Here is what the beginning of index.cgi looks like:

#!D:\\Perl\\bin\\Perl.exe
use CGI::Carp qw(fatalsToBrowser);
use utf8;
use lib "d:/Websites/www.(edited).ca/calendar2";

require jcgi ;
require jconfig ;
require calendar ;
require dataaccess ;
require language ;

&jconfig::loadConfig() ;

$version = "2.8" ;
0
 
LVL 9

Assisted Solution

by:Suhas .
Suhas . earned 120 total points
ID: 16796771
try this...

use lib "d:\/Websites\/www.(edited).ca\/calendar2";

0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:piano_fantasy
ID: 16796794
Hi Suhas,

I really don't know anything about Perl... I had tried what the previous solution had said and how get the HTTP header error!  As you can see above, I added use lib "d:/Websites/www.(edited).ca/calendar2"; to the beginning of the index.cgi script.   Has this corrected the error that I was getting?  Even though I'm now getting a different error message?  

How do I add the path where you stored jcgi.pm in @INC as you say to do?

Thanks.
0
 

Author Comment

by:piano_fantasy
ID: 16796816
I tried the double slashes with the same HTTP header error result.

CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers.
0
 
LVL 9

Expert Comment

by:Suhas .
ID: 16796845
@INC is the path where all perl modules to be stored.

else you have to add your own path to @INC.

Run this perl file:

foreach  (@INC) {
    print $_."\n";
}

there you find the different paths, copy the perl module jcgi.pm in any one of the path.

Then your module jcgi.pm will work.
0
 

Author Comment

by:piano_fantasy
ID: 16796904
Suhas,

I think you are underestimating my abilities.  How do I run the perl file on the server?  And when I figure out the paths, is this something I will be able to change , or does my web host have to do it?

Thanks.
C.
0
 
LVL 28

Expert Comment

by:FishMonger
ID: 16799457
>> use lib "d:/Websites/www.(edited).ca/calendar2";

Do you actually have a directory on your server with that path?  I doubt it.  Change the path to the true system directory path to the module.


>> #!D:\\Perl\\bin\\Perl.exe

would be better written as:

#!D:/Perl/bin/Perl.exe
0
 
LVL 39

Assisted Solution

by:Adam314
Adam314 earned 345 total points
ID: 16799806
This error:
CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers.

means that the first thing printed by your script was not an HTTP header.  The first thing your app needs to print is always a header.  You can check your error log for more info about what happened.  In the portion of the code you posted, I don't see anywhere a header is printed.  Make sure nothing is printed before the header.

To print a header:
    use CGI qw/:standard/;
    print header;
OR
    use CGI;                             # load CGI routines
    $q = new CGI;                        # create new CGI object
    print $q->header,                    # create the HTTP header
 


Also, if you add this to the top of your program (right after #!/usr/bin/perl), then any error and warning messages will be displayed in your browser, making it easier to debug.

use CGI::Carp qw(fatalsToBrowser warningsToBrowser);
0
 

Author Comment

by:piano_fantasy
ID: 16800522
Thank you Adam314,

Now I am getting somewhere.  The script is definately running (or at least part of it!) and I get this on the screen where I should only see the calendar.

--------------------------------------------------------
1-5-2006 2-5-2006 3-5-2006 4-5-2006 5-5-2006 6-5-2006 7-5-2006 8-5-2006 9-5-2006 10-5-2006 11-5-2006 12-5-2006 13-5-2006 14-5-2006 15-5-2006 16-5-2006 17-5-2006 18-5-2006 19-5-2006 20-5-2006 21-5-2006 22-5-2006 23-5-2006 24-5-2006 25-5-2006 26-5-2006 27-5-2006 28-5-2006 29-5-2006 30-5-2006 31-5-2006 [Wed May 31 11:08:49 2006] index.cgi: Wide character in print at D:\Websites\www.(edited).ca\calendar2\index.cgi line 427. Content-type: text/html;charset=UTF-8

(followed by the calendar)
-------------------------------------------------------
NOTE:  When I click on a date inside the calendar I also get another HTTP header error.  Do I need to change the headers on any other files?

Here is a list of all the files the script needs to run:
index.cgi
viewday.cgi
calendar.db
empty.db
bot.html
readme.html
top.html
calendar.pm
dataaccess.pm
dnfunc.pm
jcgi.pm
jconfig.pm
language.pm
convert.pl
faq.txt
addevent/addevent.cgi
addevent/editevent.cgi
addevent/addevent.html
addevent/editevent.html
addevent/.addevent.cgi.swp
css/calendar.css
images/add.gif
images/delete.gif
images/edit.gif
images/next.gif
images/previous.gif

Here is the index.cgi code:
#!D:\\Perl\\bin\\Perl.exe
use CGI::Carp qw(fatalsToBrowser warningsToBrowser);
use CGI qw/:standard/;
    print header;
use utf8;
use lib "d:/Websites/www.(edited).ca/calendar2";

require jcgi ;
require jconfig ;
require calendar ;
require dataaccess ;
require language ;

&jconfig::loadConfig() ;

$version = "2.8" ;

#############################################################################
#Index.cgi
# $Id: index.cgi,v 1.16 2005/09/15 15:09:41 ecklesweb Exp $
# Copyright 2004 Jay Eckles
# This file is licensed under the GPL version 2 and is provided without warranty.  
# See http://www.gnu.org/copyleft/gpl.html for license details.
#    CSS class names used in HTML Copyright Isaac McGowan, used under GPL.
#
# This cgi script is used as a part of the CGI Calendar system, a collection
# of perl scripts and modules with the purpose of creating a web-based
# group event calendar.  
#
# This script's job is to build a calendar in the form of an html table,
# including in the cell for each day any events found for that date in the
# calendar database.
#
# Which month and year should be loaded is communicated to the script via
# CGI communication.  The following is a list of the name and value pairs that
# Index.cgi must receive; the order in which they must be received is of
# no importance.
# If a name/value pair is optional, it is listed in square brackets ([]).
# if multiple values are possible for a name, all optional values are
# listed in parentheses (()), and spearated by pipes (|)
#
# month=an integer greater than or equal to 1 and less than or equal to 12
# year=a positive integer
#
# These name/value pairs may be passed to the cgi program using either the
# GET or POST methods.  The information is retrieved by calling a function
# found in the cgi.pm module.  
#
# The generation of the calendar is accomplished by first finding the number
# of days in the month and the day of the week on which the month starts
# by calling functions provided by calendar.pm.  Then, an html table is
# constructed with 7 columns, and as many rows as necessary to fill out
# the calendar.  As each cell is created, the database is queried for events
# happening on the day that cell corresponds with - this is done by using the
# &dnfunc::dn_select function of dnfunc.pm.  
#
# Originally authored by Jay Eckles <j.eckles@computer.org>.  
# Contributors:
#     Many people from comp.infosystems.www.authoring.cgi - debugging tips,
#        many feature ideas, help in pointing out errors and poor code, etc.
#     Ken MacCuish <ken@pwhinc.com> - modified code to highlight the cell of the
#        table containing the current day with a color defined by the variable
#        $cell_today_color and any day with an event with a color defined by
#        the variable $cell_active_color
#
# $Log: index.cgi,v $
# Revision 1.16  2005/09/15 15:09:41  ecklesweb
# bug fix for multiple calendar databases
#
# Revision 1.15  2005/04/19 02:47:56  ecklesweb
# change comments to license specifically under v2 of GPL
#
# Revision 1.14  2005/04/14 01:49:12  ecklesweb
# final 2.7 commits?
#
# Revision 1.13  2005/04/14 01:31:44  ecklesweb
# change way dates are represented so events can be shared across languages
#
# Revision 1.12  2005/04/14 01:16:47  ecklesweb
# remove print to STDERR, add use utf8 to .pm's
#
# Revision 1.11  2005/04/13 23:14:48  ecklesweb
# send UTF-8 content type header
#
# Revision 1.10  2005/04/02 23:47:31  ecklesweb
# added french, added language dropdown to index.cgi
#
# Revision 1.9  2005/04/01 01:58:35  ecklesweb
# utf-8 fix
#
# Revision 1.8  2005/04/01 01:51:29  ecklesweb
# multilingual enhancements
#
# Revision 1.7  2005/03/30 23:51:26  ecklesweb
# multilingual enhancements
#
# Revision 1.6  2005/02/25 01:34:52  ecklesweb
# finalizing 2.6 changes
#
# Revision 1.5  2004/11/27 19:18:16  ecklesweb
# ID and Log tags in index.cgi and calendar.pm
#
################################################################################

#initialize the language::monthnames and day lists

#retrieve the name/value pairs by using a cgi.pm function
@input = &jcgi::retrieve_input() ;
%input = %jcgi::in ;

$lang = $jcgi::in{"lang"} ;
if( $lang eq "" ){
   $lang = $jconfig::value{"defaultLanguage"} ;
}
if( $lang eq "" ){
   $lang = "en-us" ;
}

&language::loadText( $lang ) ;

#filename of the calendar database
&dataaccess::set_datasource( $jcgi::in{"db"}  );
$dbname = $jcgi::in{"db"} ;


$month = $input{"month"} ;
$year = $input{"year"} ;

#if no month or year is given, then use the current month or year according to the
#system clock.
@timelist = localtime( time() ) ;
if( $month eq "" ) {
   $month = $timelist[4] + 1 ;
}
if( $year eq "" ) {
   $year = $timelist[5]+1900 ;
}
$dayofmonth = $timelist[3] ;
$curmonth = $timelist[4]+1 ;
$curyear = $timelist[5]+1900;

#determine the language::monthname by using $month as an index to the language::monthnames list.
$language::monthname = $language::monthnames[$month-1] ;
$monthyear = $language::monthname.$year ;

#determine how many days are in the given month and on what day of the week
#that month starts.  These functions are provided by calendar.pm
$days_in_month = &calendar::days_in_month( $month, $year ) ;
$monthstart = &calendar::month_start( $month, $year ) ;

   
################Start creating the table that will be the calendar.####################

#the html code for the table will be stored as a string in the scalar variable $table
$table = "<tr>\n" ;

# print top row of calendar which holds days of week
for( $i=0; $i < 7; $i++ ){
   $table = $table."<td class=column_header>$language::day[$i]</td>\n" ;
}

# next row
$table = $table."<tr>\n" ;

# skip the appropriate number of days as indicated by the calendar::monthstart function
for( $i=0; $i < $monthstart; $i++ ){
   $table = $table."<td class=empty_day_cell></td>\n" ;
}

# in day_of_week, Sunday is 0, Saturday is 6.
$day_of_week = $monthstart ;

#now, we have got the table to the point where we know what day of the week we're on and
#we know that the next cell is the 1st of the month.  We can now start creating the cells
#for the days which means we begin to look for events in the database.

#$current_day is the day of the month we are currently working on
$current_day = 0 ;
# this loop creates the individual day cells on the calendar.
for( $i=1; $i <= $days_in_month ; $i++ ){
   $current_day++ ;
# find out if it's a new week and we need to start a new row
   if( !( $day_of_week % 7 ) ){
      $table = $table."<tr>\n" ;
   }


#create a key based on the date given...key is in format dd-mm-yyyy
   $key = $i."-".$month."-".$year ;

#retrieve the information for that day from the calendar database  
   &dataaccess::open_database() ;
   
   @events = () ;
   
#print STDERR "events contains @events items\n" ;
   
#print STDERR "key is $key\n" ;
   
   @events = &dataaccess::get_events( $key ) ;
   
#print STDERR "events now contains @events items\n" ;
### sort the events/times by time
#   @events = &calendar::eventsort( @events ) ;
   @events = sort calendar::timeCompare @events ;
   
   @daysevents = () ;
   @times = () ;
   foreach $event (@events){
      push( @daysevents, $event->{'summary'} ) ;
      push( @times, $event->{'when'} ) ;
   }
   
# hilite the cell if it is today or there is an activity today
###begin Ken's code later modified by Jay###
   if ($i eq $dayofmonth && $curmonth eq $month && $year eq $curyear){
      $cellcolor="class=today_cell"
   }
   elsif( @daysevents > 0 ){
      $cellcolor="class=populated_day_cell" ;
   }
   else{
      $cellcolor="class=day_cell";
   }
# create the cell, include the day of the month - link day to viewday.cgi  
   $table = $table."<td $cellcolor valign=top>
   <a href=\"viewday.cgi?lang=$lang&mode=all&month=$month&date=$current_day&year=$year&db=$dbname\" class=day_number>$current_day</a>
   <br>" ;
###end Jay's modifications of Ken's code###
# if there's anything on this day, put it in the day's cell.
   if( @daysevents > 0 ){
      for( $j=0; $j < @daysevents; $j++ ){    

####urlencode summary for transmission via get - encode from jcgi.pm
$enc_summary = &jcgi::encode( $daysevents[$j] ) ;
#link event to viewday.cgi
         $table .= "<a href=\"viewday.cgi?lang=$lang&mode=one&month=$month&date=$current_day&year=$year&summary=$enc_summary&db=$dbname\">";
# if there is a time, print the time after the summary of the event.  If
# there is no time given, don't print anything except the summary.
         if( $times[$j] =~ /^\D/ ){
            $table = $table."<span class=title_txt>$daysevents[$j]</span></a><br>\n" ;
         }
         else{
            $table = $table."<span class=title_txt>$daysevents[$j]</span></a> <br><span class=time_str>($times[$j])</span></a><br>\n" ;
         }
      }
   }
# close the cell
   $table = $table."</td>\n" ;
   $day_of_week = ($day_of_week + 1) % 7 ;
} #end of for loop: for( $i=1; $i <= $days_in_month ; $i++ )
#here, at the termination of the loop, we have created a cell for each day of the month.
#so we finish the table:
#$table = $table."</table>\n" ;

##loop through remaining days in last week to create empty cells...
$remaining_days = (7-$day_of_week) % 7 ;
for( $i=0; $i<$remaining_days; $i++ ){
   $table = $table."<td class=empty_day_cell></td>\n" ;
}
$table = $table."</tr>\n" ;

#create the form that will be at the top of the calendar to provide the "jump to month"
#functionality
$yearminus2 = $year - 2 ;
$yearminus1 = $year -1 ;
$yearplus1 = $year+1 ;
$yearplus2 = $year+2 ;
$yearplus3 = $year+3 ;
$form = "
<form action=\"index.cgi\" method=\"get\">
<input type=hidden name=db value=$dbname>
<input type=hidden name=lang value=$lang>
<select name=month class=month_select>
<option value=$month>$language::monthnames[$month-1]
<option value=1>$language::monthnames[0]
<option value=2>$language::monthnames[1]
<option value=3>$language::monthnames[2]
<option value=4>$language::monthnames[3]
<option value=5>$language::monthnames[4]
<option value=6>$language::monthnames[5]
<option value=7>$language::monthnames[6]
<option value=8>$language::monthnames[7]
<option value=9>$language::monthnames[8]
<option value=10>$language::monthnames[9]
<option value=11>$language::monthnames[10]
<option value=12>$language::monthnames[11]
</select>

<!--input type=text value=$year name=year size=4 class=year_input-->
<select name=year>
<option value=$yearminus2>$yearminus2
<option value=$yearminus1>$yearminus1
<option value=$year selected>$year
<option value=$yearplus1>$yearplus1
<option value=$yearplus2>$yearplus2
<option value=$yearplus3>$yearplus3
</select>

<input type=submit value=$language::govalue class=submit_button>
</form> " ;

######################################Print HTML########################################

#finally print the html page back to the client
#&jcgi::print_header function provided by cgi.pm
#append charset=UTF-8 so browsers will know to view multilingual pages as unicode and render properly
$type="text/html;charset=UTF-8" ;
&jcgi::print_header( "Content-type", $type ) ;

# if the calendar shown is January, then the previous month is December of
# the previous year (year-1).  Otherwise it is just the previous month of
# the same year (month-1)
if( $month == 1 ){
   $prevmonth = 12 ;
   $prevyear = $year-1 ;
}
else{
   $prevmonth = $month-1 ;
   $prevyear = $year ;
}
# similarly, if the calendar shown is December, the next month is January
# of the next year.  Otherwise it is month+1
if( $month == 12 ){
   $nextmonth = 1 ;
   $nextyear = $year + 1 ;
}
else{
   $nextmonth = $month+1 ;
   $nextyear = $year ;
}

$languageDropdown = "" ;
foreach $key (sort by_value keys %language::availableLanguages) {
   if( $key eq $lang ){
      $languageDropdown .= "<option value=$key selected>$language::availableLanguages{$key}\n" ;
   }
   else{
      $languageDropdown .= "<option value=$key>$language::availableLanguages{$key}\n" ;      
   }
}
sub by_value { $language::availableLanguages{$a} cmp $language::availableLanguages{$b}; }

#$calendarinfo holds the html code for the calendar, including the table and
#the form we created earlier
$calendarinfo = "
<div align=center>
<table border=1 cellpadding=2 cellspacing=0 class=calendar_table>
<tr>
<td colspan=7>
<table border=0 width=100%>
<tr>
<td class=arrows align=left><a
href=\"index\.cgi\?lang=$lang&month=$prevmonth&year=$prevyear&db=$dbname\" class=prev_month_link><img src=$jconfig::value{'prevGifUrl'} class=prev_month_image border=0 alt=$language::prevgifalt></a><a
href=\"index\.cgi\?lang=$lang&month=$nextmonth&year=$nextyear&db=$dbname\" class=next_month_link><img src=$jconfig::value{'nextGifUrl'} class=next_month_image border=0 alt=$language::nextgifalt></a>
</td>
<td class=date_header>
$language::monthname, $year
</td>
<td align=right valign=bottom class=date_nav_cell>
$form
</td>
</table>
</td></tr>

$table

<tr>
<td colspan=7 class=footprint>
<table border=0 cellpadding=0 cellspacing=0 width=100%>
<tr>
<td valign=middle align=left class=footprint>
<a href=\"http://cgicalendar.sourceforge.net\">CGI Calendar $version</a> by <a href=\"http\://www\.jayeckles\.com/\">Jay
Eckles</a>
</td>
<td align=right valign=top>
<form action=\"index.cgi\" method=\"get\" name=langform>
<input type=hidden name=db value=$dbname>
<input type=hidden name=month value=$month>
<input type=hidden name=year value=$year>
<select name=lang onChange=\"document.langform.submit();\">
$languageDropdown
</select>
</form>
</td>
</tr>
</table>
</td>
</table>
</div>
" ;
#end $calendarinfo =...

#that html code we just developed goes inbetween the code found in two files,
#top.html and bot.html.  User's can customize the look of the calendar by editing
#top.html and bot.html.

#print STDERR "preparing top.html \n" ;
#print STDERR "$jconfig::value{'cssUrl'}\n" ;

#open top.html and read it into memory
open( HTML, "top.html" ) ;
$i = 0 ;
while( $input=<HTML> ){
      if( $input =~ /<LINK REL=stylesheet TYPE=text\/css HREF=\/calendar.css>/ ){
           if( $jconfig::value{"cssUrl"} ne "" ){
                  $input = "<LINK REL=\"stylesheet\" TYPE=\"text/css\" HREF=\"".$jconfig::value{"cssUrl"}."\">" ;
             }
        }
   $top[$i] = $input ;
   $i++ ;
}
#close top.html once it is read into memory
close( HTML ) ;
#open bot.html and read it into memory
open( HTML, "bot.html" ) ;
$i = 0 ;
while( <HTML> ){
   $bot[$i] = $_ ;
   $i++ ;
}
#close bot.html once it is read into memory
close( HTML ) ;

#now print to stdout the information from top.html, all the code we've developed
#in this script, and the information from bot.html.
print <<END
@top
$calendarinfo
@bot
END
;

---------------------------------------
THANK YOU!
0
 
LVL 8

Accepted Solution

by:
Perl_Diver earned 285 total points
ID: 16800814
Windows and perl both don't care which way the slashes go in paths. It's safer to use forward slashes and use single-quoted strings for scalars with no variable expansion or meta-character interploation in them:

for eaxmple:

use lib "d:/Websites/www.(edited).ca/calendar2";

better written as:

use lib 'd:/Websites/www.(edited).ca/calendar2';

if you have something like this:

use lib "D:\Websites\www.(edited).ca\calendar2\index.cgi";

you run the risk of meta-character interpolation, such as \W and \w both of which are short cut character classes.

In your script above you have:

use CGI qw/:standard/;
    print header;

then later:

#&jcgi::print_header function provided by cgi.pm
#append charset=UTF-8 so browsers will know to view multilingual pages as unicode and render properly
$type="text/html;charset=UTF-8" ;
&jcgi::print_header( "Content-type", $type ) ;


looks like you are printing two headers which could be causing problems and is why the second headers is printed in the output stream.
0
 
LVL 8

Assisted Solution

by:Perl_Diver
Perl_Diver earned 285 total points
ID: 16800848
this comment in my above post:

It's safer to use forward slashes and use  >>single-quoted strings for scalars<<  with no variable expansion or meta-character interploation in them:


should be:

It's safer to use forward slashes and use  >>single-quotes for strings<<  with no variable expansion or meta-character interploation in them:


these words in my original comment:  single-quoted strings for scalars
should be: single-quotes  for strings

0
 

Author Comment

by:piano_fantasy
ID: 16804858
I have added

use CGI qw/:standard/;
    print header;

to the tops of both index.cgi and viewday.cgi and both of them appear to be "working" but I still get the extra text at the top of the page that is probably caused by the later print_heades (I just don't know how to change them!).   The script is CGI Calendar by Jay Eckles.  (which is supposed to be an open source project and works with windows...!!!!!!)  I just don't understand why it isn't working... but then again I know nothing about Perl...SO...

ALSO, the script is supposed to output to HTML using top.html and ending with bottom.html and thid does not appear to be hapenning either!

This is what I get when i Run index.cgi:

1-6-2006
2-6-2006
3-6-2006
4-6-2006
5-6-2006
6-6-2006
7-6-2006
8-6-2006
9-6-2006
10-6-2006
11-6-2006
12-6-2006
13-6-2006
14-6-2006
15-6-2006
16-6-2006
17-6-2006
18-6-2006
19-6-2006
20-6-2006
21-6-2006
22-6-2006
23-6-2006
24-6-2006
25-6-2006
26-6-2006
27-6-2006
28-6-2006
29-6-2006
30-6-2006
[Wed May 31 22:49:33 2006] index.cgi: Wide character in print at D:\Websites\www.(edited).ca\calendar2\index.cgi line 424.

...followed by the calendar.

And I get this extra code when I try to view a day:
7-6-2006 Content-type: text/html;charset=UTF-8

...followed by the view.

Is this code poorly written??  This is an open source project code and I thought the installation would be simple!

HELP!!


0
 
LVL 8

Assisted Solution

by:Perl_Diver
Perl_Diver earned 285 total points
ID: 16805215
Earlier in the thread Adam314 posted:

>> I don't see anywhere a header is printed.

and then he showed you what to do, but that suggestion was made before you posted the rest of the script, and the script does look like it prints a header:

#finally print the html page back to the client
#&jcgi::print_header function provided by cgi.pm
#append charset=UTF-8 so browsers will know to view multilingual pages as unicode and render properly
$type="text/html;charset=UTF-8" ;
&jcgi::print_header( "Content-type", $type ) ; <<<< HERE IT PRINTS THE HEADER


No fault of Adam314's because he gave the same advice most would have under the same circumstances. You need to remove the stuff you added to index.cgi and viewday.cgi:

use CGI qw/:standard/;
    print header;

and hopefully everything will be OK at this point. If not we can continue trying to track down what the problem is. You can keep this line in index.cgi:

use CGI::Carp qw(fatalsToBrowser warningsToBrowser);

it will help with debugging the script but once you have it working you should remove it or comment it out.

0
 

Author Comment

by:piano_fantasy
ID: 16807667
Thank you!

Well the problem is, when I remove the use CGI qw stuff from the top I get:

CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers.

and nothing more...
0
 
LVL 8

Expert Comment

by:Perl_Diver
ID: 16809305
I didn't see this buried in your post above:

 [Wed May 31 11:08:49 2006] index.cgi: Wide character in print at D:\Websites\www.(edited).ca\calendar2\index.cgi line 427.

line 427 appears to be this part of index.cgi:

-----------------------------------------
#now print to stdout the information from top.html, all the code we've developed
#in this script, and the information from bot.html.
print <<END    <<<<HERE IS LINE 427
@top
$calendarinfo
@bot
END
;
-----------------------------------------

I'm not sure if that is a warning or a fatal error though. This has something to do with utf8 encoding. Try commenting out the line noted below in index.cgi:

Here is the index.cgi code:
#!D:\\Perl\\bin\\Perl.exe
use CGI::Carp qw(fatalsToBrowser warningsToBrowser);
#use utf8;  ##<<< COMMENT OUT THIS LINE BY PUTTING A '#' AT THE BEGINNING
use lib "d:/Websites/www.(edited).ca/calendar2";

rerun the script and see if it helps.
0
 

Author Comment

by:piano_fantasy
ID: 16809749
With the  CGI qw stuff removed and the comment out of #use utf8; at the beginning of the code... I still get this error

CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers.

and nothing more...
0
 

Author Comment

by:piano_fantasy
ID: 16809767
To see this script in action (or NOT in action as it were!)  Go to:

http://www.(edited).ca/calendar2/index.cgi

where (edited) = f i r e b i r d c h a m b e r s i n g e r s
without spaces

Thanks.
Cody
0
 
LVL 8

Expert Comment

by:Perl_Diver
ID: 16809921
can you run scripts from the calendar2 folder? It's setup to allow that?
0
 
LVL 8

Expert Comment

by:Perl_Diver
ID: 16809986
take these two lines and place then where you had the CGI qw stuff:

$type="text/html;charset=UTF-8" ;
&jcgi::print_header( "Content-type", $type ) ;

and comment them out later in the script where they appear so two headers are not printed.
0
 
LVL 39

Assisted Solution

by:Adam314
Adam314 earned 345 total points
ID: 16810398
Something is printing that shouldn't be.  The jcgi::print_header function should be the first thing that is printing anything - so the first thing printed would be a header.  Something before that is printing, which is why you were getting the errors.  Now that you print the headers at the very top, whatever is printing is showing up, then the second headers, then the page as it should be.

Here is your code, with a few debug print statements.  What is the output from this:




#!D:\\Perl\\bin\\Perl.exe

use CGI::Carp qw(fatalsToBrowser warningsToBrowser);
use CGI qw/:standard/;
    print header;
use utf8;
use lib "d:/Websites/www.(edited).ca/calendar2";

require jcgi ;
require jconfig ;
require calendar ;
require dataaccess ;
require language ;

print "**DEBUG: " . __LINE__ . "\n";
&jconfig::loadConfig() ;

$version = "2.8" ;

#############################################################################
#Index.cgi
# $Id: index.cgi,v 1.16 2005/09/15 15:09:41 ecklesweb Exp $
# Copyright 2004 Jay Eckles
# This file is licensed under the GPL version 2 and is provided without warranty.  
# See http://www.gnu.org/copyleft/gpl.html for license details.
#    CSS class names used in HTML Copyright Isaac McGowan, used under GPL.
#
# This cgi script is used as a part of the CGI Calendar system, a collection
# of perl scripts and modules with the purpose of creating a web-based
# group event calendar.  
#
# This script's job is to build a calendar in the form of an html table,
# including in the cell for each day any events found for that date in the
# calendar database.
#
# Which month and year should be loaded is communicated to the script via
# CGI communication.  The following is a list of the name and value pairs that
# Index.cgi must receive; the order in which they must be received is of
# no importance.
# If a name/value pair is optional, it is listed in square brackets ([]).
# if multiple values are possible for a name, all optional values are
# listed in parentheses (()), and spearated by pipes (|)
#
# month=an integer greater than or equal to 1 and less than or equal to 12
# year=a positive integer
#
# These name/value pairs may be passed to the cgi program using either the
# GET or POST methods.  The information is retrieved by calling a function
# found in the cgi.pm module.  
#
# The generation of the calendar is accomplished by first finding the number
# of days in the month and the day of the week on which the month starts
# by calling functions provided by calendar.pm.  Then, an html table is
# constructed with 7 columns, and as many rows as necessary to fill out
# the calendar.  As each cell is created, the database is queried for events
# happening on the day that cell corresponds with - this is done by using the
# &dnfunc::dn_select function of dnfunc.pm.  
#
# Originally authored by Jay Eckles <j.eckles@computer.org>.  
# Contributors:
#     Many people from comp.infosystems.www.authoring.cgi - debugging tips,
#        many feature ideas, help in pointing out errors and poor code, etc.
#     Ken MacCuish <ken@pwhinc.com> - modified code to highlight the cell of the
#        table containing the current day with a color defined by the variable
#        $cell_today_color and any day with an event with a color defined by
#        the variable $cell_active_color
#
# $Log: index.cgi,v $
# Revision 1.16  2005/09/15 15:09:41  ecklesweb
# bug fix for multiple calendar databases
#
# Revision 1.15  2005/04/19 02:47:56  ecklesweb
# change comments to license specifically under v2 of GPL
#
# Revision 1.14  2005/04/14 01:49:12  ecklesweb
# final 2.7 commits?
#
# Revision 1.13  2005/04/14 01:31:44  ecklesweb
# change way dates are represented so events can be shared across languages
#
# Revision 1.12  2005/04/14 01:16:47  ecklesweb
# remove print to STDERR, add use utf8 to .pm's
#
# Revision 1.11  2005/04/13 23:14:48  ecklesweb
# send UTF-8 content type header
#
# Revision 1.10  2005/04/02 23:47:31  ecklesweb
# added french, added language dropdown to index.cgi
#
# Revision 1.9  2005/04/01 01:58:35  ecklesweb
# utf-8 fix
#
# Revision 1.8  2005/04/01 01:51:29  ecklesweb
# multilingual enhancements
#
# Revision 1.7  2005/03/30 23:51:26  ecklesweb
# multilingual enhancements
#
# Revision 1.6  2005/02/25 01:34:52  ecklesweb
# finalizing 2.6 changes
#
# Revision 1.5  2004/11/27 19:18:16  ecklesweb
# ID and Log tags in index.cgi and calendar.pm
#
################################################################################

#initialize the language::monthnames and day lists

#retrieve the name/value pairs by using a cgi.pm function
print "**DEBUG: " . __LINE__ . "\n";
@input = &jcgi::retrieve_input() ;
print "**DEBUG: " . __LINE__ . "\n";
%input = %jcgi::in ;

print "**DEBUG: " . __LINE__ . "\n";
$lang = $jcgi::in{"lang"} ;
if( $lang eq "" ){
   $lang = $jconfig::value{"defaultLanguage"} ;
}
if( $lang eq "" ){
   $lang = "en-us" ;
}

print "**DEBUG: " . __LINE__ . "\n";
&language::loadText( $lang ) ;

#filename of the calendar database
print "**DEBUG: " . __LINE__ . "\n";
&dataaccess::set_datasource( $jcgi::in{"db"}  );
print "**DEBUG: " . __LINE__ . "\n";
$dbname = $jcgi::in{"db"} ;


$month = $input{"month"} ;
$year = $input{"year"} ;

#if no month or year is given, then use the current month or year according to the
#system clock.
@timelist = localtime( time() ) ;
if( $month eq "" ) {
   $month = $timelist[4] + 1 ;
}
if( $year eq "" ) {
   $year = $timelist[5]+1900 ;
}
$dayofmonth = $timelist[3] ;
$curmonth = $timelist[4]+1 ;
$curyear = $timelist[5]+1900;

#determine the language::monthname by using $month as an index to the language::monthnames list.
print "**DEBUG: " . __LINE__ . "\n";
$language::monthname = $language::monthnames[$month-1] ;
print "**DEBUG: " . __LINE__ . "\n";
$monthyear = $language::monthname.$year ;

#determine how many days are in the given month and on what day of the week
#that month starts.  These functions are provided by calendar.pm
print "**DEBUG: " . __LINE__ . "\n";
$days_in_month = &calendar::days_in_month( $month, $year ) ;
print "**DEBUG: " . __LINE__ . "\n";
$monthstart = &calendar::month_start( $month, $year ) ;

   
################Start creating the table that will be the calendar.####################

#the html code for the table will be stored as a string in the scalar variable $table
$table = "<tr>\n" ;

# print top row of calendar which holds days of week
for( $i=0; $i < 7; $i++ ){
   $table = $table."<td class=column_header>$language::day[$i]</td>\n" ;
}

# next row
$table = $table."<tr>\n" ;

# skip the appropriate number of days as indicated by the calendar::monthstart function
for( $i=0; $i < $monthstart; $i++ ){
   $table = $table."<td class=empty_day_cell></td>\n" ;
}

# in day_of_week, Sunday is 0, Saturday is 6.
$day_of_week = $monthstart ;

#now, we have got the table to the point where we know what day of the week we're on and
#we know that the next cell is the 1st of the month.  We can now start creating the cells
#for the days which means we begin to look for events in the database.

#$current_day is the day of the month we are currently working on
$current_day = 0 ;
# this loop creates the individual day cells on the calendar.
for( $i=1; $i <= $days_in_month ; $i++ ){
   $current_day++ ;
# find out if it's a new week and we need to start a new row
   if( !( $day_of_week % 7 ) ){
      $table = $table."<tr>\n" ;
   }


#create a key based on the date given...key is in format dd-mm-yyyy
   $key = $i."-".$month."-".$year ;

#retrieve the information for that day from the calendar database  
print "**DEBUG: " . __LINE__ . "\n";
   &dataaccess::open_database() ;
   
   @events = () ;
   
#print STDERR "events contains @events items\n" ;
   
#print STDERR "key is $key\n" ;
   
print "**DEBUG: " . __LINE__ . "\n";
   @events = &dataaccess::get_events( $key ) ;
   
#print STDERR "events now contains @events items\n" ;
### sort the events/times by time
#   @events = &calendar::eventsort( @events ) ;
print "**DEBUG: " . __LINE__ . "\n";
   @events = sort calendar::timeCompare @events ;
   
   @daysevents = () ;
   @times = () ;
   foreach $event (@events){
      push( @daysevents, $event->{'summary'} ) ;
      push( @times, $event->{'when'} ) ;
   }
   
# hilite the cell if it is today or there is an activity today
###begin Ken's code later modified by Jay###
   if ($i eq $dayofmonth && $curmonth eq $month && $year eq $curyear){
      $cellcolor="class=today_cell"
   }
   elsif( @daysevents > 0 ){
      $cellcolor="class=populated_day_cell" ;
   }
   else{
      $cellcolor="class=day_cell";
   }
# create the cell, include the day of the month - link day to viewday.cgi  
   $table = $table."<td $cellcolor valign=top>
   <a href=\"viewday.cgi?lang=$lang&mode=all&month=$month&date=$current_day&year=$year&db=$dbname\" class=day_number>$current_day</a>
   <br>" ;
###end Jay's modifications of Ken's code###
# if there's anything on this day, put it in the day's cell.
   if( @daysevents > 0 ){
      for( $j=0; $j < @daysevents; $j++ ){    

####urlencode summary for transmission via get - encode from jcgi.pm
print "**DEBUG: " . __LINE__ . "\n";
$enc_summary = &jcgi::encode( $daysevents[$j] ) ;
#link event to viewday.cgi
         $table .= "<a href=\"viewday.cgi?lang=$lang&mode=one&month=$month&date=$current_day&year=$year&summary=$enc_summary&db=$dbname\">";
# if there is a time, print the time after the summary of the event.  If
# there is no time given, don't print anything except the summary.
         if( $times[$j] =~ /^\D/ ){
            $table = $table."<span class=title_txt>$daysevents[$j]</span></a><br>\n" ;
         }
         else{
            $table = $table."<span class=title_txt>$daysevents[$j]</span></a> <br><span class=time_str>($times[$j])</span></a><br>\n" ;
         }
      }
   }
# close the cell
   $table = $table."</td>\n" ;
   $day_of_week = ($day_of_week + 1) % 7 ;
} #end of for loop: for( $i=1; $i <= $days_in_month ; $i++ )
#here, at the termination of the loop, we have created a cell for each day of the month.
#so we finish the table:
#$table = $table."</table>\n" ;

##loop through remaining days in last week to create empty cells...
$remaining_days = (7-$day_of_week) % 7 ;
for( $i=0; $i<$remaining_days; $i++ ){
   $table = $table."<td class=empty_day_cell></td>\n" ;
}
$table = $table."</tr>\n" ;

#create the form that will be at the top of the calendar to provide the "jump to month"
#functionality
$yearminus2 = $year - 2 ;
$yearminus1 = $year -1 ;
$yearplus1 = $year+1 ;
$yearplus2 = $year+2 ;
$yearplus3 = $year+3 ;
$form = "
<form action=\"index.cgi\" method=\"get\">
<input type=hidden name=db value=$dbname>
<input type=hidden name=lang value=$lang>
<select name=month class=month_select>
<option value=$month>$language::monthnames[$month-1]
<option value=1>$language::monthnames[0]
<option value=2>$language::monthnames[1]
<option value=3>$language::monthnames[2]
<option value=4>$language::monthnames[3]
<option value=5>$language::monthnames[4]
<option value=6>$language::monthnames[5]
<option value=7>$language::monthnames[6]
<option value=8>$language::monthnames[7]
<option value=9>$language::monthnames[8]
<option value=10>$language::monthnames[9]
<option value=11>$language::monthnames[10]
<option value=12>$language::monthnames[11]
</select>

<!--input type=text value=$year name=year size=4 class=year_input-->
<select name=year>
<option value=$yearminus2>$yearminus2
<option value=$yearminus1>$yearminus1
<option value=$year selected>$year
<option value=$yearplus1>$yearplus1
<option value=$yearplus2>$yearplus2
<option value=$yearplus3>$yearplus3
</select>

<input type=submit value=$language::govalue class=submit_button>
</form> " ;

######################################Print HTML########################################

#finally print the html page back to the client
#&jcgi::print_header function provided by cgi.pm
#append charset=UTF-8 so browsers will know to view multilingual pages as unicode and render properly
print "**DEBUG: " . __LINE__ . "\n";
$type="text/html;charset=UTF-8" ;
&jcgi::print_header( "Content-type", $type ) ;

# if the calendar shown is January, then the previous month is December of
# the previous year (year-1).  Otherwise it is just the previous month of
# the same year (month-1)
if( $month == 1 ){
   $prevmonth = 12 ;
   $prevyear = $year-1 ;
}
else{
   $prevmonth = $month-1 ;
   $prevyear = $year ;
}
# similarly, if the calendar shown is December, the next month is January
# of the next year.  Otherwise it is month+1
if( $month == 12 ){
   $nextmonth = 1 ;
   $nextyear = $year + 1 ;
}
else{
   $nextmonth = $month+1 ;
   $nextyear = $year ;
}

$languageDropdown = "" ;
foreach $key (sort by_value keys %language::availableLanguages) {
   if( $key eq $lang ){
      $languageDropdown .= "<option value=$key selected>$language::availableLanguages{$key}\n" ;
   }
   else{
      $languageDropdown .= "<option value=$key>$language::availableLanguages{$key}\n" ;      
   }
}
sub by_value { $language::availableLanguages{$a} cmp $language::availableLanguages{$b}; }

#$calendarinfo holds the html code for the calendar, including the table and
#the form we created earlier
$calendarinfo = "
<div align=center>
<table border=1 cellpadding=2 cellspacing=0 class=calendar_table>
<tr>
<td colspan=7>
<table border=0 width=100%>
<tr>
<td class=arrows align=left><a
href=\"index\.cgi\?lang=$lang&month=$prevmonth&year=$prevyear&db=$dbname\" class=prev_month_link><img src=$jconfig::value{'prevGifUrl'} class=prev_month_image border=0 alt=$language::prevgifalt></a><a
href=\"index\.cgi\?lang=$lang&month=$nextmonth&year=$nextyear&db=$dbname\" class=next_month_link><img src=$jconfig::value{'nextGifUrl'} class=next_month_image border=0 alt=$language::nextgifalt></a>
</td>
<td class=date_header>
$language::monthname, $year
</td>
<td align=right valign=bottom class=date_nav_cell>
$form
</td>
</table>
</td></tr>

$table

<tr>
<td colspan=7 class=footprint>
<table border=0 cellpadding=0 cellspacing=0 width=100%>
<tr>
<td valign=middle align=left class=footprint>
<a href=\"http://cgicalendar.sourceforge.net\">CGI Calendar $version</a> by <a href=\"http\://www\.jayeckles\.com/\">Jay
Eckles</a>
</td>
<td align=right valign=top>
<form action=\"index.cgi\" method=\"get\" name=langform>
<input type=hidden name=db value=$dbname>
<input type=hidden name=month value=$month>
<input type=hidden name=year value=$year>
<select name=lang onChange=\"document.langform.submit();\">
$languageDropdown
</select>
</form>
</td>
</tr>
</table>
</td>
</table>
</div>
" ;
#end $calendarinfo =...

#that html code we just developed goes inbetween the code found in two files,
#top.html and bot.html.  User's can customize the look of the calendar by editing
#top.html and bot.html.

#print STDERR "preparing top.html \n" ;
#print STDERR "$jconfig::value{'cssUrl'}\n" ;

#open top.html and read it into memory
open( HTML, "top.html" ) ;
$i = 0 ;
while( $input=<HTML> ){
      if( $input =~ /<LINK REL=stylesheet TYPE=text\/css HREF=\/calendar.css>/ ){
          if( $jconfig::value{"cssUrl"} ne "" ){
               $input = "<LINK REL=\"stylesheet\" TYPE=\"text/css\" HREF=\"".$jconfig::value{"cssUrl"}."\">" ;
           }
       }
   $top[$i] = $input ;
   $i++ ;
}
#close top.html once it is read into memory
close( HTML ) ;
#open bot.html and read it into memory
open( HTML, "bot.html" ) ;
$i = 0 ;
while( <HTML> ){
   $bot[$i] = $_ ;
   $i++ ;
}
#close bot.html once it is read into memory
close( HTML ) ;

#now print to stdout the information from top.html, all the code we've developed
#in this script, and the information from bot.html.
print <<END
@top
$calendarinfo
@bot
END
;
0
 

Author Comment

by:piano_fantasy
ID: 16810605
Perl Driver,

When I change the print statements at the top and comment out the bottom, I get the same gobbledeegook (all of the dates) followed by

 [Thu Jun 1 13:39:48 2006] index.cgi: Wide character in print at D:\Websites\www.firebirdchambersingers.ca\calendar2\index.cgi line 429.

again.


And secondly,  I am pretty sure I have access to use the calendar2 folder... I have worked with the techies to grant me the proper permissions and also set it up in the jconfig.pm file to look in that folder for the data.

Thanks.
0
 

Author Comment

by:piano_fantasy
ID: 16810644
Adam 314,

This is what I get when I use your index.cgi with the debug features:

**DEBUG: 15 **DEBUG: 110 **DEBUG: 112 **DEBUG: 115 **DEBUG: 124 **DEBUG: 128 1-6-2006 2-6-2006 3-6-2006 4-6-2006 5-6-2006 6-6-2006 7-6-2006 8-6-2006 9-6-2006 10-6-2006 11-6-2006 12-6-2006 13-6-2006 14-6-2006 15-6-2006 16-6-2006 17-6-2006 18-6-2006 19-6-2006 20-6-2006 21-6-2006 22-6-2006 23-6-2006 24-6-2006 25-6-2006 26-6-2006 27-6-2006 28-6-2006 29-6-2006 30-6-2006 [Thu Jun 1 13:43:49 2006] index.cgi: Wide character in print at D:\Websites\www.firebirdchambersingers.ca\calendar2\index.cgi line 444. **DEBUG: 130 **DEBUG: 151 **DEBUG: 153 **DEBUG: 158 **DEBUG: 160 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 204 **DEBUG: 213 **DEBUG: 219 **DEBUG: 324 Content-type: text/html;charset=UTF-8

...followed by the calendar.

Thanks for all of your help everybody... this is a perplexing situation.
0
 
LVL 39

Assisted Solution

by:Adam314
Adam314 earned 345 total points
ID: 16810733
This command, on line 129, is printing the info
&dataaccess::set_datasource( $jcgi::in{"db"}  );

Can you post the code for that function?  
0
 
LVL 8

Expert Comment

by:Perl_Diver
ID: 16811362
somethings to consider:

Installing CGI Calendar

Notes on uploading: If you upload the .tar.gz file to your web server and then unzip/untar the file on your webserver, use BINARY mode to FTP the file. This is the recommended method for transferring the files. If, however, you unzip and untar the file locally and then upload the .cgi, .pm, and other files individually, make sure you upload them using ASCII mode. If you upload the individual files in BINARY mode, you may get an error when you try to run CGI Calendar.

on the calendar support forum:

I could not a definitive answer on this forum, but by trial and error found that the problem was caused by the calendar.db permissions being set to execute but not write. I don't know why that resulted in a 500 error message, or anything to do with premature ends, but I'm posting it here so the next guy who goes searching will find this.

and this person is describing a very similar problem you are having in this thread:

http://sourceforge.net/forum/forum.php?thread_id=1443704&forum_id=401655
0
 
LVL 17

Expert Comment

by:mjcoyne
ID: 16812778
To get rid of the "Wide character in print" warning, try putting:

binmode STDOUT, ":utf8";

just after:

use utf8;

at the top of index.cgi...
0
 
LVL 39

Expert Comment

by:Adam314
ID: 16834931
Did you get this resolved?  Care to share the solution?
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have been pestered over the years to produce and distribute regular data extracts, and often the request have explicitly requested the data be emailed as an Excel attachement; specifically Excel, as it appears: CSV files confuse (no Red or Green h…
There are many situations when we need to display the data in sorted order. For example: Student details by name or by rank or by total marks etc. If you are working on data driven based projects then you will use sorting techniques very frequently.…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Six Sigma Control Plans
Suggested Courses

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question