Jump to content


Photo

include problem


  • Please log in to reply
1 reply to this topic

#1 natalieG

natalieG
  • Members
  • PipPipPip
  • Advanced Member
  • 63 posts

Posted 02 April 2006 - 02:59 PM


we have the table below that is trying to include the file index.php from an immediate
subdirectory of public_html, where public_html is where this code is located. We hae tried
changing the code to './calendar/index.php' and also made it absolluter
/home/msdsimg/public_html/calendar/index.php and we get the error messages in the attached
image.

Thanks,

Jennifer




<table width="800" border="0" cellspacing="0" cellpadding="0">
<tr width="800">
<TD><A HREF="http://msdsimaging.c..._main.php"><img src='newitems_small.gif'></TD>
<td align="center" width="800"><?php include 'Movie1.html' ?></td>
</tr>
<tr><td>&nbsp;</td></tr>
<tr width="800">
<td width="150" valign="top"><?php include 'main_left.php' ?></td>
<td width="650" align="center"><?php include 'calendar/index.php' ?></td>
</tr>
</table>


[img src=\"http://msdsimaging.com/calendar.jpg\" border=\"0\" alt=\"IPB Image\" /]

#2 Desdinova

Desdinova
  • Members
  • PipPipPip
  • Advanced Member
  • 41 posts

Posted 02 April 2006 - 03:05 PM

I'm not sure what you're trying to achieve.

As you can see, the error is in calendar/index.php

and you're trying to include calendar/index.php?

that would create an infinite loop?


I'd suggest 'require' and format it like <? require ("index.php"); ?>

If the file cannot be found, you could try complete URLs (<? require ("http://www.whatever.....com/index.php"); though I have the feeling some servers may have this feature disabled. However, it should be on the same server, so it might be possible. It shouldn't give errors.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users