<?php
// regex breakdown
// \[ matches the left bracket
// . any character except line breaks
// * 0 or more of the preceding character
// ? lazy matching
// \] matches the right bracket
$pattern = '/\[.*?\]/';
$replacement = '';
$subject = "The Bhagavad Gita presents a synthesis[5][6] of Hindu ideas about dharma,[5][6][7] theistic bhakti,[8][7] and the yogic paths to moksha.[6] The synthesis presents four paths to spirituality.";
$limit = -1;
$count = 0;
$result = preg_replace ($pattern, $replacement, $subject, $limit, $count);
?>
Should return
The Bhagavad Gita presents a synthesis of Hindu ideas about dharma, theistic bhakti, and the yogic paths to moksha. The synthesis presents four paths to spirituality.