Advertisement:

Author Topic: Integrating the forum into your site...  (Read 271255 times)

Offline vibez

  • Semi-Newbie
  • *
  • Posts: 55
Re: Integrating the forum into your site...
« Reply #120 on: January 28, 2006, 09:40:27 AM »
Quote

Normally you need to just go through one validation error at a time and sort it out...

But as far as I can see it seems you are including a header? with its own <doctype> and <html> tags. That will render a error in the validation, because SMF already outputs those in the template. So strip your template for these things, or change the included files so that only one set of these are rendered.

I did try that. but when I tried to sort out the errors, I ended up butchering my header :(

Here is my header. Can you see anything that will cause problems when using your method?

http://test.vibez.co.uk/

bloc

  • Guest
Re: Integrating the forum into your site...
« Reply #121 on: January 28, 2006, 09:48:13 AM »
I can only see parts of it..but the source code show no opening <head> tag and doctype is missing...

You should ideally just include('header.php') right after <body> in the forum's index.template..and move any <head> stuff in header.php into the same template. The header.php would then just be the divs, no head or body tags at all.

Offline vibez

  • Semi-Newbie
  • *
  • Posts: 55
Re: Integrating the forum into your site...
« Reply #122 on: January 28, 2006, 11:24:08 AM »
Sorry that previous link is just the header.php on its own. Not merged into the index.template.php. I was just showing you that my stripped down header doesnt include any head or body tags.

this is it merged into the default  index.template.php

http://www.vibez.co.uk/forum/
« Last Edit: January 30, 2006, 04:24:54 AM by vibez »

Offline vibez

  • Semi-Newbie
  • *
  • Posts: 55
Re: Integrating the forum into your site...
« Reply #123 on: January 30, 2006, 04:34:03 AM »
Ok i've investigated a little deeper and I think the code you have told us to add into the index.template.php at the end, isn't fully xhtml compatible?

I've followed your guide for the cooler way and this time I've included a completely blank header.php file. Surely this should prove that the code you have told us to paste into the template is no longer xhtml valid with smf 1.1rc2?

Who knows, i'm losing my mind with this   :-\ :-\ :-\
My site is www.vibez.co.uk/forum

Here is my edited index.template.php

Code: [Select]
<?php
// Version: 1.1 RC2; index

/* This template is, perhaps, the most important template in the theme.  It
contains the main template layer that displays the header and footer of
the forum, namely with main_above and main_below.  It also contains the
menu sub template, which appropriately displays the menu; the init sub
template, which is there to set the theme up; (init can be missing.) and
the linktree sub template, which sorts out the link tree.

The init sub template should load any data and set any hardcoded options.

The main_above sub template is what is shown above the main content, and
should contain anything that should be shown up there.

The main_below sub template, conversely, is shown after the main content.
It should probably contain the copyright statement and some other things.

The linktree sub template should display the link tree, using the data
in the $context[&#39;linktree&#39;] variable.

The menu sub template should display all the relevant buttons the user
wants and or needs.

For more information on the templating system, please see the site at:
http://www.simplemachines.org/
*/

// Initialize the template... mainly little settings.
function template_init()
{
global $context$settings$options$txt;

/* Use images from default theme when using templates from the default theme?
if this is &#39;always&#39;, images from the default theme will be used.
if this is &#39;defaults&#39;, images from the default theme will only be used with default templates.
if this is &#39;never&#39; or isn&#39;t set at all, images from the default theme will not be used. */
$settings[&#39;use_default_images&#39;] = &#39;never&#39;;

/* What document type definition is being used? (for font size and other issues.)
&#39;xhtml&#39; for an XHTML 1.0 document type definition.
&#39;html&#39; for an HTML 4.01 document type definition. */
$settings[&#39;doctype&#39;] = &#39;xhtml&#39;;

/* The version this template/theme is for.
This should probably be the version of SMF it was created for. */
$settings[&#39;theme_version&#39;] = &#39;1.1 RC2&#39;;

/* Set a setting that tells the theme that it can render the tabs. */
$settings[&#39;use_tabs&#39;] = false;

/* Use plain buttons - as oppossed to text buttons? */
$settings[&#39;use_buttons&#39;] = false;

/* Show sticky and lock status seperate from topic icons? */
$settings[&#39;seperate_sticky_lock&#39;] = false;
}

// The main sub template above the content.
function template_main_above()
{
global $context$settings$options$scripturl$txt$modSettings;

// Show right to left and the character set for ease of translating.


// Because of the way width/padding are calculated, we have to tell Internet Explorer 4 and 5 that the content should be 100% wide. (or else it will assume about 108%!)
echo &#39;
<div id="headerarea" style="padding: 12px 30px 4px 30px;&#39;, $context[&#39;browser&#39;][&#39;needs_size_fix&#39;] && !$context[&#39;browser&#39;][&#39;is_ie6&#39;] ? &#39; width: 100%;&#39; : &#39;&#39;, &#39;">&#39;;

// The logo and the three info boxes.
echo &#39;
<table cellspacing="0" cellpadding="0" border="0" width="100%" style="position: relative;">
<tr>
<td colspan="2" valign="bottom" style="padding: 5px; white-space: nowrap;">&#39;;

// This part is the logo and forum name.  You should be able to change this to whatever you want...
echo &#39;
<img src="&#39;, $settings[&#39;images_url&#39;], &#39;/smflogo.gif" style="width: 250px; float: &#39;, !$context[&#39;right_to_left&#39;] ? &#39;right&#39; : &#39;left&#39;, &#39;;" alt="" />&#39;;
if (empty($settings[&#39;header_logo_url&#39;]))
echo &#39;
<span style="font-family: Georgia, sans-serif; font-size: xx-large;">&#39;, $context[&#39;forum_name&#39;], &#39;</span>&#39;;
else
echo &#39;
<img src="&#39;, $settings[&#39;header_logo_url&#39;], &#39;" alt="&#39;, $context[&#39;forum_name&#39;], &#39;" border="0" />&#39;;

echo &#39;
</td>
</tr>
<tr id="upshrinkHeader"&#39;, empty($options[&#39;collapse_header&#39;]) ? &#39;&#39; : &#39; style="display: none;"&#39;, &#39;>
<td valign="top">
<div class="headertitles" style="margin-right: 5px; position: relative;"><img src="&#39;, $settings[&#39;images_url&#39;], &#39;/blank.gif" height="12" alt="" /></div>
<div class="headerbodies" style="position: relative; margin-right: 5px; background-image: url(&#39;, $settings[&#39;images_url&#39;], &#39;/box_bg.gif);">
<img src="&#39;, $settings[&#39;images_url&#39;], &#39;/&#39;, $context[&#39;user&#39;][&#39;language&#39;], &#39;/userinfo.gif" style="position: absolute; left: &#39;, $context[&#39;browser&#39;][&#39;is_ie5&#39;] || $context[&#39;browser&#39;][&#39;is_ie4&#39;] ? &#39;0&#39; : &#39;-1px&#39;, &#39;; top: -16px; clear: both;" alt="" />
<table width="99%" cellpadding="0" cellspacing="5" border="0"><tr>&#39;;

if (!empty($context[&#39;user&#39;][&#39;avatar&#39;]))
echo &#39;<td valign="middle">&#39;, $context[&#39;user&#39;][&#39;avatar&#39;][&#39;image&#39;], &#39;</td>&#39;;

echo &#39;<td valign="top" class="smalltext" style="width: 100%; font-family: verdana, arial, sans-serif;">&#39;;

// If the user is logged in, display stuff like their name, new messages, etc.
if ($context[&#39;user&#39;][&#39;is_logged&#39;])
{
echo &#39;
&#39;, $txt[&#39;hello_member&#39;], &#39; <b>&#39;, $context[&#39;user&#39;][&#39;name&#39;], &#39;</b>&#39;;

// Only tell them about their messages if they can read their messages!
if ($context[&#39;allow_pm&#39;])
echo &#39;, &#39;, $txt[152], &#39; <a href="&#39;, $scripturl, &#39;?action=pm">&#39;, $context[&#39;user&#39;][&#39;messages&#39;], &#39; &#39;, $context[&#39;user&#39;][&#39;messages&#39;] != 1 ? $txt[153] : $txt[471], &#39;</a>&#39;, $txt[&#39;newmessages4&#39;], &#39; &#39;, $context[&#39;user&#39;][&#39;unread_messages&#39;], &#39; &#39;, $context[&#39;user&#39;][&#39;unread_messages&#39;] == 1 ? $txt[&#39;newmessages0&#39;] : $txt[&#39;newmessages1&#39;];
echo &#39;.<br />&#39;;

// Is the forum in maintenance mode?
if ($context[&#39;in_maintenance&#39;] && $context[&#39;user&#39;][&#39;is_admin&#39;])
echo &#39;
<b>&#39;, $txt[616], &#39;</b><br />&#39;;

// Are there any members waiting for approval?
if (!empty($context[&#39;unapproved_members&#39;]))
echo &#39;
&#39;, $context[&#39;unapproved_members&#39;] == 1 ? $txt[&#39;approve_thereis&#39;] : $txt[&#39;approve_thereare&#39;], &#39; <a href="&#39;, $scripturl, &#39;?action=viewmembers;sa=browse;type=approve">&#39;, $context[&#39;unapproved_members&#39;] == 1 ? $txt[&#39;approve_member&#39;] : $context[&#39;unapproved_members&#39;] . &#39; &#39; . $txt[&#39;approve_members&#39;], &#39;</a> &#39;, $txt[&#39;approve_members_waiting&#39;], &#39;<br />&#39;;

// Show the total time logged in?
if (!empty($context[&#39;user&#39;][&#39;total_time_logged_in&#39;]))
{
echo &#39;
&#39;, $txt[&#39;totalTimeLogged1&#39;];

// If days is just zero, don&#39;t bother to show it.
if ($context[&#39;user&#39;][&#39;total_time_logged_in&#39;][&#39;days&#39;] > 0)
echo $context[&#39;user&#39;][&#39;total_time_logged_in&#39;][&#39;days&#39;] . $txt[&#39;totalTimeLogged2&#39;];

// Same with hours - only show it if it&#39;s above zero.
if ($context[&#39;user&#39;][&#39;total_time_logged_in&#39;][&#39;hours&#39;] > 0)
echo $context[&#39;user&#39;][&#39;total_time_logged_in&#39;][&#39;hours&#39;] . $txt[&#39;totalTimeLogged3&#39;];

// But, let&#39;s always show minutes - Time wasted here: 0 minutes ;).
echo $context[&#39;user&#39;][&#39;total_time_logged_in&#39;][&#39;minutes&#39;], $txt[&#39;totalTimeLogged4&#39;], &#39;<br />&#39;;
}

echo &#39;
<a href="&#39;, $scripturl, &#39;?action=unread">&#39;, $txt[&#39;unread_since_visit&#39;], &#39;</a><br />
<a href="&#39;, $scripturl, &#39;?action=unreadreplies">&#39;, $txt[&#39;show_unread_replies&#39;], &#39;</a><br />
&#39;, $context[&#39;current_time&#39;];
}
// Otherwise they&#39;re a guest - so politely ask them to register or login.
else
{
echo &#39;
&#39;, $txt[&#39;welcome_guest&#39;], &#39;<br />
&#39;, $context[&#39;current_time&#39;], &#39;<br />

<script language="JavaScript" type="text/javascript" src="&#39;, $settings[&#39;default_theme_url&#39;], &#39;/sha1.js"></script>

<form action="&#39;, $scripturl, &#39;?action=login2" method="post" style="margin: 3px 1ex 1px 0;"&#39;, empty($context[&#39;disable_login_hashing&#39;]) ? &#39; onsubmit="hashLoginPassword(this, \&#39;&#39; . $context[&#39;session_id&#39;] . &#39;\&#39;);"&#39; : &#39;&#39;, &#39;>
<div style="text-align: right;">
<input type="text" name="user" size="10" /> <input type="password" name="passwrd" size="10" />
<select name="cookielength">
<option value="60">&#39;, $txt[&#39;smf53&#39;], &#39;</option>
<option value="1440">&#39;, $txt[&#39;smf47&#39;], &#39;</option>
<option value="10080">&#39;, $txt[&#39;smf48&#39;], &#39;</option>
<option value="302400">&#39;, $txt[&#39;smf49&#39;], &#39;</option>
<option value="-1" selected="selected">&#39;, $txt[&#39;smf50&#39;], &#39;</option>
</select>
<input type="submit" value="&#39;, $txt[34], &#39;" /><br />
&#39;, $txt[&#39;smf52&#39;], &#39;
<input type="hidden" name="hash_passwrd" value="" />
</div>
</form>&#39;;
}

echo &#39;
</td></tr></table>
</div>

<form action="&#39;, $scripturl, &#39;?action=search2" method="post" style="margin: 0;">
<div style="margin-top: 7px;">
<b>&#39;, $txt[182], &#39;: </b><input type="text" name="search" value="" style="width: 190px;" />&nbsp;
<input type="submit" name="submit" value="&#39;, $txt[182], &#39;" style="width: 8ex;" />&nbsp;
<a href="&#39;, $scripturl, &#39;?action=search;advanced">&#39;, $txt[&#39;smf298&#39;], &#39;</a>
<input type="hidden" name="advanced" value="0" />&#39;;

// Search within current topic?
if (!empty($context[&#39;current_topic&#39;]))
echo &#39;
<input type="hidden" name="topic" value="&#39;, $context[&#39;current_topic&#39;], &#39;" />&#39;;

// If we&#39;re on a certain board, limit it to this board ;).
elseif (!empty($context[&#39;current_board&#39;]))
echo &#39;
<input type="hidden" name="brd[&#39;, $context[&#39;current_board&#39;], &#39;]" value="&#39;, $context[&#39;current_board&#39;], &#39;" />&#39;;

echo &#39;
</div>
</form>

</td>
<td style="width: 262px; &#39;, !$context[&#39;right_to_left&#39;] ? &#39;padding-left&#39; : &#39;padding-right&#39;, &#39;: 6px;" valign="top">&#39;;

// Show a random news item? (or you could pick one from news_lines...)
if (!empty($settings[&#39;enable_news&#39;]))
echo &#39;
<div class="headertitles" style="width: 260px;"><img src="&#39;, $settings[&#39;images_url&#39;], &#39;/blank.gif" height="12" alt="" /></div>
<div class="headerbodies" style="width: 260px; position: relative; background-image: url(&#39;, $settings[&#39;images_url&#39;], &#39;/box_bg.gif); margin-bottom: 8px;">
<img src="&#39;, $settings[&#39;images_url&#39;], &#39;/&#39;, $context[&#39;user&#39;][&#39;language&#39;], &#39;/newsbox.gif" style="position: absolute; left: -1px; top: -16px;" alt="" />
<div style="height: 50px; overflow: auto; padding: 5px;" class="smalltext">&#39;, $context[&#39;random_news_line&#39;], &#39;</div>
</div>&#39;;

// The "key stats" box.
echo &#39;
<div class="headertitles" style="width: 260px;"><img src="&#39;, $settings[&#39;images_url&#39;], &#39;/blank.gif" height="12" alt="" /></div>
<div class="headerbodies" style="width: 260px; position: relative; background-image: url(&#39;, $settings[&#39;images_url&#39;], &#39;/box_bg.gif);">
<img src="&#39;, $settings[&#39;images_url&#39;], &#39;/&#39;, $context[&#39;user&#39;][&#39;language&#39;], &#39;/keystats.gif" style="position: absolute; left: -1px; top: -16px;" alt="" />
<div style="&#39;, !$context[&#39;browser&#39;][&#39;is_ie&#39;] ? &#39;min-height: 35px;&#39; : &#39;height: 4em;&#39;, &#39; padding: 5px;" class="smalltext">
<b>&#39;, $context[&#39;common_stats&#39;][&#39;total_posts&#39;], &#39;</b> &#39;, $txt[95], &#39; &#39;, $txt[&#39;smf88&#39;], &#39; <b>&#39;, $context[&#39;common_stats&#39;][&#39;total_topics&#39;], &#39;</b> &#39;, $txt[64], &#39; &#39;, $txt[525], &#39; <span style="white-space: nowrap;"><b>&#39;, $context[&#39;common_stats&#39;][&#39;total_members&#39;], &#39;</b> &#39;, $txt[19], &#39;</span><br />
&#39;, $txt[656], &#39;: <b> &#39;, $context[&#39;common_stats&#39;][&#39;latest_member&#39;][&#39;link&#39;], &#39;</b>
</div>
</div>&#39;;

echo &#39;
</td>
</tr>
</table>

<a href="javascript:void(0);" onclick="shrinkHeader(!current_header); return false;"><img id="upshrink" src="&#39;, $settings[&#39;images_url&#39;], &#39;/&#39;, empty($options[&#39;collapse_header&#39;]) ? &#39;upshrink.gif&#39; : &#39;upshrink2.gif&#39;, &#39;" alt="*" title="&#39;, $txt[&#39;upshrink_description&#39;], &#39;" style="margin: 2px 2ex 2px 0;" border="0" /></a>&#39;;

// Show the menu here, according to the menu sub template.
template_menu();

echo &#39;
</div>&#39;;

// The main content should go here.  A table is used because IE 6 just can&#39;t handle a div.
echo &#39;
<table width="100%" cellpadding="0" cellspacing="0" border="0"><tr>
<td id="bodyarea" style="padding: 1ex 20px 2ex 20px;">&#39;;
}

function 
template_main_below()
{
global $context$settings$options$scripturl$txt;

echo &#39;</td>
</tr></table>&#39;;

// Show the "Powered by" and "Valid" logos, as well as the copyright.  Remember, the copyright must be somewhere!
echo &#39;

<div id="footerarea" style="text-align: center; padding-bottom: 1ex;&#39;, $context[&#39;browser&#39;][&#39;needs_size_fix&#39;] && !$context[&#39;browser&#39;][&#39;is_ie6&#39;] ? &#39; width: 100%;&#39; : &#39;&#39;, &#39;">
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
function smfFooterHighlight(elementvalue)
{
element.src smf_images_url "/" + (value "h_" "") + element.id ".gif";
}
// ]]></script>
<table cellspacing="0" cellpadding="3" border="0" width="100%">
<tr>
<td width="28%" valign="middle" align="&#39;, !$context[&#39;right_to_left&#39;] ? &#39;right&#39; : &#39;left&#39;, &#39;">
<a href="http://www.mysql.com/" target="_blank"><img id="powered-mysql" src="&#39;, $settings[&#39;images_url&#39;], &#39;/powered-mysql.gif" alt="&#39;, $txt[&#39;powered_by_mysql&#39;], &#39;" width="54" height="20" style="margin: 5px 16px;" border="0" onmouseover="smfFooterHighlight(this, true);" onmouseout="smfFooterHighlight(this, false);" /></a>
<a href="http://www.php.net/" target="_blank"><img id="powered-php" src="&#39;, $settings[&#39;images_url&#39;], &#39;/powered-php.gif" alt="&#39;, $txt[&#39;powered_by_php&#39;], &#39;" width="54" height="20" style="margin: 5px 16px;" border="0" onmouseover="smfFooterHighlight(this, true);" onmouseout="smfFooterHighlight(this, false);" /></a>
</td>
<td valign="middle" align="center" style="white-space: nowrap;">
&#39;, theme_copyright(), &#39;
</td>
<td width="28%" valign="middle" align="&#39;, !$context[&#39;right_to_left&#39;] ? &#39;left&#39; : &#39;right&#39;, &#39;">
<a href="http://validator.w3.org/check/referer" target="_blank"><img id="valid-xhtml10" src="&#39;, $settings[&#39;images_url&#39;], &#39;/valid-xhtml10.gif" alt="&#39;, $txt[&#39;valid_xhtml&#39;], &#39;" width="54" height="20" style="margin: 5px 16px;" border="0" onmouseover="smfFooterHighlight(this, true);" onmouseout="smfFooterHighlight(this, false);" /></a>
<a href="http://jigsaw.w3.org/css-validator/check/referer" target="_blank"><img id="valid-css" src="&#39;, $settings[&#39;images_url&#39;], &#39;/valid-css.gif" alt="&#39;, $txt[&#39;valid_css&#39;], &#39;" width="54" height="20" style="margin: 5px 16px;" border="0" onmouseover="smfFooterHighlight(this, true);" onmouseout="smfFooterHighlight(this, false);" /></a>
</td>
</tr>
</table>&#39;;

// Show the load time?
if ($context[&#39;show_load_time&#39;])
echo &#39;
<span class="smalltext">&#39;, $txt[&#39;smf301&#39;], $context[&#39;load_time&#39;], $txt[&#39;smf302&#39;], $context[&#39;load_queries&#39;], $txt[&#39;smf302b&#39;], &#39;</span>&#39;;

echo &#39;
</div>&#39;;

// This is an interesting bug in Internet Explorer AND Safari.  Rather annoying, it makes overflows just not tall enough.
if (($context[&#39;browser&#39;][&#39;is_ie&#39;] && !$context[&#39;browser&#39;][&#39;is_ie4&#39;]) || $context[&#39;browser&#39;][&#39;is_mac_ie&#39;] || $context[&#39;browser&#39;][&#39;is_safari&#39;])
{
// The purpose of this code is to fix the height of overflow: auto div blocks, because IE can&#39;t figure it out for itself.
echo &#39;
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[&#39;;

// Unfortunately, Safari does not have a "getComputedStyle" implementation yet, so we have to just do it to code...
if ($context[&#39;browser&#39;][&#39;is_safari&#39;])
echo &#39;
window.addEventListener("load"smf_codeFixfalse);

function smf_codeFix()
{
var codeFix document.getElementsByTagName document.getElementsByTagName("div") : document.all.tags("div");

for (var 0codeFix.lengthi++)
{
if ((codeFix[i].className == "code" || codeFix[i].className == "post" || codeFix[i].className == "signature") && codeFix[i].offsetHeight 20)
codeFix[i].style.height = (codeFix[i].offsetHeight 20) + "px";
}
}&#39;;
else
{
echo &#39;
var window_oldOnload window.onload;
window.onload smf_codeFix;

function smf_codeFix()
{
var codeFix document.getElementsByTagName document.getElementsByTagName("div") : document.all.tags("div");

for (var codeFix.length 10i--)
{
if (codeFix[i].currentStyle.overflow == "auto" && (codeFix[i].currentStyle.height == "" || codeFix[i].currentStyle.height == "auto") && (codeFix[i].scrollWidth codeFix[i].clientWidth || codeFix[i].clientWidth == 0) && (codeFix[i].offsetHeight != || codeFix[i].className == "code"))
codeFix[i].style.height = (codeFix[i].offsetHeight 36) + "px";
}

if (window_oldOnload)
{
window_oldOnload();
window_oldOnload null;
}
}&#39;;
}

echo &#39;
// ]]></script>&#39;;
}
}

// Show a linktree.  This is that thing that shows "My Community | General Category | General Discussion"..
function theme_linktree()
{
global $context$settings$options;

// Folder style or inline?  Inline has a smaller font.
echo &#39;<span class="nav"&#39;, $settings[&#39;linktree_inline&#39;] ? &#39; style="font-size: smaller;"&#39; : &#39;&#39;, &#39;>&#39;;

// Each tree item has a URL and name.  Some may have extra_before and extra_after.
foreach ($context[&#39;linktree&#39;] as $link_num => $tree)
{
// Show the | | |-[] Folders.
if (!$settings[&#39;linktree_inline&#39;])
{
if ($link_num 0)
echo str_repeat(&#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/icons/linktree_main.gif" alt="| " border="0" />&#39;, $link_num - 1), &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/icons/linktree_side.gif" alt="|-" border="0" />&#39;;
echo &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/icons/folder_open.gif" alt="+" border="0" />&nbsp; &#39;;
}

// Show something before the link?
if (isset($tree[&#39;extra_before&#39;]))
echo $tree[&#39;extra_before&#39;];

// Show the link, including a URL if it should have one.
echo &#39;<b>&#39;, $settings[&#39;linktree_link&#39;] && isset($tree[&#39;url&#39;]) ? &#39;<a href="&#39; . $tree[&#39;url&#39;] . &#39;" class="nav">&#39; . $tree[&#39;name&#39;] . &#39;</a>&#39; : $tree[&#39;name&#39;], &#39;</b>&#39;;

// Show something after the link...?
if (isset($tree[&#39;extra_after&#39;]))
echo $tree[&#39;extra_after&#39;];

// Don&#39;t show a separator for the last one.
if ($link_num != count($context[&#39;linktree&#39;]) - 1)
echo $settings[&#39;linktree_inline&#39;] ? &#39; &nbsp;|&nbsp; &#39; : &#39;<br />&#39;;
}

echo &#39;</span>&#39;;
}

// Show the menu up top.  Something like [home] [help] [profile] [logout]...
function template_menu()
{
global $context$settings$options$scripturl$txt;

// Show the [home] and [help] buttons.
echo &#39;
<a href="&#39;, $scripturl, &#39;">&#39;, ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . $context[&#39;user&#39;][&#39;language&#39;] . &#39;/home.gif" alt="&#39; . $txt[103] . &#39;" style="margin: 2px 0;" border="0" />&#39; : $txt[103]), &#39;</a>&#39;, $context[&#39;menu_separator&#39;], &#39;
<a href="&#39;, $scripturl, &#39;?action=help">&#39;, ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . $context[&#39;user&#39;][&#39;language&#39;] . &#39;/help.gif" alt="&#39; . $txt[119] . &#39;" style="margin: 2px 0;" border="0" />&#39; : $txt[119]), &#39;</a>&#39;, $context[&#39;menu_separator&#39;];

// How about the [search] button?
if ($context[&#39;allow_search&#39;])
echo &#39;
<a href="&#39;, $scripturl, &#39;?action=search">&#39;, ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . $context[&#39;user&#39;][&#39;language&#39;] . &#39;/search.gif" alt="&#39; . $txt[182] . &#39;" style="margin: 2px 0;" border="0" />&#39; : $txt[182]), &#39;</a>&#39;, $context[&#39;menu_separator&#39;];

// Is the user allowed to administrate at all? ([admin])
if ($context[&#39;allow_admin&#39;])
echo &#39;
<a href="&#39;, $scripturl, &#39;?action=admin">&#39;, ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . $context[&#39;user&#39;][&#39;language&#39;] . &#39;/admin.gif" alt="&#39; . $txt[2] . &#39;" style="margin: 2px 0;" border="0" />&#39; : $txt[2]), &#39;</a>&#39;, $context[&#39;menu_separator&#39;];

// Edit Profile... [profile]
if ($context[&#39;allow_edit_profile&#39;])
echo &#39;
<a href="&#39;, $scripturl, &#39;?action=profile">&#39;, ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . $context[&#39;user&#39;][&#39;language&#39;] . &#39;/profile.gif" alt="&#39; . $txt[79] . &#39;" style="margin: 2px 0;" border="0" />&#39; : $txt[467]), &#39;</a>&#39;, $context[&#39;menu_separator&#39;];

// The [calendar]!
if ($context[&#39;allow_calendar&#39;])
echo &#39;
<a href="&#39;, $scripturl, &#39;?action=calendar">&#39;, ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . $context[&#39;user&#39;][&#39;language&#39;] . &#39;/calendar.gif" alt="&#39; . $txt[&#39;calendar24&#39;] . &#39;" style="margin: 2px 0;" border="0" />&#39; : $txt[&#39;calendar24&#39;]), &#39;</a>&#39;, $context[&#39;menu_separator&#39;];

// If the user is a guest, show [login] and [register] buttons.
if ($context[&#39;user&#39;][&#39;is_guest&#39;])
{
echo &#39;
<a href="&#39;, $scripturl, &#39;?action=login">&#39;, ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . $context[&#39;user&#39;][&#39;language&#39;] . &#39;/login.gif" alt="&#39; . $txt[34] . &#39;" style="margin: 2px 0;" border="0" />&#39; : $txt[34]), &#39;</a>&#39;, $context[&#39;menu_separator&#39;], &#39;
<a href="&#39;, $scripturl, &#39;?action=register">&#39;, ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . $context[&#39;user&#39;][&#39;language&#39;] . &#39;/register.gif" alt="&#39; . $txt[97] . &#39;" style="margin: 2px 0;" border="0" />&#39; : $txt[97]), &#39;</a>&#39;;
}
// Otherwise, they might want to [logout]...
else
echo &#39;
<a href="&#39;, $scripturl, &#39;?action=logout;sesc=&#39;, $context[&#39;session_id&#39;], &#39;">&#39;, ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . $context[&#39;user&#39;][&#39;language&#39;] . &#39;/logout.gif" alt="&#39; . $txt[108] . &#39;" style="margin: 2px 0;" border="0" />&#39; : $txt[108]), &#39;</a>&#39;;
}

// Generate a strip of buttons, out of buttons.
function template_button_strip($button_strip$direction = &#39;top&#39;, $force_reset = false, $custom_td = &#39;&#39;)
{
global $settings$buttons$context$txt$scripturl;

if (empty($button_strip))
return &#39;&#39;;

// Create the buttons...
foreach ($button_strip as $key => $value)
{
if (isset($value[&#39;test&#39;]) && empty($context[$value[&#39;test&#39;]]))
{
unset($button_strip[$key]);
continue;
}
elseif (!isset($buttons[$key]) || $force_reset)
$buttons[$key] = &#39;<a href="&#39; . $value[&#39;url&#39;] . &#39;" &#39; .( isset($value[&#39;custom&#39;]) ? $value[&#39;custom&#39;] : &#39;&#39;) . &#39;>&#39; . ($settings[&#39;use_image_buttons&#39;] ? &#39;<img src="&#39; . $settings[&#39;images_url&#39;] . &#39;/&#39; . ($value[&#39;lang&#39;] ? $context[&#39;user&#39;][&#39;language&#39;] . &#39;/&#39; : &#39;&#39;) . $value[&#39;image&#39;] . &#39;" alt="&#39; . $txt[$value[&#39;text&#39;]] . &#39;" border="0" />&#39; : $txt[$value[&#39;text&#39;]]) . &#39;</a>&#39;;

$button_strip[$key] = $buttons[$key];
}

echo &#39;
<td &#39;, $custom_td, &#39;>&#39;, implode($context[&#39;menu_separator&#39;], $button_strip) , &#39;</td>&#39;;
}
function 
template_site_above()
{
global $context$settings$options$scripturl$txt$modSettings;

echo &#39;<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html><head>
<script language="JavaScript" type="text/javascript" src="&#39;, $settings[&#39;default_theme_url&#39;], &#39;/script.js"></script>
<script language="JavaScript" type="text/javascript"><!--
var smf_theme_url "&#39;, $settings[&#39;theme_url&#39;], &#39;";
var smf_images_url "&#39;, $settings[&#39;images_url&#39;], &#39;";
// --></script>
<title>&#39;, $context[&#39;page_title&#39;], &#39;</title>
<link rel="stylesheet" type="text/css" href="&#39;, $settings[&#39;theme_url&#39;], &#39;/style.css?rc1" />&#39;;

if ($context[&#39;browser&#39;][&#39;needs_size_fix&#39;])
echo &#39;
<link rel="stylesheet" type="text/css" href="&#39;, $settings[&#39;default_theme_url&#39;], &#39;/fonts-compat.css" />
&#39;, $context[&#39;html_headers&#39;], &#39;
</head>
<
body>&#39;;

include(&#39;header.php&#39;);
}

function 
template_site_below()
{
global $context$settings$options$scripturl$txt$modSettings;

include(&#39;footer.php&#39;);

echo &#39;
</body></html>&#39;;
}
?>

and here are my errors

Code: [Select]
This page is not Valid XHTML 1.0 Transitional!

Below are the results of checking this document for XML well-formedness and validity.

   1. Error Line 10 column 58: document type does not allow element "div" here; assuming missing "object" start-tag.

      <div id="headerarea" style="padding: 12px 30px 4px 30px;">

      ✉
   2. Error Line 184 column 6: end tag for element "body" which is not open.

      </body></html>

      The Validator found an end tag for the above element, but that element is not currently open. This is often caused by a leftover end tag from an element that was removed during editing, or by an implicitly closed element (if you have an error related to an element being used where it is not allowed, this is almost certainly the case). In the latter case this error will disappear as soon as you fix the original problem.

      If this error occured in a script section of your document, you should probably read this FAQ entry.

      ✉
   3. Error Line 184 column 13: end tag for "object" omitted, but OMITTAG NO was specified.

      </body></html>

      You may have neglected to close an element, or perhaps you meant to "self-close" an element, that is, ending it with "/>" instead of ">".

      ✉
   4. Info Line 10 column 1: start tag was here.

      <div id="headerarea" style="padding: 12px 30px 4px 30px;">

   5. Error Line 184 column 13: end tag for "head" omitted, but OMITTAG NO was specified.

      </body></html>

      ✉
   6. Info Line 2 column 6: start tag was here.

      <html><head>

   7. Error Line 184 column 13: end tag for "html" which is not finished.

      </body></html>

      Most likely, You nested tags and closed them in the wrong order. For example <p><em>...</p> is not acceptable, as <em> must be closed before <p>. Acceptable nesting is: <p><em>...</em></p>

      Another possibility is that you used an element which requires a child element that you did not include. Hence the parent element is "not finished", not complete. For instance, <head> generally requires a <title>, lists (ul, ol, dl) require list items (li, or dt, dd), and so on.

Offline Mr.Doro

  • Newbie
  • *
  • Posts: 1
Re: Integrating the forum into your site...
« Reply #124 on: February 09, 2006, 01:50:19 PM »
Hi, i Want to Intergrate such things as Lastest Posts and such into a Joomla Based Website, could anyone help me with this?

Thanks
Doro

Offline jrcarr

  • Jr. Member
  • **
  • Posts: 142
  • Gender: Male
  • Following the boards
    • Upholstery Website
Re: Integrating the forum into your site...
« Reply #125 on: February 09, 2006, 11:18:10 PM »
[Unknown] or anyone with any thoughts on this:

What would need to be added to the code in either of the two methods listed by [Unknown] in the first two posts, to limit access of the page to just selected groups?

Jack
Jack Carr

Offline Acf

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 3,967
  • Gender: Male
  • 101101010112
Re: Integrating the forum into your site...
« Reply #126 on: February 10, 2006, 05:07:26 AM »
Have you tried?:
http://www.simplemachines.org/community/index.php?topic=14906.0
I am sure your anwser is there. ;)
Sigh...

Offline jrcarr

  • Jr. Member
  • **
  • Posts: 142
  • Gender: Male
  • Following the boards
    • Upholstery Website
Re: Integrating the forum into your site...
« Reply #127 on: February 10, 2006, 10:13:01 AM »
Thank you!  Yes, my answer was there and the answer to many other questions I have had.  I've used the last version of Yabbse for quite some time on one site and have SMF on another.  The Yabbse site has required that I do a number of code changes inside key /Source/ files to get some things in yabbse to do things that SMF now does as standard features.  However, trying to upgrade this site to SMF has been an intimidating idea, because of all the code changes I have had to make.  The use and changes in the SSI.php file and just taking time to really read through it, solves about 95% of the reasons that I haven't been able to update this forum in the past.  I believe that with a little further reading and research of the SMF site,  I will be able to solve the other 5% of my problems.  With this, I will be able to do upgrades as they come out and not have to worry about breaking the rest of my site at: www.carrscorner.com .  I have created a membership site using the login information from the forum, limiting access to several items based on the member's group.   Anyway, to keep a long story short, I am highly impressed with SMF and the direction it has taken and will be upgrading shortly after pre-preparing some pages so that they will still be accessible by the right group/s once the upgrade is completed.

Jack
Jack Carr

Offline Confused Too

  • Semi-Newbie
  • *
  • Posts: 81
  • Gender: Male
  • SMF Works for Me
Re: Integrating the forum into your site...RC2
« Reply #128 on: February 16, 2006, 05:48:20 PM »
Is there a simple method to intigrate a forum entirely into a site yet leaving the users the ability to change their themes as they choose?
I have had RC1 running on my site for a while now and found it a little fiddly to change all the themes then along comes RC2 which doesn't appear to work correctly.  However, I have decided to use the default themes but wrap it into an iframe on another HTML document.  However, this is a problem for screen readers.
I have been using Active Scripts ActiveBook and they have a great method for integration.  They simply provide a box for the code to go before the book and another for the code to end it.  As long as you only use the code from body down to the start of your forum and then the other end of the HTML goes into another box and save.  Hey presto you have just wrapped your guestbook in your own site template?

Now knowing how complex and intigrated the SMF forums can be I am sure there must be another more simple way to do it than all the ways discussed here which would have have the robustness to withstand any upgrades or updates :D
Making the working lives of the disadvantaged a little easier.

Offline jrcarr

  • Jr. Member
  • **
  • Posts: 142
  • Gender: Male
  • Following the boards
    • Upholstery Website
Re: Integrating the forum into your site...
« Reply #129 on: February 16, 2006, 06:23:06 PM »
HuttonIT,

I am by no means and expert at HTML, PHP, Themes, templates..... I know a little about a lot and alot about nothing.  ;)
Anyway, if you had seem my site at: www.carrscorner.com last Saturday morning and then later at about 10 pm that night, you would have seen little to no visible difference in the site.  At noon Saturday, I started upgrading by extremely modified Yabbse 1.5.5 board to SMF 1.0.6  The actual upgrade of the forum went pretty much as smooth as any upgrade I've done.  However, because of the excessive modification to Source files in Yabbse and creating my own template that wraps around it and all other pages on my site, getting the site back to it's original look was a scary thought.  I haven't worked with themes much in the past and so had to figure that out and how to make it look like the Template I had made for the site.  With some reading of the various topics here in the Themes section and learning about how to use the SSI.php file I was able to not only get my site back to the look my users were use to seeing, but most all of my intergrations and modifications were able to be solved and in most cases improved.  Much of the changes to the Theme came from adding includes of my original template into the right Template files in Themes/mytheme/.  As I said, it took a little reading, but now all is well.  In the next week or so I will make the necessary changes to the other Themes, so that my template for the Header, left menu and footer just wraps around the theme design.  In some cases this is going to cause some ugly color combinations, but that will still be at the option of each user and the theme they decide to select.  At this time, they are not give an option, but as I make each conversion, I'll add that them as an option.  The Themes in SMF are actually much simplier to modify than I ever expected and will eventually be able to make my Template be able to change colors with CSS so that it matches the other Theme colors.

Jack
Jack Carr

Offline Confused Too

  • Semi-Newbie
  • *
  • Posts: 81
  • Gender: Male
  • SMF Works for Me
Re: Integrating the forum into your site...
« Reply #130 on: February 17, 2006, 05:14:55 AM »
jrcarr,
I appreciate that it can be done but every time there is an upgrade you have to go through the whole process again.  How about a simple method which lends SMF to integration as a standard feature instead of messing about with the code for every theme.
I already have RC1 themes customised but with the new release I have decided that I haven't got the time to keep doing it every time.  The simple option would be to build into the basic code of SMF the ability to use the top and bottom files if you want to.  It would also mean that if you re-design your site all you have to do is edit those files and nothing else changes.
I have decided that until this is available I will use an ilayer and point users to that.  The only other difficulty is that the links sent out to people will take them to the unwrapped version of the forum.  Where as if this were part of the SMF coded intigration would not happen.
Making the working lives of the disadvantaged a little easier.

Offline jrcarr

  • Jr. Member
  • **
  • Posts: 142
  • Gender: Male
  • Following the boards
    • Upholstery Website
Re: Integrating the forum into your site...
« Reply #131 on: February 17, 2006, 09:59:15 AM »
Well, I guess that what I haven't had the opportunity to see, is whether with each up grade they make changes to the template system or not.  Since I have now created my own theme and named it different than the "Default" or Classic", I'm figuring that the upgrades won't be over writing those files, so the worse case scenerio would be to have to make some adjustments to my themes.  Before, I had re-written actual code in Source files for the Forum, so there was no doubt that the files were going to be over-written. 
The tendency to make changes to everything with each upgrade is one of the reasons I don't upgrade with every single new version that releases.  I manage two websites that require enough time to keep operating, add new features, write newsletters, answer questions.....to have to be taking time to make theme, template or programming changes for every upgrade that releases too.
I all fairness though, this is a problem with many of the Open-Source programs.  When adding new features or improving old features, causes changes to template files, so most time previous template files won't work with new releases.
Even when I had a template design that wrapped itself around SMF, the same template would have to be adjusted a little to wrap around Coppermine and just a little change to wrap around my own pages.  I was having to have 3-4 different set of Header and footer files depending on the need of the give program I was trying to wrap my template around.  Even doing this, my site that has been running SMF since the first release, required adjustments to my Header and footer files to get new releases/versions to work most of the time.
So there is not perfect solution to this problem.  You are going to find that there will be some adjustments to make everytime SMF or any other software you are using releases a new version.  It's kind of like, "Death and Taxes".  ;D

Jack
Jack Carr

Offline Confused Too

  • Semi-Newbie
  • *
  • Posts: 81
  • Gender: Male
  • SMF Works for Me
Re: Integrating the forum into your site...
« Reply #132 on: February 17, 2006, 03:44:16 PM »
So there is not perfect solution to this problem.  You are going to find that there will be some adjustments to make everytime SMF or any other software you are using releases a new version.  It's kind of like, "Death and Taxes".  ;D
LOL - Your right but running a forum which requires accessability I have to offer various colour, text only and screen reader friendly templates which all have to be edited to allow the updates.  It would be nice to simply use my site template cut in half to wrap seamlessly around the themes each time so when I do perform an upgrade there is no messing about except importing the new compliant themes in the colours and options offered.
The actual software is the best I have ever seen and I was a skeptic about SMF only 6 months ago now I am completely sold on it and find it exceptionally user friendly and intuitive to use.
I suppose this may be an option someone will build into future releases in the future.
Making the working lives of the disadvantaged a little easier.

Offline Enigma

  • Semi-Newbie
  • *
  • Posts: 71
    • Night Train Webhosting
Re: Integrating the forum into your site...
« Reply #133 on: March 08, 2006, 04:55:02 PM »
Can someone explain to me in simple terms how I can have tabs (like on this forum) that I can use that will point to pages outside of the forum and still keep the tabs for navigation?

Offline sydbat

  • Semi-Newbie
  • *
  • Posts: 16
  • Gender: Male
    • http://www.facebook.com/CAPICalgary on Facebook
    • Calgary Association of Paranormal Investigations
Re: Integrating the forum into your site...
« Reply #134 on: March 14, 2006, 01:05:32 PM »
I want to thank everyone (especially [Unknown]) for their help in showing the steps for integrating SMF into my website (CAPI Forum [nofollow]). I used the "simple" tutorial provided and then followed my nose to get exactly what I wanted. Some day I'll try the "cooler" way.

I made a backup of the default theme, renamed it, and played with the code. I left everything in place. In <head>, before the SMF javascript, I added my javascript sources like so:
Code: [Select]
// Show right to left and the character set for ease of translating.
echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html', $context['right_to_left'] ? ' dir="rtl"' : '', '><head>
<meta http-equiv="Content-Type" content="text/html; charset=', $context['character_set'], '" />
<meta name="description" content="', $context['page_title'], '" />
<meta name="keywords" content="PHP, MySQL, bulletin, board, free, open, source, smf, simple, machines, forum" />
 
  <script src="http://www.capi7.ca/menu_array.js" type="text/javascript"></script>
  <script src="http://www.capi7.ca/invest.js" type="text/javascript"></script>
  <script src="http://www.capi7.ca/foot.js" type="text/javascript"></script>
  <script src="http://www.capi7.ca/update.js" type="text/javascript"></script>
  <script src="http://www.capi7.ca/mmenu.js" type="text/javascript"></script>
<script language="JavaScript" type="text/javascript" src="', $settings['default_theme_url'], '/script.js"></script>
<script language="JavaScript" type="text/javascript"><!--
var smf_theme_url = "', $settings['theme_url'], '";
var smf_images_url = "', $settings['images_url'], '";
// --></script>

I replaced the stylesheet with my own hybrid. I took the existing SMF stylesheet and added the elements from my stylesheet to create the container for the the forum.

Then, at the top of the <body>, I added
Code: [Select]
<body>';
echo '<div class="container">';
  echo '<div class="banner" id="logo">
<h1 id="title">Calgary Association of Paranormal Investigations</h1>
  </div>';
echo '<div class="content" id="content">';

This gave me the result I wanted with very little discomfort. Now my contributors can choose if they want the "classic" forum style or the "new and improved" forum default.

One question - When I upgrade to 1.1 RC2 (or any following release), will I have to do all this again?

Once again, thank you all for your well written posts. And thank you Lewis Media for developing SMF!!
Don't mess with the dead boy. They have eerie powers.
    - Homer J Simpson

CAPI Forum [nofollow]

Offline Telnets

  • Newbie
  • *
  • Posts: 1
Re: Integrating the forum into your site...
« Reply #135 on: March 21, 2006, 02:26:33 PM »
ok I know this has been gone over and over, but Im still having issues getting it to sit where its suposed to on my site. I Am trying to use the rc2 package and follow these instructions but its not going very well.. Ive noticed a few small "Differences" in your examples and in the code. Is this tutorial written for 1.0.6 perhaps? Maybe thats my issue there.

Basicaly, i want to throw the forums in the <td> call i have where my content is suposed to go. I have a header.php and a footer.php file that wraps the site around any content i have right now. It all works awsome. Except when i try to put the forums in there.

Ive followed the directions you posted to the letter (minus the issue with the code not being exact). I can get it into the table i need.. however when it does go in there, the footer tables that close off the cells from the header are all messed up. Almost like the forums software has an extra </td> call or something. Thats about as close as i can get to having it work.

I can however take my index file, which calls my header/footer files.. throw and include to /forums/index.php in the middle, and everything looks exactly how i want it to.. The only issue with doing that of course is it all looks well and fine.. untill you click on a topic or option and it sends it full screen.

If there is any other suggestions, or ways to get this working i would love to hear it. Ive tried BOTH meathods you have posted and so far no luck. I can get things going with a silly <iframe> call.. but unfortunatly thats not a good way of doing this, and i would like the include to be working properly.

Even if there is anyone that has sucessfully wrapped thier site around thier forum that could take a look at mine through PM which i could give you the passwords to poke around or something?

Thanks very much. Im trying 1.0.6 now to see if it might work any better.
« Last Edit: March 21, 2006, 02:58:46 PM by Telnets »

Offline Leipe Po

  • Sr. Member
  • ****
  • Posts: 700
  • Gender: Male
  • Bookmark Mod 1.0
    • PhpScripters(under construction)
Re: Integrating the forum into your site...
« Reply #136 on: March 24, 2006, 02:28:38 PM »
http://www.phpscripters.net

its completly intergrated
There is only one thing more importend to me then coding:
My Girlfriend

Microsoft - "You've got questions.  We've got dancing paperclips."

Offline Eleazar

  • Newbie
  • *
  • Posts: 3
Re: Integrating the forum into your site...
« Reply #137 on: March 26, 2006, 10:28:00 AM »
I did the simple method, but I get an error for line 2 of index.template.php.

This is line 2 in that file: <html><head>

Line 1 is: <?php

Is this correct????

Offline jrcarr

  • Jr. Member
  • **
  • Posts: 142
  • Gender: Male
  • Following the boards
    • Upholstery Website
Re: Integrating the forum into your site...
« Reply #138 on: March 26, 2006, 11:51:28 AM »
There should be an echo ' before and  a '; after those.  In my index.template.php there is actually a lot of html code that is surronded by an echo ' {html code} '; (no curly bracket).

You either need to close the <?php with a ?> then have the html code and then when there is more PHP you start a new <?php or use the echo statement to surround the html code.

Jack
Jack Carr

Offline Eleazar

  • Newbie
  • *
  • Posts: 3
Re: Integrating the forum into your site...
« Reply #139 on: March 26, 2006, 04:05:04 PM »
Thanks man! That's what I needed.

Now, I have a new error on line 188: syntax error, unexpected '}'

I removed the }, but it doesn't display the board correctly then.
The board can be seen hxxp:calvarywv.com/board/Themes/Integrated%20Test/index.template.php [nonactive].