One of the main functions of the liver is the production of bile. Bile is important for the digestion of fats. Fats are primarily oily and hydrophobic, which means they don't dissolve well in water or water-based solutions. Because the liquid inside the stomach and intestines contains a lot of water, fats that are consumed in the diet tend to stick together in large globules to minimize the amount of contact it has with water. Bile helps to break up these globules because it has parts that interact well with fats and parts that interact well with water, essentially forming a bridge between the fats and their environment. This allows the fats to be more easily absorbed by the intestines.
The liver also can play a role in the digestive system by the way that it filters out toxins. Some things that the digestive system absorbs can build up in the blood and poison the tissues of the digestive tract or other organs. The liver is one of the main areas in which toxins and other things are broken down (a process called metabolism). This is another way in which the liver interacts with the digestive system---by metabolizing some of the nutrients and chemicals that it absorbs. For example, the liver plays a major role in the way the digestive system handles alcohol, by helping process and eliminate the chemical.
Another function of the liver is how it works with the digestive system to modulate the amount of sugar in the blood. When the digestive system absorbs excess sugar in the form of glucose, the liver may take some of this energy and convert it into a highly compact carbohydrate called glycogen. This allows the liver to store excess sugar when it has been consumed. During periods in which the digestive system is not absorbing sugar, the glycogen can be converted back into glucose and used to keep blood sugar levels high--even during times of starvation.