is the session_start compulsory for session_destroy?

Yes, if you browse a page without session_start() you cannot load the related data that you want to destroy.

Check the example: http://www.php.net/session_destroy

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.