Search Results for 'code'
-
AuthorSearch Results
-
December 18, 2008 at 1:10 am #70435
In reply to: Entries coming up with no content
Ipstenu (Mika Epstein)
ModeratorSomething is telling it that there are no posts (thus
<?php if ($posts) : ?>never calls the rest of it). But at this point you’ve tapped out my poor brain
December 17, 2008 at 10:00 pm #70434In reply to: Entries coming up with no content
flashpunk
MemberI dont think i have anything major integrated into the site, its not calling wordpress tags thats for sure, all those links pointing to the wordpress template files are hard coded.
Can you think of anything specific i should look at? anything else that will help?
December 17, 2008 at 9:39 pm #70432In reply to: Entries coming up with no content
flashpunk
MemberThats what I dont get, I have the loop in there.
Yes, i attempted the deep integration but it doesn’t seem to have worked, i’ve given up.
This is what the topic.php template looks like, fron that topic_tags() downward.
<!-- <?php topic_tags(); ?> -->
<div style="clear:both;"></div>
</div>
<?php do_action('under_title'); ?>
<?php if ($posts) : ?>
<div class="nav">
<?php topic_pages(); ?>
</div>
<div id="ajax-response"></div>
<ol id="thread" class="list:post">
<?php foreach ($posts as $bb_post) : $del_class = post_del_class(); ?>
<li id="post-<?php post_id(); ?>"<?php alt_class('post', $del_class); ?>>
<?php bb_post_template(); ?>
</li>
<?php endforeach; ?>
</ol>
<div class="clearit"><br style=" clear: both;" /></div>
<p class="rss-link"><a href="<?php topic_rss_link(); ?>" class="rss-link"><?php _e('<abbr title="Really Simple Syndication">RSS</abbr> feed for this topic') ?></a>
<div class="nav">
<?php topic_pages(); ?>
</div>
<?php endif; ?>
<?php if ( topic_is_open( $bb_post->topic_id ) ) : ?>
<?php post_form(); ?>
<?php else : ?>
<h2><?php _e('Topic Closed') ?></h2>
<?php _e('This topic has been closed to new replies.') ?>
<?php endif; ?>
<?php if ( bb_current_user_can( 'delete_topic', get_topic_id() ) || bb_current_user_can( 'close_topic', get_topic_id() ) || bb_current_user_can( 'stick_topic', get_topic_id() ) || bb_current_user_can( 'move_topic', get_topic_id() ) ) : ?>
<div class="admin">
<?php bb_topic_admin(); ?>
</div>
<?php endif; ?>
<?php bb_get_footer(); ?>December 17, 2008 at 9:25 pm #70431In reply to: Entries coming up with no content
Ipstenu (Mika Epstein)
ModeratorIt looks like the ‘loop’ for your posts is missing.
In your source, you mention
http://www.theacerguy.com/forum/bb-templates/theAcerGuyForum/forumStyle.csswhich doesn’t exist, and really should be in my-templatesIt’s really like your topic.php is missing all the stuff from
<?php do_action('under_title'); ?>down to the if open then reply_ok.Do you have deep integration going on? You seem to be pulling WP header stuff down.
December 17, 2008 at 8:43 pm #70428In reply to: Entries coming up with no content
flashpunk
MemberNegative – changing the theme to the default theme doesn’t fix it
December 17, 2008 at 8:40 pm #70379In reply to: Looking for alternatives
vadi
MemberYeah, I guess posting my req’s would’ve been a good start.
The forums need to accommodate a community. The community is for a open-source program – so the forums have an ideas, support, general talk, scripting (it can be done in the program by advanced users), and an offtopic section (means embedded images and whatnot).
Avatars, PM’s, a featureful button toolbar, support for code pastes (so no forum breaking, highlighting), post attachments, email post notifications, and support for embedded images is what’s missing for me currently. Oh, and a search bar…
December 17, 2008 at 8:25 pm #70142In reply to: bbPress 1.0-alpha-4 released
johnnydoe
Memberi hope a working “preview post” feature is an integral part of 1.0
December 17, 2008 at 8:08 pm #70424In reply to: change text.
chrishajer
ParticipantIn the front-page.php file in your template folder, you can do this:
Change:
<th><?php _e('Topic'); ?> — <?php new_topic(); ?></th>to:
<th><?php _e('Topic'); ?> — <?php new_topic('Add New ---->'); ?></th>Where Add New —-> is what you want displayed instead of the default.
December 17, 2008 at 8:01 pm #70422In reply to: change text.
johnnydoe
Memberit’s the Topic – Add New » on front-page.php
<th align="left"><?php _e('Topic'); ?> <?php new_topic(); ?></th>thats why i thought there is a language file or such around, because the phrases here are actually php tags.
December 17, 2008 at 7:47 pm #70420In reply to: change text.
johnnydoe
Memberwell actually i want to change things like “» ” or the “|” in the footer (Welcome, admin | Admin | Log Out ) .
so sorry for the confusion so far
December 17, 2008 at 6:39 pm #70264In reply to: 1.0-Alpha-4, and the AJAX styles
Ipstenu (Mika Epstein)
ModeratorNo, it’s right. Mine does that too. They’re supposed to ‘hide’ when they’re deleted, and then you’ll see something like this :
TOPIC NAME (26 posts +2 more)
And if you click on 2 more you get the two missing posts in red and a
?view=allat the end of your URL.December 17, 2008 at 6:26 pm #69950In reply to: bbpress is slow like godaddy says?
_ck_
ParticipantMost hosts will not admit and definitely not advertise NFS, it’s a downside, not a plus.
But you can tell if you have an account with them by studying
df -athough the shell, php shell or perl cgi shell. Or if they hide/block all that you can write a script to time 1000 reads of filemtime (with clearstatcache) which cannot be cached by the OS and will have telltail lag.Marketing-wise NFS is usually spun as “unlimited” or “expanding” storage space, like Dreamhost promises extra space each month.
I’m very curious to find out what the “resolution” was.
The latest page show shows 1.432 – 36 queries which is still poor.
December 17, 2008 at 6:22 pm #70263In reply to: 1.0-Alpha-4, and the AJAX styles
stevedrum
Memberoh right, well that’s even weirder… because my deleted posts gets deleted. they disappear. they don’t stick around in a new colour.
but… i’ve just had a look at the source code after i deleted something and you are right, they are still there. and a new style has been added to the
- tag which says
style=”background-color: rgb(255, 51, 51); display: none;”
is that display:none bit an error? because that is what is making it disappear.
and also — i’ve just noticed that i get the ‘undelete’ link appear on every single post. even if it hasn’t been deleted. and it’s got a very strange class on it. it says
class=’dim:thread:post-85:deleted:FF3333:FFFF33:action=delete-post&status=0 undelete-post’
December 17, 2008 at 5:16 pm #68749In reply to: How to move a forum?
Ipstenu (Mika Epstein)
Moderator@staats – If you have access to your SQL database (like through phpMyAdmin), it’s much the same as moving any databased app, like WordPress

