I sometimes access the Joomla DB via external scripts. The problem I have is that if I ever need to change the prefix, I'll need to edit my scripts again too.
Is there a way to programmatically determine the Joomla database prefix using php? If yes, how?