Ive have made a small custom module/standalone page that pulls clients from db and populate table with an option to generate pdf in size of envelope with company data and client data (uses mpdf also).
Now, my idea is to integrate this into IP as sub page available from dashboard, or include some code so its not browseable for non-logged users (to use the same authentication system as IP).
Can somebody with a bit more knowledge in php and IP code help me whit this?
From your description, it is unclear to me what your module does (maybe a screenshot may help) so I cannot say where I would include it in the IP menu, but that’s not needed at this stage.
Does your module follow the model-controller-view design pattern?
If it does and if your code files are in the folder tree structure imposed by CodeIgniter framework, then it should be rather easy to integrate it into IP1.
Start by looking at the modules directory. Choose the simplest one (for example the product or category).
Add the function to your modules controller and create models and views as required. As miquel suggested, you just need to conform to the Code Igniter framework, and you should be ok.
You can call your controller function in the following way