Virtual PC and Windows 2003 Server activation

Refer: www.tipandtrick.net

To fix the Shared Network (NAT) Internet no connection or not working issue, the resolution is to manually assign the IP address for the DNS Server for the guest operating system to 192.168.131.254, the virtual gateway IP address used by Virtual PC. To make the change (in guest operating system), open Network Connections folder (in Windows Vista, access via Network and Sharing Center), and right click Local Area Connection network icon to select its Properties. Then double click on Internet Protocl (TCP/IP) under General tab or Internet Protocol Version 4 (TCP/IPv4) under Networking (for Windows Vista) tab.

Windows 2003 IP Settings for Virtual PC
Windows 2003 IP Settings for Virtual PC

Scanning for CR/LF, want valid bash script

Quick Conversion Command

find . -name "*" -type f -exec dos2unix {} \;

Sample Script

#!/bin/sh
# MAKE SURE TO ALWAYS SAVE THIS FILE AS UNIX FORMAT.</code>

# Date: Monday, November 17, 2008 8:30 AM
# Author: Maurice Ruckman
#
# Description: Scan scripts directory looking for CR/LF which indicates
# a script was not saved in UNIX format. This would cause the script
# to fail.

grep -l -r $'\r\n' /devl/scripts > scan_for_crlf.output.txt

if [ -s scan_for_crlf.output.txt ]; then
echo "FAILURE CR/LF DETECTED IN SCRIPTS FOLDER"
echo "Found CR/LF when scanning scripts folder" | mailx -s "FAILURE FAILURE FAILURE CR/LF DETECTED IN SCRIPTS FOLDER" mruckman@hollandamerica.com
else
echo "ALL OKAY"
echo "All scripts passed test scan." | mailx -s "Scripts Folder Passed Scan" mruckman@hollandamerica.com
fi
find "/home/jboss1/workspace/HAL" -type f -name "*.java" > list.txt

We can easily convert the code with dos2unix

and find the problem code with something like this:

grep -l -r $'\r\n' /home/jboss1/workspace/HAL

or just convert everything by scripting it, here's a start

find "/home/jboss1/workspace/HAL" -type f -name "*.java"

Attempt to speed up FTP in Ubuntu

Try installing FileZilla instead.

sudo gedit /etc/modprobe.d/aliases

Replace

alias net-pf-10 ipv6

with

alias net-pf-10 off

and reboot.  After that, 'ifconfig' should no longer show any scary looking hex-notated IP addresses.

Update: It did not help FTP speed.  Change rolled back...

How to remove red eye in PhotoShop

Create a new layer and paint color of iris, use guassian blur 1.0, blend layers saturation, duplicate this layer and use hue saturation

Refer: http://graphicssoft.about.com/library/nosearch/n-psredeye.htm

Difficulty: Easy
Time Required: 5 minutes
Here's How:

1. Open the image.
2. Go to Image > Duplicate and close the original.
3. In Photoshop 6 or earlier, go to View > New View. In Photoshop 7 go to Window > Documents > New Window. This will open a duplicate window of the same image.
4. Zoom one of the windows so that you can see the eyes as large as possible. Set the other window view to 100%.
5. Arrange the two windows so you can see both the zoomed view and the 100% view at the same time.
6. Create a new layer.
7. Use the eyedropper to pick up a color from the iris of the eye. It should be a fairly gray tint with a hint of the eye color.
8. Paint over the red part of the eye on the new layer, being careful not to paint over the eyelids.
9. Go to Filters > Blur > Gaussian and give it about a 1 pixel blur to soften the edges.
10. Set the layer blend mode to Saturation. This will take the red out without removing the highlights, but in many cases it leaves the eyes too gray and hollow looking.
11. If that's the case, duplicate the saturation layer and change the blend mode to Hue. That should put some color back in while still preserving the highlights.
12. If the color is too strong after adding a Hue layer, lower the opacity of the Hue layer.
13. When you're happy with the results you can merge the extra layers down.

Tips:

1. If you need to darken the pupil area, use the burn tool. It should only take a couple of taps with the burn tool to darken the pupils.
2. Before merging your layers, use the eraser tool to clean up any overspray from painting outsideof the iris.
3. Watch an animated demonstration of how to remove redeye in Photoshop.
4. This technique works in Photoshop 4 and up, including Photoshop LE and Photoshop Elements.

Page Flipping Animation

Use JavaScript to emulate a web booking where the user can flip the pages.

http://www.sitepoint.com/blogs/2007/07/20/javascript-sprite-animation-using-jquery/