Skip to:
Content
Pages
Categories
Search
Top
Bottom

How Do I Do This?

  • Hi,

    I want to make a forum or forums like this:

    Chicago Forum

      General Discussion

      Jobs

      For Sale

      Housing

      Another Topic

      Another Topic

      Another Topic

      Another Topic

    New York Forum

      General Discussion

      Jobs

      For Sale

      Housing

      Another Topic

      Another Topic

      Another Topic

      Another Topic

    And do this for five or six cities.

    How would I do this? I fear the thing will be too big and complicated.

    If the answer has to do with multiple forum installations, what’s involved with that? And, I would like users to be able to post in any city without having to log in again and again.

    Oh, I should mention that I’m just now learning code ect. I’m at the point where I can tinker with a file if I’m told exactly how to do it.

    Any suggestions?

Viewing 25 replies - 26 through 50 (of 64 total)
  • Why don’t you just backup current front-page.php and replace with new code, then see what you will get?

    I did…but if I click edit on the individual cities I see that the “positions” for each are different than the id’s I entered in the new code.

    Maybe I should go back and enter those numbers instead.

    Oh… you are still there…

    position isn’t the id. When your mouse move over the Edit link, check the status bar of your browser. The id is there.

    I got all the id’s and entered them into the line in the code…mine where 2, 3, 4, 5, 6, 7, 18, 19, 20, 101

    then I uploaded the new frontpage.

    Everything looks the same. So now I’m wondering how I use this. I mean, when I try to create a link from the main site to the “Chicago Forum” what do I put in the link box? http://theangrywaiter.com/forum takes me to the forum page, but nothing I do seems to take me directly to the Chicago Forum.

    I must be doing something wrong

    Please post entire front-page.php.

    <?php bb_get_header(); ?>

    <?php if ( $forums ) : ?>

    <div id="hottags">
    <h2><?php _e('Hot Tags'); ?></h2>
    <p class="frontpageheatmap"><?php bb_tag_heat_map(); ?></p>
    </div>

    <div id="discussions">
    <?php if ( 0 > 1 ) : ?>

    <h2><?php _e('Latest Discussions'); ?></h2>

    <table id="latest">
    <tr>
    <th><?php _e('Topic'); ?> — <?php new_topic(); ?></th>
    <th><?php _e('Posts'); ?></th>
    <th><?php _e('Last Poster'); ?></th>
    <th><?php _e('Freshness'); ?></th>
    </tr>

    <?php if ( $super_stickies ) : foreach ( $super_stickies as $topic ) : ?>
    <tr<?php topic_class(); ?>>
    <td><?php _e('Sticky:'); ?> <big><a href="<?php topic_link(); ?>"><?php topic_title(); ?></a></big></td>
    <td class="num"><?php topic_posts(); ?></td>
    <td class="num"><?php topic_last_poster(); ?></td>
    <td class="num"><small><?php topic_time(); ?></small></td>
    </tr>
    <?php endforeach; endif; // $super_stickies ?>

    <?php if ( $topics ) : foreach ( $topics as $topic ) : ?>
    <tr<?php topic_class(); ?>>
    <td><a href="<?php topic_link(); ?>"><?php topic_title(); ?></a></td>
    <td class="num"><?php topic_posts(); ?></td>
    <td class="num"><?php topic_last_poster(); ?></td>
    <td class="num"><small><?php topic_time(); ?></small></td>
    </tr>
    <?php endforeach; endif; // $topics ?>
    </table>
    <?php endif; // $topics or $super_stickies ?>

    <?php
    if ( bb_forums() ) :
    global $bb_forums_loop;
    $_loop =& $bb_forums_loop;
    bb_forum();
    $skipForum = false;
    while ($_loop) :
    if ($_loop->walker->depth == 1) {
    if (in_array(get_forum_id(), array(2, 3, 4, 5, 6, 7, 18, 19, 20, 101)))
    $skipForum = true;
    if ($skipForum) {
    ?>
    <h2<?php bb_forum_class?>><a href="<?php forum_link(); ?>">Click Here To Go To the <?php forum_name(); ?> Forums</a></h2>
    <?php
    }
    else {
    ?>
    <h2<?php bb_forum_class?>><?php forum_name(); ?></h2>
    <table id="forumlist">
    <tr>
    <th><?php _e('Main Theme'); ?></th>
    <th><?php _e('Topics'); ?></th>
    <th><?php _e('Posts'); ?></th>
    </tr>
    <?php
    }
    }
    elseif (!$skipForum) {
    ?>
    <tr<?php bb_forum_class(); ?>>
    <td><?php bb_forum_pad( '<div class="nest">' ); ?><a href="<?php forum_link(); ?>"><?php forum_name(); ?></a><small><?php forum_description(); ?></small><?php bb_forum_pad( '</div>' ); ?></td>
    <td class="num"><?php forum_topics(); ?></td>
    <td class="num"><?php forum_posts(); ?></td>
    </tr>
    <?php
    }
    bb_forum();
    if ($_loop === null || $_loop->walker->depth == 1) {
    if (!$skipForum)
    echo '</table>';
    $skipForum = false;
    }
    endwhile; ?>
    <?php endif; // bb_forums() ?>

    <?php if ( bb_is_user_logged_in() ) : ?>
    <div id="viewdiv">
    <h2><?php _e('Views'); ?></h2>
    <ul id="views">
    <?php foreach ( bb_get_views() as $view => $title ) : ?>
    <li class="view"><a href="<?php view_link(); ?>"><?php view_name(); ?></a></li>
    <?php endforeach; ?>
    </ul>
    </div>
    <?php endif; // bb_is_user_logged_in() ?>

    </div>

    <?php else : // $forums ?>

    <h3 class="bbcrumb"><a href="<?php bb_option('uri'); ?>"><?php bb_option('name'); ?></a></h3>

    <?php post_form(); endif; // $forums ?>

    <?php bb_get_footer(); ?>

    Thats works on my server. Are you sure you edited right front-page.php? Do you have more than one template?

    You were right…I’m an idiot and uploaded my backup front page.

    It works now, but it’s not exactly what I was trying to do.

    I was trying to do something like that on my main WP site. You know, build a “Page” with those links on it. But, I might leave it as is…if I do, however, can I take out the “New Topic In This Forum” underneath all of the sub-forums?

    I don’t want people posting things outside the individual sub-forums.

    BTW, thanks for all of your help. I never could have made this thing work without you and Chris

    Comment out third line from bottom in forum.php like

    <?php // post_form(); ?>

    Oh, BTW, what just to make sure I explained it clearly…

    On my main WP site, in my navigation bar, I was going to have Page called forums. If someone clicked on that “Forum” Page button they would see a list of cities. I just thought it would be easier for them to be transported directly to their city of choice rather than having to scroll down the page once reaching the bbpress forums.


    chrishajer
    Participant

    @chrishajer

    Just grab the links to the individual forum pages then, and insert them into a WordPress page. You’ll have to maintain it manually, so if you add a new city you would need to add a new link to that WordPress page. I imagine there is probably a way with integration to use the bbPress functions in a WordPress page but I think that’s more work than it’s worth, especially if your list of cities is pretty much set.

    Your WordPress page would be titled “Forum” then, and in that page would be the links to the individual forums. Then you might not even need front-page.php since you’d be navigating directly to the parent forums for each city. I think you would probably leave it there so if anyone navigated in the breadcrumbs to the next level ‘up’ they would still get a list of all cities, either links to the parents, or the way you had it set up initially with the long front page.

    Ok, so I now know how to link the individual cities. I can use Livibetter’s new code and do it from the front page of the forum or I can do it from the Forum Page on our main site. Thanks to both of you…I’m really learning a lot!

    So, now I’ve added the logo with a “Click Here” statement to direct people back to the main site. As you can see http://www.theangrywaiter.com/forum

    it sits on top of the title.

    I was thinking maybe I could move the title up higher and center it.

    Don’t know how to do this.

    Then I could make the logo and “Click Here” words clickable to the main site. (The main site and forum are not integrated if that makes a difference. They both reside in their own sub-directories.)

    Don’t know how to do this either.

    I have to go out for a while, but I’ll be back around 11:00 Chicago time.

    Talk to you later.


    chrishajer
    Participant

    @chrishajer

    Integration doesn’t matter at all if you’re just linking one to the other, they’re just simple html links. You can link anything to anywhere, no integration required.

    Not sure what you mean about “on top of” – the new logo is a background image over to the bottom/right of the header div. The problem with making it a background image, rather than just an image in your code, is that to make it clickable back to the main site, you’d have to make the whole header a link back to the main site. If you look at the source for the page, you’ll see there is no img tag for awforumlogo2.jpg that you can wrap in an <a href=" tag to link back to the main site. I don’t think you want that image as a background image for the header if you’re going to make a link out of it.

    I would remove the background image from your style.css and put the img tag in header.php somewhere in the <div id="header"> section (around line 34 in a stock installation).

    Once you have an image in header.php, you can work on positioning it where you want it and linking it to what you want as well. Then you can figure out where you want your forum title as well.

    I was able to move the forum Title up and to the center just by adding some padding. I think it looks good there.

    I removed the logo from the background in the style sheet.

    Now, I’ve been trying to add the image to the header.php, but I don’t know how to do it.


    chrishajer
    Participant

    @chrishajer

    In header.php, in the header div (where the login_form() is) put this:

    <img id=”headerlogo” src=”http://www.theangrywaiter.com/wordpress/wp-content/uploads/awbanner.jpg&#8221; alt=”The Angry Waiter” />

    Right now though, the image is taller than the header div (the header is 106px, the image is 131px, I think.)

    So, to make it all work, you’ll need to make the header div taller, or the image less tall. Then you’ll need to apply some styling to the image you just placed in the header. Something like this:

    #header img {
    whatever: here;
    }

    That just gets the image into the header. Then you need to wrap an <a href="http://www.theangrywaiter.com/" alt="go home"></a> around that image tag you just added, to link the image to the destination.

    OK…I have it positioned and clickable, but somehow I’ve made the entire banner clickable and added a border.

    To position the logo/Click here I added a left-padding in the style sheet.

    I also had to add change the header php from src= to img src= to get the logo to display after I added href.

    The whole header is clickable now…could this be because I positioned it with padding?

    so now I changed style sheet put floated the image right and it’s postioned fine, but there’s a bortder around it.

    I think I should replace that image with a smaller one

    Edit: Ok, I think it’s related to what you said before about the image being too large. I kind of blew that off because I was using a different image. The new one is 280×100. I think what I’m going to do is make a smaller image, upload that and change the header.php ing src.

    Then, try to hide the border.


    chrishajer
    Participant

    @chrishajer

    This needs to be removed. It’s right after the header div in header.php

    <img id="headerlogo"

    That is doing you no good. Actually, my message was a combination of a couple messages. Initially I was going to say give the image an id so you could position it, then I said to just style it with #header img – in any case, you need to remove the above since it’s not valid and is causing weird things.

    And you must be working on it since there is no border.

    Yes! It works!

    I was having trouble in IE (it worked fine in Firefox). Now, after removing img id, it works in both.

    Thanks.

    I think, though, I might make a slightly smaller logo/click here so it fits better into the header.

    47 posts later and I think I’m done!

    Check it out and let me know what you think


    chrishajer
    Participant

    @chrishajer

    Only 47 posts? Piece of cake.

    I did notice, in Firefox 2.0.0.10 the logo is not entirely clickable. Certain parts of it are, if you hit it just right, but not the whole thing. Odd. In IE7, it’s all clickable.

    Oh, and I probably told you this incorrectly as well (although not intentionally.) The <a href should have a <strong>title attribute, not an alt attribute. The <img should have an alt. So

    <a href="http://www.theangrywaiter.com/" title="go home"> and

    <img src="http://www.theangrywaiter.com/forum/bb-templates/awbbtheme/images/awforumlogo3.jpg" alt="the angry waiter logo" />

    Sorry about that.

    And, to keep your page valid XHTML, you’re going to have to give each forumlist a different ID by appending the name or number of the forum to it. So it would be

    <table id="forumlist-chicago">

    and <table id="forumlist-atlanta">

    or <table id="forumlist-4">

    and<table id="forumlist-11">

    I changed the title to alt=

    As far as the table ids…are you talking about the code I got from Livibetter?

    And about anchoring each forum?

    After all that work (by you guys, not so much me) I took that out and decided to just let people scroll down the page. I just think the page looks better and I kind of like that they can see all the other cities.

    I know, I’m a pain in the ass.

    So, on the front-page.php and the forum.php I see nothing like that anymore, but if I right-click page source when at the actual forums page I see what you mean.

    Edit: I see what you mean too when I run it through a valadator


    chrishajer
    Participant

    @chrishajer

    table ids, yes, the code from livibetter would need a tiny modification to create unique ids for each table. :)

    And for the anchoring, do you mean something like a list up top on the page, then each of those link further down the page to a named anchor? Like this?

    http://www.vestacompanies.com/properties/

    (click a for sale or for rent category and it just scrolls down the page a little bit to the proper table)

    Yes, remember I was going to try to have a list of the cities so people could just click on say “Miami” and then be taken directly to the “Miami” part of the page? Well, livibetter’s code created a list of all the cities and took them directly to the sub-forum for each city. If I create a link on the main WP Page for the Chicago board using an address like http://theangrywaiter.com/forum/forum.php?id=2

    it also takes them directly to the sub-forum. I didn’t really like that, so I figure I’ll just offer one link from the main WP site to the forums and let the visitor scroll past the other cities until they find their’s.

    It might actually be better because then they can see the other cities and more easily go and read posts in those cities as well as in their own city.

    Oh, and if they go to a sub-forum they can enter a post outside of the child forums. I tried to comment that comment form out, but it took them out of all the forums as well. So, now I think it was all a waist of time, but at least I learned something.

Viewing 25 replies - 26 through 50 (of 64 total)
  • You must be logged in to reply to this topic.
Skip to toolbar