The first set of directions I put in the post above are mostly right. I’ve updated them here since there’s a couple things that should be explained differently than my copy replace from WordPress’s directions (why reinvent the wheel?). If you’ve got WP and BB integrated you’ll have to make all the changes to the files (wp-config and bb-config AND the admin settings changes) BEFORE you backup your database.
First, backup your database – https://codex.wordpress.org/Backing_Up_Your_Database (obviously the bb database, not the wp one for your case) No matter WHAT you want this copy! If you screw everything up (and we’ve all done that) you need a fall back plan.
- Download a copy of the main bbpress files from your OLD forum to your hard drive and edit b-config.php to suit the new server.
- Go back to your OLD forum and go to settings and change the bbPress address (URL) to that of your new site. (You may want to change your email addy here, but you don’t have to just yet).
- IF you’ve integrated bbPress and WordPress, go to your WordPress Integration page and change any domain information there that has changed.
- Download your database (but keep the old backup just in case), upload this new database and the copy of the forum files with the edited bb-config.php to your new server.
Again, if WordPress and bbPress are integrated and sharing a database, do steps 1-3 for bbpress, and then steps 1 and 2 here, and THEN do the last DB download step just once.
And if it’s all confusing … yeah, it’s a lot of fruit to be juggling at once.
December 17, 2008 at 4:54 pm #70378In reply to: Looking for alternatives
Ipstenu (Mika Epstein)
ModeratorI guess it depends on what you want a forum to do.
Make a list of what you need, being firm with yourself to separate your WANTS from your NEEDS. For example, for me a PM system is nice, but it’s not a deal breaker for me. Whereas sharing IDs and Passwords (and cookies) with WP is a must have. Include things like ‘cost’ and support. Do you want to be able to call up the company, or is a support forum okay.
Then check out a place like http://www.forummatrix.org/ to compare some of them. Like a quick check comparing SMF, bbPress and Vanilla may help you out (see my results).
bbPress is a young product, it’s not even ‘live’ yet, and having been there as a user for SMF back when it was YABB and then YABBSE and THEN when it moved on to SMF (not to mention IPB, the big bad daddy of fat forum software) … well, I’ve tried a lot of forums. They all start out about this level and some improve and some don’t. It’s hard to tell at this stage, but bbPress feels like it’s headed the right way to me
I do understand why it’s not right for everyone, though!
December 17, 2008 at 4:28 pm #70376ganzua
MemberI’m aware of that
but sooner or later, template things should be placed in the templates folder, I don’t know, perhaps a new functions.php in all templates. BTW John, do you know where can I find some info in custom loops? I’d like to build a loop like this one that I described here; https://bbpress.org/forums/topic/separating-the-first-post-of-each-topic
December 17, 2008 at 4:04 pm #4456ganzua
MemberThis is just a suggestion;

