Search Results for 'test'
-
Search Results
-
Trying to locate the file that has the routine that does msql_connect or _pconnect…
Today I did the reverse integration of an existing WordPress blog (2.7.1) and BBPress forum (0.9.4). I described my plans here. With some help from bobbyh and a lot of digging into these forums, things worked out well.
Here are the steps (all but the final 2 are database operations, which I did using phpMyAdmin):
- I didn’t need to do backups because I was using a test site, but if you are trying this, don’t go any further without full backups of everything.
- Copied the “bb_users” and “bb_usermeta” tables from the BBPress database to the WordPress database. I was a bit worried that the row sizes weren’t exactly the same in the destination copy, but as it turns out, that wasn’t an issue.
- Added a “user_activation_key” field to the copy of “bb_users” to ensure that the schema matched my current “wp-users” table in the WordPress database.
- Renamed the “wp_users” and “wp_usermeta” tables to “wp_users_old” and “wp_usermeta_old” respectively.
- Renamed the new “bb_users” and “bb_usermeta” tables to “wp_users” and “wp_usermeta” respectively.
- Added WordPress admin rights and metadata to the new admin user. To do this I ran the following query:
INSERT INTO wp_usermeta (user_id, meta_key, meta_value) VALUES (‘1’, ‘wp_capabilities’, ‘a:1:{s:13:”administrator”;b:1;}’);
- Added WordPress user metadata for the rest of the users (since I’m using the BBPress user tables as the starting point they know nothing about WP capabilities). Here is the query:
INSERT INTO wp_usermeta (user_id, meta_key, meta_value) SELECT user_id, ‘wp_capabilities’ AS meta_key, ‘a:1:{s:10:”subscriber”;b:1;}’ AS meta_value from wp_usermeta WHERE user_id NOT IN (SELECT user_id from wp_usermeta WHERE meta_key = ‘wp_capabilities’) GROUP BY user_id;
- Changed the user_id references in the “wp_posts” and “wp_comments” tables so that they pointed to the correct users (you need to do this because equivalent users don’t necessarily have the same ID in the previously separate WordPress and BBPress databases). Here are the queries I ran:
UPDATE wp_posts SET post_author=NEW_ID WHERE post_author = OLD_ID
UPDATE wp_comments SET user_id=NEW_ID WHERE user_id = OLD_ID
NOTE that you need to think carefully about the order in which you do these changes. You don’t want to change a user’s ID to one that already exists in the WordPress table.
- Installed superann’s plugin to downgrade WP 2.7.1’s cookie handling for compatibility with BBP 0.9.4: http://superann.com/2009/02/26/wordpress-26-27-bbpress-09-cookie-integration-plugin/
- Told BBPress to find its user data in the new WordPress user tables. This is done in the BBPress admin page for WordPress integration: […]/bb-admin/options-wordpress.php. You need to follow the instructions carefully. In particular, note that the WordPress database secret should be copied from the current WordPress setting and not vice versa.
Some other notes:
- This is not something to do in a rush. I checked the results of each step carefully before moving on. This included browsing the database and, later in the process, logging in to the blog and forum to check whether things were working as expected.
- This worked for me. Your mileage may vary.
I’m trying to come up with a way to show additional information on the lastest discussions on the front page. I want to show the topic author’s avatar, name, title, the date it was first posted, and the forum it is in. I found some author functions in the post.php, but I think I need to make them within a post loop calling only the firs post. I haven’t figured out how to do that or how the topics.php is doing it.
Here is what I’ve tried so far:
‘<?php foreach ($posts as $bb_post) : $del_class = post_del_class(); ?></p>
- <?php post_author_avatar(); ?>
- <?php post_author_link(); ?>
- <?php post_author_title(); ?>
- <?php printf( __(‘Posted %s ago’), bb_get_post_time() ); ?>
<p> <?php endforeach; ?>
`
Hello!
I use 2.6.3 version of WP and I just installed bbPress 0.9.
I also use Freshly Baked Cookies plugin (http://bbpress.org/plugins/topic/freshly-baked-cookies/) to allow bbPress using WP cookies.
What I get now is a strange situation: when I log into WP then I become logged out from bbPress and when I log into bbPress then I become logged out from WP, so I can never be logged in both of them. Everything else work fine.
My WP works on http://www.subdomain.domain.com/ address and bbPress works on http://www.subdomain.domain.com/bbpress/ address. I have fulfilled all the integration instructions.
What is also strange that when I log in WP then get these cookies:
– wordpress_logged_in_[HASH 1]: admin%7C[HASH 2]
– wordpress_test_cookie: WP+Cookie+check
– wpfsession: [10 digits number]
– wp-admin wordpress_[HASH 1]: admin%7C[HASH 3]
– wp-content/plugins wordpress_[HASH 1]: admin%7C[HASH 3]
…and when I log in bbPress then I get similar but [HASH 2] is the same as [HASH 3].
What am I doing wrong?
Thank you in advance!
Topic: Problem with Smileys
Topic: New users wont get mail!
New users wont get mail!
Plugins installed:
– Memberlist
– BBcode Lite
– Avatar Upload
– Human Test for bbPress
– bb-emoticons
– Post Count Plus – Dynamic.Titles & More!
– Hidden Forums
– Members Online
– Move It
– Allow Images
– BBVideo
– Admin Can Post Anything
– Hidden Forums Tag Filter
– Mini Stats
– Topic Icons
Anyone?
Need to change number of recent updated posts in Latest Discussions. Where can I change that number in the code or settings?
Thanks.
