Forum Moderators: open
The big question is what does "work" mean - are you trying to send the user to the domain root? If so, then it's not a good practice to use index.html - use http://www.example.com/ instead. If you're trying to send people to the home page of the same directory where the include is being used, then you don't need any ../ at all.
<?php include("../includes/thecode.php"); ?>
Just disable the main page of /includes/ from being viewable using an Apache deny or by uploading a blank index page. That's basically for privacy and security reasons.