Fiji Web Design
Welcome, Guest
Please Login or Register.    Lost Password?
PHP Module FAQs (1 viewing) (1) Guest
Go to bottom Post Reply Favoured: 0
TOPIC: PHP Module FAQs
#7
admin (Admin)
Admin
Posts: 475
graph
User Online Now Click here to see the profile of this user
PHP Module FAQs 3 Years, 7 Months ago Karma: 10  
Where can I get the PHP Module for Joomla?
Visit the PHP Module Project Page for download details.

What does the PHP Module do?
It allows you to place any PHP, HTML, JavaScript and CSS code in a module position. It is based on the HTML Module, with the added benefit of allowing PHP.

Do I have to wrap the PHP code in special tags?

No, you can use the regular PHP tags directly. eg:
<?php phpinfo(); ?>
Can I use predefined Joomla variables? Yes, but you first have to declare them as globals. eg:
<?php
      global $mainframe; 
?>
Can I include PHP files? Yes, but make sure you use the full path to the PHP files. It's just easier. Example: Joomla 1.0
<?php
global $mainframe;

include($mainrame->getCfg('absolute_path').'/modules/mod_php/includes/my_php_file.php');
?>
Example: Joomla 1.5
include(JPATH_ROOT.'/modules/mod_php/includes/my_php_file.php');
Can I use more than one Joomla PHP Module on a page? Yes, just copy the module using the built in Joomla Module Copy feature.
 
Report to moderator   Logged Logged  
 
Last Edit: 2008/07/11 07:05 By admin.
  The administrator has disabled public write access.
Go to top Post Reply
Powered by FireBoardget the latest posts directly to your desktop

Joomla Downloads

DownloadsDownload our free Joomla! Components, Modules and Plugins.