Integrating the forum into your site...

Started by [Unknown], November 09, 2004, 11:18:05 PM

Previous topic - Next topic

Martje

ok that looks really wierd if you get into a post , did you edit the original theme or did you made a new theme and edit that one.
the safest way not messing up your board is making a new theme and edit that one.

if you post your header and footer here i will take a look at that cause now it looks like there is nothing in your header and footer.

I can take a quicklook if you make me an admin on that board for now so i can see what went wrong and where. you can PM me the details if you want

MeRcChRiS

oh dang, i edited the original....ok well im gonna make a new of the original.

yeah ill make you a admin, just sign up and you can take a look.

Xaneth

Thank you so much for the tips!  I went the cooler way and enabled SSI.  I was really wanting to be able to provide dynamic content for my main website based on posts in the forum.  I learned a lot over the weekend, and everything is seamless now!  I am still working with CSS to make everything better, but it's fully functional.  My site is at www.mirrorstonemusic.com.  Check out the news page, killer!

Xaneth

#183
A couple of quick questions.  Now that I have my theme up and running, whenever I go to make a post, delete a post, or any other action that would normally take me back to the board I was posting in, it takes me to a blank page.  For instance, after creating a new post, it takes me to the following site with a blank page:

http://www.mirrorstonemusic.com/forum/index.php?action=post2;start=0;board=7

I'm running a couple of mods as well.  TinyPortal .96, Post by Email, Streaming 3 and BBC-Google 2.5.1.

One other question I have is:  The header and footer are working great!  The issue that I'm seeing is that when I click on the forum link, or move about the forum, the background takes a bit before it kicks in.  Any way to get around this?  Pre-caching perhaps?

Xaneth

Got it all fixed up, corruption somewhere.  Thank goodness for a test site and good old repair_settings.php.  I was able to point the test site to my production database and everything was there and working, no blank screens upon posting.  I was also missing avatars among many pages of log file errors.  After getting all the attachments, avatars, etc copied over, I copied my test site back to my production area and I didn't skip a beat.  Still curious about speeding up the background load times, however.

Xaneth

I also figured out how to speed up the load times, so please forgive me if I am reiterating here, but by removing any background color at all under the following section of style.css:

/* The main body of the entire forum. */
body
{
   background-color: white;
   margin: 0px;
   padding: 0px;
}


And turned it into:

/* The main body of the entire forum. */
body
{
   margin: 0px;
   padding: 0px;
}


When one moved around the forum previously, it loaded a white background (in my case black), then loaded the background image I had in my header.php and footer.php, causing a flashing effect and slowing down load times.  After removing it, the flashing went away and the load time improved.  I'm assuming this is the correct method.


Dannii

Removing that wouldn't help load time in any noticeable way.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

Xaneth

#187
At the very least it eliminated the weird flashing issues.

Sh0ck

Ok so I am integrating my site with SMF. What i need to know is how to use the current usergroups and user permissions from the forum and apply them to a admin control panel and specific features on each page. IE admins can edit anything and mods or other groups can only use certain things.  I would help to find out ASAP.

hxxp:nateodesigns.com [nonactive]
We are currently Accepting Applications for the following:

  • Head Programer
  • Programmers
  • Designer
  • Support Staff

To Apply Send a Email with your Name and Qualifications to [email protected]

iraklion

#189
Quote from: [Unknown] on April 10, 2005, 05:47:42 AM
Whatever you'd like!  Here's an example.  Find:

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

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

echo '</td>
</tr></table>';


Replace:

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

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

echo '</td>
</tr></table>';


I didn't even touch the PHP, I just added your HTML.  Of course, this isn't exactly what you suggested, but that's because it's really the same anyway and changes less of the HTML (which makes for a shorter and easier to understand post.)

-[Unknown]


ok/ i did it.
what i want now is to view this included file only on index page.
or
to be splitted in tables only in index page

jayant

I wish to know a very silly question that I wish to add a left margin (including few buttons) with my forum. In which file of the template the alteration have to be made. As in the theme directory there are various files (whether the correction will be at profile or display or index or...... template). My desire is for a look of this type forum.http://img226.imageshack.us/img226/8020/forumhp0.jpg [nofollow] a very simple one. I have only sound knowledge of html and I have the codes of html for my left portion. But, where to add and how to add, I am not getting. Please help.

-Regards

argus1881

Quote from: EliTe_ThuT on October 21, 2006, 02:07:35 PM
I included the forum very well to my website...I have my left menu and banner and all of this... but I have one problem.

In my footer, I have a © somewhere... but it displays as a ♦

Someone know what's the problem...well I know what is the problem...it's the charset...but I tried to change it but it doesn't work...

I had the same problem  >:(
hxxp:www.66mobile.com [nonactive]

Daniel15

QuoteI wish to know a very silly question that I wish to add a left margin (including few buttons) with my forum. In which file of the template the alteration have to be made.
That would need to be a modification to the Index.template.php file. Index.template.php contains the header and footer of each page.
QuoteMy desire is for a look of this type forum.http://img226.imageshack.us/img226/8020/forumhp0.jpg a very simple one.
Unfortunately, Imageshack isn't loading for me (for some strange reason), so I can't see that image.

QuoteI had the same problem  [copyright symbol thing]
Find: ©
Replace with: &copy;
Daniel15, former Customisation team member, resigned due to lack of time. I still love everyone here :D.
Go to smfshop.com for SMFshop support, do NOT email or PM me!

MirditaForum

How can i insert (include) a small chat in my SMF forum?

gupp

Hi, I've been carefully trying to follow these instructions but I'd like to do something a bit different than what I came up with and wondered if someone could help.

I had smfone as my theme but it didn't work as well after the upgrade and I wanted to add the gallery and chat so I decided to just make the default theme green. Everything worked out OK. I'll probably do a few changed but so far I'm good with it.

I did the header and footer php's today. The footer worked out great. Instead of having my header above the forum I'd like to put it in the place where your forum name and smflogo usually default to.   

I've done a small screen shot, I'm adding of what it's doing now and then a modified version of what I want it to look like to help explain better.

I've been writing my html in text for more than 10 years but I don't really know any other code or language. Can I just put the   include('header.php');   in somewhere to make it show up in the logo space?

This is the page:

http://naturalaquariums.com/bb/

Uqqeli

Quote from: [Unknown] on November 09, 2004, 11:36:22 PMSo, creating the layer only means creating two sub templates.  At the end of index.template.php, right before the ?>, add:function template_site_above()
{
global $context, $settings, $options, $scripturl, $txt, $modSettings;

echo '<!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="', $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>
<title>', $context['page_title'], '</title>
<link rel="stylesheet" type="text/css" href="', $settings['theme_url'], '/style.css?rc1" />';

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

include('header.php');
}

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

include('footer.php');

echo '
</body></html>';
}
Would the template_site_above function echo </head><body> only when $context['browser']['needs_size_fix'] is true? I think other browsers would like those tags too... ;)
It's about the powerlessness of being in love and how it devours the insides of a person like a deadly virus. It's a comedy.

mdrcracing

Hi everyone.. As you can tell I'm new here.. I'm fairly good at html.. php I'm still getting into trying to understand it.  I've searched and went though the thread trying to see if I can figure this one out.  This is my 5th bbs software that I'm tryin to get to work the way I want.. so far, its been the best. but anyways.

I followed the header/footer as in post #1.  No probs there.  But now I need to add a right column, but its a remote file, just like the header.php is.  Is there any simple way for me to include right.php?

Either the includes can define its width or I could define its width within the right.php.


also, while I'm here.. I haven't fully looked into it yet, but is there a way I can break the menu up?
ie: here has; forum help search profile my messages calendar members logout
but if I just wanted: forum help search members logout 
is it possible? and is it possible to add a menu item?   I'm attempting to do drop down menu's..
Where I would have:

Your Account
View Profile
Edit Profile
messages
view new post
Show Stats

I also want to make another one "Features" that would include the calander, my gallery script and other related material.


Thanks for any help you can give me.

Daniel15

QuoteWould the template_site_above function echo </head><body> only when $context['browser']['needs_size_fix'] is true? I think other browsers would like those tags too...
It looks like an oversight :P
Not many people do that method though, they aim for the layer system instead (it's a lot more powerful).

QuoteBut now I need to add a right column, but its a remote file, just like the header.php is.  Is there any simple way for me to include right.php?
It depends on where you need to put the code for the column. If it goes above the actual content (as it would if you're using CSS to align it), you can use another include statement to include it (either below the header, or inside the header.php file, depending on where the code needs to go). If the code goes below the actual content (as it would if you're using tables for layout), then you can use another include statement above the footer
Reading over my post again, it doesn't make much sense :P. Please feel free to ask if you have any further questions ;)

Quotealso, while I'm here.. I haven't fully looked into it yet, but is there a way I can break the menu up?
ie: here has; forum help search profile my messages calendar members logout
but if I just wanted: forum help search members logout 
is it possible? and is it possible to add a menu item?   I'm attempting to do drop down menu's..
Sure, look in index.template.php (search for template_menu). This contains all the buttons. If you're using the default SMF 1.1 theme, there's information on how to add a new button at http://docs.simplemachines.org/index.php?topic=564
Daniel15, former Customisation team member, resigned due to lack of time. I still love everyone here :D.
Go to smfshop.com for SMFshop support, do NOT email or PM me!

mdrcracing

alright, I still need help.. Working with Daniel tonight, we still can't figure out what I'm doing wrong.


echo'
<div style="float: right; width= 225px">';
include('../right.php');
echo'
</div>';


This is what I have to load the "right.php" file.  It loads the file, but loads it to the left, which I can fix, but it doesn't float it to the right.  I have the code inbetween my header and the welcome header.

if you look at my page you'll understand what I mean more.. I'm working on a new welcome header for my layout, but I still have the current one on there as well, since this is my way of undering how the code works.  but I have the right inbetween the 2.  What its not doing is shifting the 2nd welcome header and the forum to the left, its just putting them inline with each other.. 

http://www.mdrcracing.com/smf/index.php [nofollow]

there where I have everything installed..
Please help..thanks.

mdrcracing

Sorry for the doouble post.

I ended up making a table, putting the forum in 1 column and the remote file in the other.

But I have another question.  I closed the table right before the body tag.  I'd like to close the table right before the info center.  But in the index.template file I can't figure out where it is.  I just want my right column to cover the board. and have the info center full width..  can anyone tell me where I can find it?

and just to save time, if its another file, would I just copy it from the default theme, edit what I need to and copy it over to my theme and it would show?  I'm sorry for all the questions.

Advertisement: