Google Code University offers free training for computer programming. The training consists of a website which contains training materials such as slide shows, videos, and problem solving sets. Here is an excerpt from the Google training website which describes the training offered:
This website provides tutorials and sample course content so CS students and educators can learn more about current computing technologies and paradigms. In particular, this content is Creative Commons licensed which makes it easy for CS educators to use in their own classes.
The Courses section contains tutorials, lecture slides, and problem sets for a variety of topic areas:
- AJAX Programming
- Distributed Systems
- Web Security
In the Tools 101 section, you will find a set of introductions to some common tools used in Computer Science such as version control systems and databases.
The CS Curriculum Search will help you find teaching materials that have been published to the web by faculty from CS departments around the world. You can refine your search to display just lectures, assignments or reference materials for a set of courses.
Here is a link to the Google Code University website: Link
Here is a snippet of PERL code which you can use to send emails from your PERL scripts:
open (MAIL, "|/usr/sbin/sendmail -t ");
print MAIL "From: someFromAddress\@someFromDomain\n";
print MAIL "To: someToAddress\@someToDomain\n";
print MAIL "Content-Type: text/plain\n";
print MAIL "Subject: Very simple email test\n\n";
print MAIL "Body of the message";
Replace “someFromAddress\@someFromDomain” with an email address to be displayed in the “from” field of the email. It is important to not omit the backslash in front of the @ character in the email address. Similarly, replace “someToAddress\@someToDomain” with the email address to send the email to. Again don’t forget to escape the @ character in the email address by placing a backslash (\) in front of the @ sign. Also you’ll need to not leave off the “\n” you see in the to, from, and subject lines in the code.
Here is some sample code for determining what the file path is to the PERL script containing the code:
use Cwd qw(realpath);
my $fullpath = realpath($0);
If you just do $0 alone in the second line, that only gives you the filename that was executed. For example, if you include the first line of code above in a PERL script file named “perl foo.pl” $0 will return “foo.pl”. But if you ran the PERL script using an absolute path like this “perl /user/local/foo.pl”, $0 would return “/user/local/foo.pl”. So the example above uses the realpath() function to guarantee the full absolute path is always returned.
Sometimes while debugging a PHP application it is handy to display request and post variables. Here is the code that will do that:
foreach($_POST as $var=>$val)
Replace POST with SESSION and it’ll work for the session variables. You can do the same with GET, but probably don’t need it.