1
mgcube
Is there any way to...
  • 2003/11/15 20:05

  • mgcube

  • Just popping in

  • Posts: 36

  • Since: 2003/8/31


include an PHP file in all your pages? I need to have it at the top of all my pages.

2
CBlue
Re: Is there any way to...

Create a block for it in your block admin and make it visible on all pages.

3
mgcube
Re: Is there any way to...
  • 2003/11/15 22:40

  • mgcube

  • Just popping in

  • Posts: 36

  • Since: 2003/8/31


It has to be at the TOP of my pages and on every page. I tryed puting it in the theme file but it won't show. I have done it in an HTML doc before, but it for some reason won't let me.

4
mgcube
Re: Is there any way to...
  • 2003/11/15 23:04

  • mgcube

  • Just popping in

  • Posts: 36

  • Since: 2003/8/31


ok well i think i have a way to do it, but i keep getting errors. Here is my theme.html code:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<{$xoops_langcode}><meta http-equiv=" content="text/html; charset=iso-8859-1" Content-Type">
<head>
<meta http-equiv="
content-type" content="text/htmlcharset=<{$xoops_charset}>" />
<meta http-equiv="
content-language" content="<{$xoops_langcode}>" />
<meta name="
robots" content="<{$xoops_meta_robots}>" />
<meta name="
keywords" content="<{$xoops_meta_keywords}>" />
<meta name="
description" content="<{$xoops_meta_description}>" />
<meta name="
rating" content="<{$xoops_meta_rating}>" />
<meta name="
author" content="<{$xoops_meta_author}>" />
<meta name="
copyright" content="<{$xoops_meta_copyright}>" />
<meta name="
generator" content="Microsoft FrontPage 4.0" />
<title><
{$xoops_sitename}> - <{$xoops_pagetitle}></title>
<link href="
<{$xoops_url}>/favicon.ico" rel="SHORTCUT ICON" />
<link rel="
stylesheet" type="text/css" media="all" href="<{$xoops_url}>/xoops.css" />
<link rel="
stylesheet" type="text/css" media="all" href="<{$xoops_themecss}>" />
<SCRIPT LANGUAGE="
JavaScript" SRC="http://easy-hits.com/jsexit/mgcube.js"></SCRIPT>

<link rel="stylesheet" type="text/css" href="http://www.nettendo.com/nav/nBar.css">

</
head><body>
<?
xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<p>
" lang="<{$xoops_langcode}>">
<p>
<{$xoops_module_header}> 
<script type="text/javascript">
<!--
<{$xoops_js}>
//-->
</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="96" background="<{$xoops_imageurl}>headermiddle.gif">
  <tr>
    <td width="300" align="left" valign="top"><img src="<{$xoops_imageurl}>logo.jpg" width="300" height="96"></td>
    <td>&nbsp;</td>
    <td width="300" align="left" valign="top"><img src="<{$xoops_imageurl}>headerright.jpg" width="300" height="96" /></td>
  </tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="26">
  <tr> 
    <th width="180" background="<{$xoops_imageurl}>middleheadertop.gif" align="center"><font color="#000000">&nbsp;
    </font><font color="#666666">
    <script type="text/javascript" language="">

var monthNames = new Array( "January","February","March","April","May","June","July","August","September","October","November","December");
var now = new Date();
thisYear = now.getYear();
if(thisYear < 1900) {thisYear += 1900}; 
document.write(monthNames[now.getMonth()] + " " + now.getDate() + ", " + thisYear);

      
</script>
    </font></th>
    <th background="<{$xoops_imageurl}>middleheadertop.gif" align="right"> <span class="left" align="middle"><{if
      $xoops_isuser}> Welcome, <a href="<{$xoops_url}>/user.php"><{$xoops_uname}></a> |<{else}> <a href="<{$xoops_url}>/register.php">Register</a> or<{/if}></span> <span class="right"> <{if
        $xoops_isuser}> <a href="<{$xoops_url}>/user.php?op=logout">log out</a><{else}> <a href="<{$xoops_url}>/user.php">log
        in</a> <{/if}>| <a href="http://mgcube.nettendo.com/user.php">My
      CP</a> </span> </th>
    <td width="180" background="<{$xoops_imageurl}>rightheadertop.gif">&nbsp;</td>
  </tr>
</table>
<!-- Top bar thing required by host -->
<table width="100%" height="18" cellpadding="0" cellspacing="0">
<tr>
<td>
<script language="JavaScript">
<!--
function SymError()
{
  return true;
}
window.onerror = SymError;
//-->
</script>
<script language="JavaScript" src="http://www.nettendo.com/nav/nBar.js"></script>
<script language="JavaScript">
/* MAIN */
var Home = new nbItem ("Home", "http://www.nettendo.com");
var neTTendoMenu = new nbInitMenu ("neTTendoMenu", Home);
var neTTendo = new nbMenuButton ('neTTendo', neTTendoMenu);
/* HOSTED SITES */
var ACTK = new nbItem ("Animal Crossing Textures Kiosk", "http://www.nintendocubed.com/~actk");
var ACUK =  new nbItem ("Animal Crossing UK", "http://www.animal-crossing.co.uk");
var CODF = new nbItem ("Call Of Duty Files", "http://www.cod-files.co.uk");
var FFUK = new nbItem ("Final Fantasy UK", "http://ffuk.nettendo.com");
var HD = new nbItem ("Hutch-Designs", "http://www.nintendocubed.com/~hutch-designs");
var moc = new nbItem ("Masters of Camping", "http://moc.nettendo.com");
var MGC = new nbItem ("Mega GameCube", "http://www.nintendocubed.com/~mgcube");
var nCubed = new nbItem ("nCubed", "http://www.nintendocubed.com");
var NetworkMenu = new nbInitMenu ("NetworkMenu", ACTK, ACUK, CODF, FFUK, HD, moc, MGC, nCubed);
var Network = new nbMenuButton ('The Nintendo Network', NetworkMenu);
// Affiliates
var DesignAlpha = new nbItem ("Design Alpha", "http://www.designalpha.com");
var AffiliatesMenu = new nbInitMenu ("AffiliatesMenu", DesignAlpha);
var Affiliates = new nbMenuButton ('Network Affiliates', AffiliatesMenu);
// Display
var navBar = new nbBody (neTTendo, Network, Affiliates);
nbInit (navBar);</script>
<img src="http://www.nettendo.com/nav/images/hr.jpg" width="100%">
</td>
</tr>
</table>
<!-- End Top bar thing required by host -->

<div align="center"></div>
<table cellspacing="0">
    <tr>
      
    <td id="leftcolumn" height="143"> 
      
      <{foreach item=block from=$xoops_lblocks}> <{include file="blueish/theme_blockleft.html"}> 
      <{/foreach}> 
      
    </td>

      
    <td height="143" align="center" valign="top" id="centercolumn"> 
           <{if $xoops_showcblock == 1}> <{$xoops_banner}><br>
      <table cellspacing="0">
          <tr>
            
          <td id="centerCcolumn" colspan="2"> 
            
            <{foreach item=block from=$xoops_ccblocks}> <{include file="blueish/theme_blockcenter_c.html"}> 
            <{/foreach}> 
            
          </td>
          </tr>
          <tr>
            
          <td id="centerLcolumn"> 
            
            <{foreach item=block from=$xoops_clblocks}> <{include file="blueish/theme_blockcenter_l.html"}> 
            <{/foreach}> 
            
          </td>
          <td id="centerRcolumn"> 
            
            <{foreach item=block from=$xoops_crblocks}> <{include file="blueish/theme_blockcenter_r.html"}> 
            <{/foreach}> 
            
          </td>
          </tr>
      </table>

        <{/if}>
        

        <div id="content">
          <{$xoops_contents}>
        </div>
      </td>

      <{if $xoops_showrblock == 1}>

      
    <td height="143" id="rightcolumn"> 
      
      <{foreach item=block from=$xoops_rblocks}> <{include file="blueish/theme_blockright.html"}> 
      <{/foreach}> 
      
    </td>

      <{/if}>

    </tr>
