https://www.icyphoenix.com/viewtopic.php?f=35&t=3960 ----------------------------------- tibi2007 Sat 29 Mar, 2008 14:45 Blog Mod ----------------------------------- is there any blog mod that works with icy phoenix? i found wp united that integrates withs phpbb 2.x.x but i don't know how to install it withs icy phoenix. anyone can help me? ----------------------------------- JHOSMAN Sat 29 Mar, 2008 20:03 Re: Blog Mod ----------------------------------- It would be interesting to connect with a blog Icyphoenix Wordpress but on the same host where this forum, but with the news that are published on the portal. It can be done but it phpBB2 ----------------------------------- tibi2007 Sat 29 Mar, 2008 22:28 Re: Blog Mod ----------------------------------- i have the mod but it works with phpbb2. the question is that can anyone help me integrated with icy phoenix? [spoiler]############################################################## ## MOD Title: WP-UNITED WordPress - phpBB Integration Mod ## MOD Author: Jhong < admin@wp-united.com > (John Wells) www.wp-united.com ## MOD Description: Tightly integrates phpBB2 and WordPress. ## MOD Version: 0.9.5-beta ## ## Installation Level: (Medium) ## Installation Time: 35 Minutes ## Files To Edit: ## includes/page_header.php ## includes/page_tail.php ## viewonline.php ## admin/index.php ## includes/bbcode.php ## includes/constants.php ## includes/functions.php ## templates/subSilver/overall_header.tpl ## language/lang_english/lang_main.php ## language/lang_english/lang_admin.php ## login.php ## includes/usercp_register.php ## templates/subSilver/overall_footer.tpl ## includes/usercp_viewprofile.php ## templates/subSilver/viewtopic_body.tpl ## templates/subSilver/profile_view_body.tpl ## templates/subSilver/privmsgs_read_body.tpl ## templates/subSilver/subSilver.cfg ## viewtopic.php ## privmsg.php ## ## Included Files: templates/subsilver/blog.tpl ## blog.php ## wp-united/wordpress-entry-point.php ## wp-united/wp-functions.php ## wp-united/wp-template-loader.php ## wp-united/mod-settings.php ## wp-united/wp-integration-class.php ## wp-united/wpu-actions.php ## wp-united/wpu-plugin.php ## wp-united/wpu-latest-posts.php ## wp-united/wpu-template-funcs.php ## wp-united/widgets.php ## wp-united/abstractify.php ## wp-united/wpu-helper-funcs.php ## wp-united/options.php ## wp-united/cache/cache_readme.txt ## admin/wpu_usermap.php ## admin/admin_wordpress.tpl ## language/lang_english/lang_wordpress_admin.php ## language/lang_english/lang_wp-united.php ## templates/subSilver/blog.tpl ## templates/subSilver/wpu-blogs-homepage.css ## templates/subSilver/images/lang_english/icon_wpu_blog.gif ## templates/subSilver/images/lang_english/wpu_no_avatar.gif ## templates/subSilver/images/lang_english/wpu_unregistered.gif ## templates/subSilver/admin/wordpress_admin_body.tpl ## templates/subSilver/images/wp-united-working.gif ## templates/subSilver/images/wp-united-logo.gif ## ## License: http://opensource.org/licenses/gpl-license.php GNU General Public License v2 ############################################################## ## For security purposes, please check: http://www.phpbb.com/mods/ ## for the latest version of this MOD. Although MODs are checked ## before being allowed in the MODs Database there is no guarantee ## that there are no security problems within the MOD. No support ## will be given for MODs not found within the MODs Database which ## can be found at http://www.phpbb.com/mods/ ############################################################## ## Author Notes: Make sure you follow the instructions in the DIY INSTRUCTIONS section, in order for this MOD to work properly! ############################################################## ## Last updated: 04 June 2007 ## ## MOD History: Refer to the included changelog for details. ## ## ############################################################## ## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD ############################################################## # #-----[ DIY INSTRUCTIONS ]------------------------------------------ # After installing this mod, you must complete the following steps: STEP 1. Install WordPress before installing this mod, and ensure it is workng properly. If you need help, look at the instructions on the WordPress Codex, here: http://codex.wordpress.org/Installing_WordPress STEP 2. Go to your phpBB Admin Control Panel, and run the Setup Wizard on the "WP-United" page. Further instructions are included there to help you. NOTEs: - You can move/rename the blog.php file to wherever you like. For example, you could have it replace WordPress' index.php if you don't want our WordPress path to change. Just run the setup Wizard after you move it, and set the appropriate location, then open the file and enter the relative path back to your forum. - You must run the Setup Wizard all the way through, and be able to reach Step 6 error-free. If you don't, then don't expect WP-United to work properly! - If WordPress is already installed, and you plan to integrate logins, please run the integration mapping tool after running the Setup Wizard. - You should review the blog.tpl and make any changes necessary if you re not using the stock subSilver theme. - The "admin" WordPress user will never be integrated. So therefore the phpBB user named "admin" cannot have a corresponding WordPress account. This is for security reasons. - Whenever you upgrade WP-United or WordPress, you MUST delete any files that have appeared in the WP-United/cache folder. (Don't worry, they will be automatically recreated) - Additional options can be found in your wp-united/options.php file. - If you are integrating users, be sure to review the mapping tool in the WP-United Admin Panel every so often to ensure that everything is running smoothly. # #-----[ SQL ]------------------------------------------ # # (Use correct table prefix if not phpbb) # CREATE TABLE `phpbb_wpu_integration` ( `fullUri` VARCHAR( 255 ) NOT NULL, `fullPath` VARCHAR( 255 ) NOT NULL, `wpLogin` TINYINT( 1 ) NOT NULL, `permMapping` VARCHAR( 511 ) NOT NULL, `showInside` VARCHAR ( 255 ) NOT NULL, `dtdChange` TINYINT ( 1 ) NOT NULL, `ownBlogs` TINYINT ( 1 ) NOT NULL, `profileBtn` TINYINT ( 1 ) NOT NULL, `postBtn` TINYINT ( 1 ) NOT NULL, `styleSwitch` TINYINT ( 1 ) NOT NULL, `installStage` TINYINT ( 1 ) NOT NULL, `blogsEntry` VARCHAR ( 255 ) NOT NULL, `blogHomePage` TINYINT ( 1 ) NOT NULL, `blogHomeTitle` VARCHAR( 255 ) NOT NULL, `blogIntro` VARCHAR( 255 ) NOT NULL, `numBlogsPerPage` TINYINT ( 1 ) NOT NULL, `wpublStyles` TINYINT ( 1 ) NOT NULL, `encoding` VARCHAR ( 32 ) NOT NULL, `censorPosts` TINYINT ( 1 ) NOT NULL, `wpHdrSimple` TINYINT( 1 ) NOT NULL, `cssFirst` VARCHAR( 255 ) NOT NULL, `wpPage` VARCHAR( 255 ) NOT NULL, `pPadding` VARCHAR( 255 ) NOT NULL, `ugRun` TINYINT( 1 ) NOT NULL, `mustLogin` TINYINT ( 1 ) NOT NULL, `wpuVer` VARCHAR( 32 ) NOT NULL ); ALTER TABLE phpbb_users ADD user_wpublog_id VARCHAR(10) NULL DEFAULT NULL; ALTER TABLE phpbb_users ADD user_wpuint_id VARCHAR(10) NULL DEFAULT NULL; # #-----[ COPY ]------------------------------------------ # # Note: blog.php is the entry point to your integrated blog. You can put it anywhere you like, and rename it to anything you # like, provided you open it and provide the correct path to phpBB where shown. If you want to put it in your WordPress root # as index.php, it is OK to rename the existing WordPress' index.php to something like index-old.php copy blog.php to blog.php copy wp-united/wordpress-entry-point.php to wp-united/wordpress-entry-point.php copy wp-united/wp-functions.php to wp-united/wp-functions.php copy wp-united/wp-template-loader.php to wp-united/wp-template-loader.php copy wp-united/wp-integration-class.php to wp-united/wp-integration-class.php copy wp-united/mod-settings.php to wp-united/mod-settings.php copy wp-united/wpu-actions.php to wp-united/wpu-actions.php copy wp-united/wpu-plugin.php to wp-united/wpu-plugin.php copy wp-united/wpu-latest-posts.php to wp-united/wpu-latest-posts.php copy wp-united/wpu-template-funcs.php to wp-united/wpu-template-funcs.php copy wp-united/wpu-widgets.php to wp-united/wpu-widgets.php copy wp-united/abstractify.php to wp-united/abstractify.php copy wp-united/options.php to wp-united/options.php copy wp-united/cache/cache_readme.txt to wp-united/cache/cache_readme.txt copy wp-united/wpu-helper-funcs.php to wp-united/wpu-helper-funcs.php copy admin/admin_wordpress.php to admin/admin_wordpress.php copy admin/wpu_usermap.php to admin/wpu_usermap.php copy templates/subSilver/blog.tpl to templates/subSilver/blog.tpl copy templates/subSilver/wpu-blogs-homepage.css to templates/subSilver/wpu-blogs-homepage.css copy templates/subSilver/admin/wordpress_admin_body.tpl to templates/subSilver/admin/wordpress_admin_body.tpl copy templates/subSilver/images/wp-united-working.gif to templates/subSilver/images/wp-united-working.gif copy templates/subSilver/images/wp-united-logo.gif to templates/subSilver/images/wp-united-logo.gif copy language/lang_english/lang_wordpress_admin.php to language/lang_english/lang_wordpress_admin.php copy language/lang_english/lang_wp-united.php to language/lang_english/lang_wp-united.php copy templates/subSilver/images/lang_english/icon_wpu_blog.gif to templates/subSilver/images/lang_english/icon_wpu_blog.gif copy templates/subSilver/images/lang_english/wpu_no_avatar.gif to templates/subSilver/images/lang_english/wpu_no_avatar.gif copy templates/subSilver/images/lang_english/wpu_unregistered.gif to templates/subSilver/images/lang_english/wpu_unregistered.gif # #-----[ OPEN ]------------------------------------------ # includes/page_header.php # #-----[ FIND ]-------------------------------------------- # // Format Timezone. We are unable to use array_pop here, because of PHP3 compatibility $l_timezone = explode('.', $board_config['board_timezone']); # #-----[ BEFORE, ADD ]------------------------------------- # //WP-United require_once($phpbb_root_path . 'wp-united/mod-settings.' . $phpEx); global $wpSettings; $wpSettings = get_integration_settings(); //Do a reverse integration? if ( $wpSettings['showHdrFtr'] == 'REV' ) { if (empty($gen_simple_header)) { define('WPU_REVERSE_INTEGRATION', true); ob_start(); } } # #-----[ FIND ]------------------------------------------ # 'U_GROUP_CP' => append_sid('groupcp.'.$phpEx), # #-----[ AFTER, ADD ]------------------------------------------ # 'L_BLOG' => $lang['Blog'], 'U_BLOG' => append_sid($wpSettings['blogsUri']), # #-----[ FIND ]------------------------------------------ # $template->assign_block_vars('switch_enable_pm_popup', array()); } } # #-----[ AFTER, ADD ]------------------------------------------ # // //WordPress Integration MOD -- DTD switcher // if ( !empty($wpHeader) ) { $template->assign_block_vars('switch_wp_dtd', array( 'WP_DTD' => $lang['WP_DTD']) ); } else { $template->assign_block_vars('switch_phpbb_dtd', array()); } # #-----[ OPEN ]------------------------------------------ # includes/page_tail.php # #-----[ FIND ]-------------------------------------------- # $template->pparse('overall_footer'); # #-----[ AFTER, ADD ]------------------------------------------ # //WP-United global $pfContent; if ( defined('WPU_REVERSE_INTEGRATION') ) { $pfContent = ob_get_contents(); ob_end_clean(); //Now insert phpBB into a wordpress page include ($phpbb_root_path . 'wp-united/wordpress-entry-point.' . $phpEx); } # #-----[ OPEN ]------------------------------------------ # viewonline.php # #-----[ FIND ]------------------------------------------ # case PAGE_FAQ: $location = $lang['Viewing_FAQ']; $location_url = "faq.$phpEx"; break; # #-----[ AFTER, ADD ]------------------------------------------ # case PAGE_BLOG: $location = $lang['Blog']; $location_url = $wpSettings['blogsUri']; break; # #-----[ OPEN ]------------------------------------------ # admin/index.php # #-----[ FIND ]------------------------------------------ # case PAGE_FAQ: $location = $lang['Viewing_FAQ']; $location_url = "index.$phpEx?pane=right"; break; # #-----[ AFTER, ADD ]------------------------------------------ # case PAGE_BLOG: $location = $lang['Blog']; $location_url = $wpSettings['blogsUri']. "?pane=right"; break; # #-----[ FIND ]------------------------------------------ # case PAGE_FAQ: $location = $lang['Viewing_FAQ']; $location_url = "index.$phpEx?pane=right"; break; # #-----[ AFTER, ADD ]------------------------------------------ # case PAGE_BLOG: $location = $lang['Blog']; $location_url = $wpSettings['blogsUri']. "?pane=right"; break; # #-----[ OPEN ]------------------------------------------ # includes/constants.php # #-----[ FIND ]------------------------------------------ # define('PAGE_GROUPCP', -11); # #-----[ AFTER, ADD ]------------------------------------------ # define('PAGE_BLOG', -1385); # #-----[ FIND ]------------------------------------------ # define('VOTE_USERS_TABLE', $table_prefix.'vote_voters'); # #-----[ AFTER, ADD ]------------------------------------------ # //WordPress Integration MOD define('WP_INT_TABLE', $table_prefix.'wpu_integration'); # #-----[ OPEN ]------------------------------------------ # includes/functions.php # #-----[ FIND ]------------------------------------------ # function get_userdata($user, $force_str = false) { # #-----[ BEFORE, ADD ]------------------------------------------ # global $IN_WP_ADMIN; if ( !$IN_WP_ADMIN ) { # #-----[ FIND ]------------------------------------------ # global $db; if (!is_numeric($user) || $force_str) # #-----[ BEFORE, ADD ]------------------------------------------ # global $IN_WORDPRESS; if ($IN_WORDPRESS) { return wp_get_userdata($user); } else { //do standard phpBB function # #-----[ FIND ]------------------------------------------ # return ( $row = $db->sql_fetchrow($result) ) ? $row : false; } # #-----[ AFTER, ADD ]------------------------------------------ # } } # #-----[ FIND ]------------------------------------------ # global $db, $board_config; # #-----[ AFTER, ADD ]------------------------------------------ # global $phpbb_root_path, $phpEx; require_once($phpbb_root_path . 'wp-united/mod-settings.' . $phpEx); $wpSettings = get_integration_settings(); # #-----[ FIND ]------------------------------------------ # $url = preg_replace('#^/?(.*?)/?$#', '/1', trim($url)); # #-----[ AFTER, ADD ]------------------------------------------ # //WP-United flexible redirect for blogs if ( isset($wpSettings) ) { if ( !(strpos($url, '/wp-united-blog') === FALSE) ) { $server_protocol = $server_name = $server_port = $script_name = ''; $url = htmlentities(append_sid($wpSettings['blogsUri'])); } } # #-----[ OPEN ]------------------------------------------ # includes/bbcode.php # #-----[ FIND ]------------------------------------------ # function make_clickable($text) { # #-----[ BEFORE, ADD ]------------------------------------------ # if (!function_exists('make_clickable')) { # #-----[ FIND ]-------------------------------------------- # $text = preg_replace('#(script|about|applet|activex|chrome):#is', "1:", $text); # #-----[ BEFORE, ADD ]------------------------------------------ # global $IN_WORDPRESS; if ($IN_WORDPRESS) { return wp_make_clickable($text); //WP version } else {//phpBB version # #-----[ FIND ]------------------------------------------ # return($ret); } # #-----[ AFTER, ADD ]------------------------------------------ # } } # #-----[ OPEN ]------------------------------------------ # templates/subSilver/overall_header.tpl # #-----[ FIND ]------------------------------------------ # # #-----[ BEFORE, ADD ]------------------------------------------ # # #-----[ FIND ]------------------------------------------ # # #-----[ BEFORE, ADD ]------------------------------------------ # {switch_wp_dtd.WP_DTD} # #-----[ FIND ]------------------------------------------ # {SITENAME} :: {PAGE_TITLE} # #-----[ AFTER, ADD ]------------------------------------------ # # #-----[ FIND ]------------------------------------------ # # #-----[ BEFORE, ADD ]------------------------------------------ # {WP_HEADERINFO} # #-----[ FIND ]------------------------------------------ #   # #-----[ IN-LINE FIND ]------------------------------------------ # {L_LOGIN_LOGOUT}  # #-----[ IN-LINE AFTER, ADD ]------------------------------------------ #  {L_BLOG}{L_BLOG}  # #-----[ OPEN ]------------------------------------------ # language/lang_english/lang_main.php # #-----[ FIND ]-------------------------------------------- # ?> # #-----[ BEFORE, ADD ]------------------------------------- # //WordPress Integration MOD $lang['Blog'] = 'WordPress Blog'; # #-----[ OPEN ]------------------------------------------ # language/lang_english/lang_admin.php # #-----[ FIND ]-------------------------------------------- # ?> # #-----[ BEFORE, ADD ]------------------------------------- # //WordPress Integration MOD $lang['WordPress_Integration'] = 'WP-United'; # #-----[ OPEN ]------------------------------------------ # login.php # #-----[ FIND ]-------------------------------------------- # else if( ( isset($HTTP_GET_VARS['logout']) || isset($HTTP_POST_VARS['logout']) ) && $userdata['session_logged_in'] ) { # #-----[ AFTER, ADD ]------------------------------------------ # // //WordPress Integration MOD - Log out from WordPress // //Get integration settings include($phpbb_root_path . 'wp-united/mod-settings.' . $phpEx); $wpSettings = get_integration_settings(); if ( ($wpSettings == FALSE) || ($wpSettings['wpPath'] == "") ) { message_die(GENERAL_ERROR, $lang['WP_DBErr_Gen'], __LINE__, __FILE__, $sql); } if ( !empty($wpSettings['integrateLogin']) ) { require_once($phpbb_root_path . 'wp-united/wp-integration-class.' . $phpEx); $wpUtdInt = WPU_Integration::getInstance(get_defined_vars()); if ($wpUtdInt->can_connect_to_wp()) { $wpUtdInt->enter_wp_integration(); eval($wpUtdInt->exec()); $wpUtdInt->wp_logout(); $wpUtdInt->exit_wp_integration(); $wpUtdInt = null; unset ($wpUtdInt); } } //end of WordPress Integration MOD # #-----[ OPEN ]------------------------------------------ # includes/usercp_register.php # #-----[ FIND ]------------------------------------------ # else { $user_active = 1; $user_actkey = ''; } # #-----[ AFTER, ADD ]------------------------------------------ # //WP-United -- update the user in WP $wpuAction = 'PROFILE UPDATE'; require_once($phpbb_root_path . 'wp-united/wpu-actions.' . $phpEx); # #-----[ OPEN ]------------------------------------------ # templates/subSilver/overall_footer.tpl # #-----[ FIND ]------------------------------------------ # Powered by phpBB © 2001, 2005 phpBB Group
{TRANSLATION_INFO} # #-----[ IN-LINE FIND ]------------------------------------------ # {TRANSLATION_INFO} # #-----[ IN-LINE AFTER, ADD ]------------------------------------------ #
{WP_CREDIT} # #-----[ OPEN ]------------------------------------ # includes/usercp_viewprofile.php # #-----[ FIND ]------------------------------------ # include($phpbb_root_path . 'includes/page_header.'.$phpEx); # #-----[ AFTER, ADD ]------------------------------------ # //WP-UNITED Mod -- Blog buttons in profile if ( $wpSettings != FALSE ) { if (!empty($wpSettings['buttonsProfile'])) { if ( !empty($profiledata['user_wpublog_id']) ) { $blog_uri = append_sid($wpSettings['blogsUri'] . "?author=" . $profiledata['user_wpublog_id']); $blog_img = '' . $lang['Blog'] . ''; } else { $blog_img = ""; } } } //end WP-United Mod # #-----[ FIND ]------------------------------------ # 'YIM' => $yim, # #-----[ AFTER, ADD ]------------------------------------ # 'BLOG_IMG' => $blog_img, # #-----[ FIND ]------------------------------------ # 'L_INTERESTS' => $lang['Interests'], # #-----[ AFTER, ADD]------------------------------------ # 'L_BLOG' => $lang['Blog'], # #-----[ OPEN ]------------------------------------ # templates/subSilver/viewtopic_body.tpl # #-----[ FIND ]------------------------------------ # {postrow.PROFILE_IMG} {postrow.PM_IMG} {postrow.EMAIL_IMG} {postrow.WWW_IMG} {postrow.AIM_IMG} {postrow.YIM_IMG} {postrow.MSN_IMG} # #-----[ AFTER, ADD ]------------------------------------ # {L_BLOG}: {BLOG_IMG} # #-----[ OPEN ]------------------------------------ # templates/subSilver/privmsgs_read_body.tpl # #-----[ FIND ]------------------------------------ # {WWW_IMG} {AIM_IMG} {YIM_IMG} {MSN_IMG}