Scripts and footage from the new series of Doctor Who were circulated online weeks ahead of its broadcast because of a mistake rather than a deliberate leak, BBC chiefs have said.

The corporation's commercial arm, BBC Worldwide, said it was taking disciplinary action over the bungle and had apologised to programme boss Steven Moffat and his team.

Five scripts from the series - starring Peter Capaldi as The Doctor - together with unfinished scenes from six episodes were accidentally placed in a publicly accessible area online.

Fans had to be asked not to share the material online or post spoilers about what happens. They were also warned that downloading and passing it on would be illegal.

There have been frantic ­efforts to remove the scripts and scenes - which were still to have special effects added - and a Miami-based server was said last week to have been closed.

BBC Worldwide said: "We would like to thank Doctor Who fans everywhere for their amazing efforts in helping us contain the recent leaks. The mistake was damaging."