Corning Inc. (GLW), the world's largest maker of fiber-optic cable (search), on Monday posted a quarterly profit versus a year-earlier loss, thanks to stronger demand for its liquid crystal display (search) panels used in laptops and desktop computers.

Shares rose almost 6 percent in after-hours trading on the INET electronic brokerage after Corning also forecast stronger-than-expected results in its current quarter — the third — and boosted its spending plans for the year.

Until recent quarters, Corning had been weighed down by slower spending in the telecom sector. It responded over the three-year decline by cutting costs, slashing jobs and selling or closing money-losing units such as some optical components businesses.

However, its recent resurgence has been driven by the demand for LCD glass panels.

"We clearly exceeded our expectations for the quarter," Corning Chairman and Chief Executive James Houghton said in a statement. "We saw very strong performance in our Telecommunications and Display Technologies segments. In addition, this was our sixth quarter of sequential revenue growth."

The Corning, N.Y.-based company reported a second-quarter net profit of $108 million, or 7 cents a share, compared with a net loss in the year-ago quarter of $22 million, or 2 cents a share.

Excluding one-time items, it earned 11 cents a share.

Sales in the quarter rose to $971 million from $752 million last year. Revenue also was up 15 percent from the preceding quarter.

Analysts were expecting Corning to report second-quarter earnings before one-time items of about 9 cents a share on sales of $911.7 million, according to Reuters Estimates.

Corning also forecast third-quarter results above analysts' expectations and raised its spending plans for the year due to the strong demand for its LCD glass panels.

It expects third-quarter earnings before one-time items of 10 cents to 12 cents a share on sales of $950 million to $1 billion. Analysts were expecting 9 cents a share on sales of almost $955 million, according to Reuters Estimates.

Corning also hiked its spending plans for the year to a range of $950 million to $1 billion, from its previous forecast of $650 million to $700 million. The company said it believes it will remain sold out of its LCD manufacturing capacity through the rest of the year.

Corning said in April that it expected to remain sold out of LCD glass in the second quarter and planned to add manufacturing capacity throughout the year.

Corning also said the recent anti-dumping preliminary ruling in China is beginning to hurt fiber exported to China. The company, which previously said any potential loss should be less than 1 cent per share in the second half of the year, is cooperating with the Chinese Ministry of Commerce to reach a final ruling.