1
Bassman
Module PHP help
  • 2004/7/1 1:58

  • Bassman

  • Friend of XOOPS

  • Posts: 1272

  • Since: 2003/5/23


Help!
I'm trying to develop a module, actually porting the Open Moogle script. My index.php contains the following sofar:

[QUOTE]
<?php
include(XOOPS_ROOT_PATH."/mainfile.php");
include(XOOPS_ROOT_PATH."/header.php");
include(XOOPS_ROOT_PATH."/modules/openmoogle/moogleindex.php;
//standard for module name recognition
$ModName = 'OpenMoogle';
?>
<table width= '100%' align= 'center'>
<tr>
<td align='center'><big><strong>Open Moogle</strong></big><br>
<br>
<!-- Instructions to go in here-->
</tr>
<tr>
<td>
<?
include(XOOPS_ROOT_PATH.'/footer.php');
?>
[/QUOTE]

and when I try to connect from my main menu link, I get

[QUOTE]
Parse error: parse error, unexpected $ in /home/bassma00/public_html/modules/openmoogle/index.php on line 18
[/QUOTE]

Why am I getting this?

2
Herko
Re: Module PHP help
  • 2004/7/1 6:15

  • Herko

  • XOOPS is my life!

  • Posts: 4238

  • Since: 2002/2/4 1


Quote:
<?
include(XOOPS_ROOT_PATH.'/footer.php');
?>

<? in stead of <?php perhaps?

Herko

3
gstarrett
Re: Module PHP help

Quote:
<?php
include(XOOPS_ROOT_PATH."/mainfile.php");
include(XOOPS_ROOT_PATH."/header.php");
include(XOOPS_ROOT_PATH."/modules/openmoogle/moogleindex.php;
//standard for module name recognition
$ModName = 'OpenMoogle';
?>


You're missing a close quote and paren on your 3rd include... this will make the parser happy:

Quote:
<?php
include(XOOPS_ROOT_PATH."/mainfile.php");
include(XOOPS_ROOT_PATH."/header.php");
include(XOOPS_ROOT_PATH."/modules/openmoogle/moogleindex.php");
//standard for module name recognition
$ModName = 'OpenMoogle';
?>


4
Bassman
Re: Module PHP help
  • 2004/7/1 10:14

  • Bassman

  • Friend of XOOPS

  • Posts: 1272

  • Since: 2003/5/23


ah, gotcha. thanks ;)

Login

Who's Online

203 user(s) are online (163 user(s) are browsing Support Forums)


Members: 0


Guests: 203


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits