Here is a manual to enable a second monitor on Ubuntu using an NVIDIA video card. First you need to check if you have the NVIDIA drivers installed, go to System -> Administration -> Hardware Drivers. If the NVIDIA accelerated graphics driver is not installed select it and click on the Install button. When the driver is installed you need to reboot your system.
After the reboot connect the second monitor to your system and then follow these steps. To enable your second monitor go to System -> Administration -> NVIDIA X Server Settings
Select X Server Display Configuration
Click on the Model button and select your 2nd monitor
Click on the Configure button
Select TwinView and click the OK button
Now click on the Apply button
Click on OK button to keep the settings
To disable your second monitor follow these steps:
Select the monitor you want to disable and click on Configure. Select Disabled and click the OK button
Click on the Disable button
Click on the Apply button
Click on the OK button to keep the settings and you second monitor will be disabled