I noticed that there is a lot of stuff in functions.bb-template.php file that should be moved to templates. There are h2 tags in post_form function plus a lot of words that need translation in localization cases.
Besides, I can’t find information on building custom loops. Is there any literature available?
December 17, 2008 at 2:38 pm #70369In reply to: Cookies in WP and BBpress only works on logout
Ipstenu (Mika Epstein)
ModeratorIn bb-config.php
define('BB_AUTH_KEY', 'WP's AUTH KEY halmstad');
define('BB_SECURE_KEY', 'WP's SECURE KEY halmstad');
define('BB_LOGGED_IN_KEY', 'WP's LOGGED IN KEY halmstad');Also make sure you have the salts:
define('BB_AUTH_SALT', 'WP's AUTH SALT');
define('BB_LOGGED_IN_SALT', 'WP's LOGGED IN SALT');And that you have these defined:
$bb->secure_auth_cookie = 'wordpress_sec_456c71223b3bb9958349ec3d65b850f6';
$bb->logged_in_cookie = 'wordpress_logged_in_456c71223b3bb9958349ec3d65b850f6';Personally, I set my cookie domain to .domain.se for both WP and BB.
December 17, 2008 at 8:50 am #70071In reply to: PLEASE Create 2 Versions of bbpress!
John James Jacoby
KeymasterFirstly, while there’s two ways to skin a cat, david’s method kills the kitty in the process. My advice is not to do it that way. If you need to get the absolute path of a directory I made a quick file to do it…
Put this code in a php file, I named mine “abs.php”
<?php
$p = getcwd();
echo $p;
?>Then upload that file to the directory you want to find the path to, and visit it in a web browser. It will echo the absolute path for you. Copy the output. Delete the file. Done!
Duplicating the themes is really the best way to do this, and I promise that once you’ve included WordPress into bbPress properly, it’s a really straightforward and rewarding process.
Firstly, download Notepad++. It’s free, and it rules.
Firstly.5, make copies of your WordPress header.php/footer.php files, and save them someplace safe. We will be modifying these files and don’t want to ruin the actual working WordPress ones.
Secondly, open the header.php/footer.php files for both the stock bbPress theme, and the copied ones I just mentioned. In Notepad++ you should now have 4 files open.
We’re basically working from the outside in.
Thirdly, take all of the relevant bbPress PHP code from it’s header.php/footer.php files, and start copy and pasting them to the equivalent places in the WP copy header.php/footer.php files. Like in mine, I actually have:
<?php
bb_feed_head();
wp_get_archives('type=monthly&format=link');
wp_head();
bb_head();
?>Which loads all of the WP and BBP head related functions inside my BBP forums. Because I want links to my feeds and what-not…
Fourthly, once you’re done with this, then you start poking around the other BBP theme files, and modify all of those files to work within the same construct as your WP theme does, with the same DIV classes and names and what-not.
Because we’ve included the WordPress functions inside bbPress, and because we’re using the same original WP theme header.php file, all of the same style-sheets and JS from that theme are already coded and loaded, even though you’re looking at bbPress. The rest is just tweaking all of the files to look how you want them to.
This is the process I used at http://www.delsolownersclub.com, and I think it’s worked really super well.
December 17, 2008 at 4:53 am #69946In reply to: bbpress is slow like godaddy says?
vannak
Membermy site is getting slower and having more error after raising this topic. ok i need to stop posting now and do a backup fast in case i’ll lose everything
December 17, 2008 at 4:36 am #70069In reply to: PLEASE Create 2 Versions of bbpress!
lolos
MemberFirst of all, thank you so much, especially David and Sam. I really appreciate your help and input.
David, I followed your steps and I think your explanation is very straight forward and detailed. However, it gives me this error:
“Warning: main(/wp-load.php) [function.main]: failed to open stream: No such file or directory in /…/…/…/…/…/www/root folder/forum/bb-config.php on line 4.
Warning: main(/wp-blog-header.php) [function.main]: failed to open stream: No such file or directory in /…/…/…/…/…/www/root folder/forum/bb-config.php on line 7.”
It gave me the error above no matter how I write down the “full path:”
if ( !defined( 'ABSPATH' ) ) {
include_once( '/Full/Path/To/wp-load.php' );
}
require_once('/Full/Path/To/wp-blog-header.php');I translated the /Full/Path/To/wp-load.php –> /wp-load.php and /www/root folder/wp-load.php
December 17, 2008 at 4:25 am #70000In reply to: Windows (Apache2/PHP/5.2.6/MySQL5.1.30)
Sam Bauers
ParticipantOK, so should we manually set “sendmail_from”…
ini_set( 'sendmail_from', 'me@example.com' );Which only affects Windows servers anyway I believe.
December 17, 2008 at 3:11 am #70067In reply to: PLEASE Create 2 Versions of bbpress!
davidbaldwin
Memberlolos,
first of all, if you are doing this with WordPress 2.6 or newer, you have to run 1.0-alpha. If you are running an older version of wordpress you can use the stable version. I attempted to roll back to an older version of wordpress, but i was unsuccessful, so this method is for 1.0-alpha users.
I found the intigration information at:
https://bbpress.org/documentation/integration-with-wordpress/
https://bbpress.org/forums/topic/first-pass-at-a-fix-for-deep-integration-in-trunk#post-21572
you need to add the following to the bb-config.php file, after <?php
if ( !defined( 'ABSPATH' ) ) {
include_once( '/Full/Path/To/wp-load.php' );
}
require_once('/Full/Path/To/wp-blog-header.php');the full paths have to be absolute paths on the servers, not the domain paths.
this will load wordpress when bbpress is loaded.
and then you need to add this line to the very top of every page that has this line: <?php bb_get_header(); ?>
<?php get_header(); ?>please note that the line above has to be line #1 in every page that already calls the bb header, if it does not call the bb header, do not add this, the final result should look like this:
<?php get_header(); ?>
<?php bb_get_header(); ?>this will load the wordpress header when the bbpress header is called. you can edit the bbpress header to remove all the unnecessary code. (like the title, etc.)
and then you need to add this line to the very bottom of every page that has this line: <?php bb_get_footer(); ?>
<?php get_footer(); ?>please note that the line above has to be the last line in every page that already calls the bb footer, if it does not call the bb footer, do not add this, the final result should look like this:
<?php bb_get_footer(); ?>
<?php get_footer(); ?>this will load the wordpress footer when the bbpress footer is called. you can edit the bbpress footer to remove all the unnecessary code. (like the title, etc.)
I hope this helps. if you have any questions, please feel free to ask!
david
December 17, 2008 at 2:12 am #70131In reply to: bbPress 1.0-alpha-4 released
Ipstenu (Mika Epstein)
Moderatortomwi – Two easy options.
1) Use the build in RSS sidebar widget in wordpress.
2) Add the PHP Widget plugin and then toss in something like this:
<?php require_once (ABSPATH . WPINC . '/rss-functions.php');
$today = current_time('mysql', 1);
// insert the feed URL here
$rss = @fetch_rss('http://domain.net/forums/rss');
if ( isset($rss->items) && 0 != count($rss->items) ) {
echo '<ul>';
// set the number of items from the feed to display (5)
$rss->items = array_slice($rss->items, 0, 5);
foreach ($rss->items as $item ) {
echo '<li><a href="';
echo wp_filter_kses($item['link']);
echo '">';
echo wp_specialchars($item['title']);
echo '</a></li>';
}
echo '</ul>';
}; ?>December 17, 2008 at 1:10 am #69943In reply to: bbpress is slow like godaddy says?
vannak
Memberhi _ck_ i did add this ‘$bb->load_options = true;’ into bb-config.php but i wonder that there is no functions.php in my template folder. it is strange isn’t it? anyway, thank for your help so far. maybe hostmonster is a better choice.
-
AuthorSearch Results