module opening file in modal box

For Joomla! 1.5 Coding related discussions, please use: http://groups.google.com/group/joomla-dev-general
Locked
houndcomputers
Joomla! Apprentice
Joomla! Apprentice
Posts: 16
Joined: Sat Dec 18, 2010 10:10 pm

module opening file in modal box

Post by houndcomputers » Wed Aug 03, 2011 7:43 pm

I have written a module and within the module i have a link that opens a file window.php in a modal box. The file is located in the joomla module files. The problem is when that php page opens it does not have access to the Joomla classes. How do i do this where I can utilize the joomla classes in that modal box?

User avatar
Kiran cheema
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 153
Joined: Fri Nov 23, 2007 11:18 am

Re: module opening file in modal box

Post by Kiran cheema » Thu Aug 04, 2011 8:30 am

I would write it to a component e.g.:

components/com_pop
in there if this is only a 1 page view all you should need is then pop.php

pop.php should be able to access the joomla framework.

to call it you would then use : index.php?option=com_pop&tmpl=component

the tmpl=component loads only the page area without menus and modules

houndcomputers
Joomla! Apprentice
Joomla! Apprentice
Posts: 16
Joined: Sat Dec 18, 2010 10:10 pm

Re: module opening file in modal box

Post by houndcomputers » Thu Aug 04, 2011 3:46 pm

Seems like overkill to install a whole component just for that, but it worked. As long as it works and gets the job done then overkill it is...lol

User avatar
Kiran cheema
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 153
Joined: Fri Nov 23, 2007 11:18 am

Re: module opening file in modal box

Post by Kiran cheema » Thu Aug 04, 2011 4:16 pm

well it does mean you "could" attach it to a menu item if you wanted...


Locked

Return to “Joomla! 1.5 Coding”