On 2.0 we do not trust ANYMORE test project ID, test plan ID stored on $_SESSION, because is only way to allow users to access WITH SAME USER DIFFERENT test projects and test plans using TABBED BROWSING.
This has also effects on HOW testlinkInitPage() is used, and HOW NEW PAGES present on 1.9.4 has to be refactored to be ported to 2.0
On 2.0 99,99% time you have to use testlinkInitPage() this way => testlinkInitPage($db)