I guess this is a question of how America fought in this time period versus Europe. Going through the wiki page for the War of 1870, one can see cavalry depicted in paintings, even some depicting mass cavalry charges in combat, from which my recollection never happened in a large-scale in the American Civil War. So why did the role of cavalry differ between the regions, and were the infantry style of fighting in the two (ex. US: lines with moderately-accurate rifles) similar?
There are two key differences in these conflicts, the first is technological change driving an increase in firepower, the second is preparation.
Let's start with technology. The U.S. Army officers (on both sides of the civil war) looked closely to Europe for military technology and tactics, in particular the French military. The French were (barely) the victors in the 1859 Battle of Solferino during the Franco-Austrian war and American Civil War officers largely attempted to imitate French tactics (close order infantry attacks vigorously pressed) and adopt French technology. State of the art for France in 1859 was rifled muskets with shortish combat effective range and slow rates of fire and 12lbs "Napoleon" smooth-bore gun-howitzers firing explosive shells (these were supplemented with rifled muzzle loading artillery rushed into action). The results of this technological era was an infantry focused tactical system. At Solferino, and during the Civil War, artillery and cavalry was a supporting arm to the infantry. Cavalry actions at Solferino were restricted by the numbers and firepower of infantry formations. Artillery was not accurate or long range enough to disrupt infantry or drive them off the field. Cavalry attacks in this era (including as far back as the Crimean war) were typically failures against infantry, and were not able to effectively turn retreats into routs or pursuits. However Cavalry had an important reconnaissance and screening role and often fought against other cavalry. In the Civil War there were several large cavalry engagements fought primarily to aid reconnaissance and cavalry and mounted infantry were important in many larger battles in the initial stages.
By 1870, 11 years after Solferino and 5 years after the American Civil War, Europe had experienced a revolution in Military arms. The Prussians had demonstrated the effectiveness of massed Breech loading infantry rifles in 1866 against Austria in the Austro-Prussian war, and by 1870 the Austrians and French (and Americans) had also adopted these arms. These weapons fired faster, at flat trajectories (400-600 yards) and could be fired prone. Although both use the word "rifle" a rifle-musket of the ACW / Solferino vintage was massively less effective. With this change infantry no longer needed close formations to stop cavalry attacks, the rifle-firepower alone could prevent charges from being pressed home. There is one interesting and much celebrated 1870 episode, "Von Bredow's Death Ride" in which the Germans managed to sneak a cavalry brigade charge into some French artillery and surprised infantry forces and buy some time while the German cavalry suffered 50-70% casualties. This was essentially a fluke in 1870 and very much against the tactical norm for the war. "Von Bredow's Death Ride" was the only really successful cavalry action in 1870 and the last successful one in western Europe.
While cavalry waned in 1870, the other supporting arm, Artillery, made a huge comeback. Germans introduced a breech loading, accurate rifled gun with an explosive shell in 1870 that dramatically improved artillery firepower. Now artillery became able to make many infantry positions untenable and became a decisive element of successful infantry attacks. French rapid firing infantry caliber towed guns "mitrailleuse" played a minor role. For the next 50 years after 1870, European tactics would be dominated by the infantry-artillery combined arms team that the Prussians first fielded in 1870. Cavalry lingered but never did much except show up in paintings, and was used to provide mobility to mounted infantry or in colonial wars.
The other huge difference in the ACW vs the Franco-Prussian was preparation. America did not (shocker I'm sure) intend to tear itself to bits and fight a civil war, and there were no other serious opponents on it's borders. However, the French and Germans were quite aware that they would eventually fight each other or a similar Europeon state. Consequently the Prussians and French were ready to fight in 1870. In the ACW, they started the war April, and had an important battle in July (First Manassass) which only a tiny fraction of the country's military capacity was employed (35,000 men per side out of an eventual 800,000 peak strength). Then each side trickled in a little bit of men and material for the next 4 years until the South ran out in 1864-65. In contrast, 1870 had important engagements in three weeks time, and the war was decided at Sedan less than two months later. European generals built their armies before the war, then fought the war with those armies. In the ACW, the two sides tried to build armies and fight a war at the exact same time. The few professional officers (including Europeon imports like Franz Sigel) were drowned in a tide of green recruits, both officers and men alike. This improvisational character of the ACW would only appear in Europe when armies for one reason or another reached a stalemate, as they did in 1914.
Sources:
Nosworthy, Brent "The Bloody Crucible of Courage: Fighting Methods and Combat Experience of the Civil War"
Barry, Quintin, "The Road to Koniggratz"
Barry, Quintin "The Franco-Prussian War 1870-71"