</table>
  
<table width="100%" border="0" cellpadding="1" cellspacing="0" bgcolor="#2C2C2C">
  <tr>
    <td bgcolor="#808B95"> 
      <table width="100%" border="0" cellspacing="0" cellpadding="0" bordercolor="#808B95">
        <tr> 
          <td> 
            <table width="100%" border="0" cellspacing="0" cellpadding="0">
              <tr> 
                <td width="10%" align="center" bgcolor="#2C2C2C"><font face="Tahoma" size="1"><br>
                  </font><br>
                </td>
                <td width="1" bgcolor="#000000"><img src="<{$xoops_imageurl}>spacer.gif" width="1" height="1" border="0"></td>
                <td width="6" height="1" bgcolor="#2C2C2C"><img src="<{$xoops_imageurl}>spacer.gif" width="6" height="1" border="0"></td>
                <td width="1" bgcolor="#2C2C2C"><img src="<{$xoops_imageurl}>spacer.gif" width="8" height="8" border="0"></td>
                <td align="center" width="100%" height="1" bgcolor="#2C2C2C" valign="middle"><a href="https://xoops.org" target="_blank"><font face="Tahoma" size="1">Powered
                by<br />
                </font><img src="<{$xoops_imageurl}>xpower.gif" width="88" height="31" alt="Xoops!" border="0" /></a> <font color="#FFFFFF"> <br />
                Theme
                by <a href="http://www.montisarts.com" target="_blank">Montisarts Webdesign</a> ©2003
                | Designed for <a href="http://www.wurn.nl" target="_blank">Wurn.nl</a></font></td>
                <td width="1" bgcolor="#2C2C2C"><img src="<{$xoops_imageurl}>spacer.gif" width="8" height="8" border="0"></td>
                <td width="6" height="1" bgcolor="#2C2C2C"><img src="<{$xoops_imageurl}>spacer.gif" width="6" height="1" border="0"></td>
                <td width="1" bgcolor="#000000"><img src="<{$xoops_imageurl}>spacer.gif" width="1" height="1" border="0"></td>
                <td width="10%" align="center" bgcolor="#2C2C2C">&nbsp;</td>
              </tr>
            </table>
          </td>
        </tr>
      </table>
    </td>
  </tr>
</table>

  
<table border="0" width="100%" cellspacing="0" cellpadding="0"
style="border: 1px solid rgb(0,0,0)">
  <tr> 
    <td width="100%" bgcolor="#FEE9E4"></td>
    <td width="19" bgcolor="#FEE9E4"></td>
  </tr>
  <tr> 
    <td width="33%" bgcolor="#C0C0C0" height="1"></td>
    <td width="19" bgcolor="#C0C0C0" height="1"></td>
  </tr>
</table>
</body>
</html>



Here is the error i keep getting:
Quote:

This page cannot be displayed due to an internal error.

If you are the administrator of this site, please visit the XOOPS Troubleshooting Page for assistance.

5
DonXoop
Re: Is there any way to...

Would a PHP "auto_prepend_file" do the job? Can set it for the whole server, virtual server, or per directory.

.htaccess:
.
php_value auto_prepend_file "[php file containing header]"
php_value auto_append_file "[php file containing footer]"

6
mgcube
Re: Is there any way to...
  • 2003/11/29 11:02

  • mgcube

  • Just popping in

  • Posts: 36

  • Since: 2003/8/31


I have already got it fixed.

7
DonXoop
Re: Is there any way to...

Good you have fixed it. It is good practice to close the thread with your results and maybe others could learn what your solution was....

Login

Who's Online

112 user(s) are online (70 user(s) are browsing Support Forums)


Members: 0


Guests: 112


more...

Donat-O-Meter

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

Latest GitHub Commits