Cook needed lengthy treatment but was able to resume as Bournemouth came back from 2-0 down to clinch their fifth win of the season.
A section of Millwall fans among 1,378 travelling supporters took exception to the celebrations led by goal scorer Lewis Grabban, a former Millwall player.
Police moved in to prevent any further trouble as Lions fans threatened to spill onto the pitch.
It was a bad day for Steve Lomas' side who fell to their second heavy defeat in four days, after going down 4-0 at Birmingham in midweek.
Bournemouth manager Eddie Howe said: "There is no way the players deserve to have things thrown at them. This is a family club, it should not have happened and I hope it does not happen again.
"Crowds can shout what they like and Lewis was doing nothing untoward after scoring his goal. Football is an emotional game and I can understand the celebrations.
"We showed great character to comeback from being two goals down. I was disappointed with the Millwall goals because they were both avoidable.
"But that is the way we play and you have to allow for mistakes because we like to get forward and attack when we can.
"Ryan Fraser got the crucial goal because it took us back to 2-1 at half time and it was no more than he deserved.
"Ryan puts in the hours on the training pitch and this was the end product of a tremendous amount of practise.
"It was a very open game, but our fans stuck with us and responded in the right manner and in the end we were easy winners."
Millwall manager Lomas was left to lament what he described as "15 mad minutes" when Bournemouth scored three goals and Alan Dunne was sent off.
Lomas said: "There were some poor decisions from the referee, including the red card to Dunne. How was that a deliberate hand ball?
"It's one thing to give a penalty for that incident but another thing to send him off and it was very harsh as he had no way of winning the ball.
"The referee booked every tackle we made but did nothing about the tackle by Fraser on one of our players.
"The goal just before half time gave Bournemouth some confidence and momentum. We were hindered by the refereeing decisions but we did not help ourselves.
"Bournemouth's second goal was a free header and you shouldn't be giving goals like that away at this level.
"The first half was good but now we need to pick ourselves up and get over this because it was disappointing after going ahead and being on top for 40 minutes."
Martyn Waghorn put Millwall in front in the sixth minute, before turning provider to slot through Liam Trotter who lifted his shot over on-loan goalkeeper Stephen Henderson four minutes later.
The Lions looked to be in cruise control before Scotland Under-20 winger Ryan Fraser curled a shot inside the post in the 43rd minute.
Bournemouth surged in front after scoring three goals in nine second half minutes with Cook rising to head home Ian Harte's corner for the equaliser in the 50th minute.
Bournemouth scored their third in the 54th minute when Harry Arter smashed home a loose ball on the edge of the box.
Dunne was given his second yellow card for a deliberate handball in the box to concede a penalty, which Grabban stepped up to smash in.
Substitute Brett Pitman dispatched a second penalty in added time after Fraser had been fouled.