Yêu cầu Hướng dẫn cú pháp kết nối user Xenforo & 1 script PHP

Thảo luận trong 'XenForo Development' bắt đầu bởi s200, 16/9/12.

1votes
5/5, 1 vote

  1. svlamnghiep

    svlamnghiep Member

    Bài viết:
    271
    Likes :
    84
    Note that as this is an initial release, there will almost certainly be some teething troubles. Please backup your databases prior to using this mod.

    Joomla - Xenforo integration via JFusion
    version 1.0.9

    Tested against
    XenForo 1.1.0

    JFusion 1.6.0 - can be downloaded from http://www.jfusion.org/
    Joomla 1.5.24 & 1.7.2

    Description
    This addon consists of two parts, a standalone XenForo addon and a plugin for the JFusion framework. The aim is to provide seamless logon integration between Joomla and XenForo.

    Limitations
    Due to the way this software works, both the Joomla installation and the Xenforo installation must be on the same domain and have their files on the same physical server. It must also be possible for one script to access the other, so both pieces of software must be in the same user account if your server uses open_basedir.

    The current release works with Joomla 1.5. and Joomla 1.6 when using JFusion 1.6.

    Known Issues
    [issue] language, timezone settings and avatar details are not added to the Joomla account that is created.
    This is a known issue with this version and is being worked on.

    Functionality
    • Ability to synchronise accounts between Joomla and XenForo.
    • Ability to synchronize accounts with the other supported software for JFusion (though this is currently untested).
    • Ability to login from either Joomla or Xenforo with the logins synchronised. So if you login to one, you are logged into both.
    • Automatically deals with password synchronisation between the two systems.
    Installation
    Installation is in two parts, as there is an addon to be installed into XenForo and a plugin to be installed into JFusion.

    XenForo Installation
    1. Download and unpack the JoomlaBridge.zip file
    2. First, upload the contents of upload/* to your Xenforo installation folder. This will just upload some files to a new directory in the library area of XenForo. No system files are modified or replaced.
    3. Go to your XenForo Admin Control Panel, and click *Install Add-on*.
    4. Click the *+ Install Add-on* button.
    5. Select *addon_JoomlaBridge.xml* as the file to upload.
    6. Click *Install Add-on* to confirm the installation of JoomlaBridge.
    7. From the *Home* tab of the adminCP, navigate to the *Options* area
    8. Select the *Joomla Bridge Configuration* menu item
    9. In the *Joomla Path* enter the full server path to your Joomla installation.
    10. Press the *Save Changes* button
    XenForo Upgrade
    1. Download and unpack the *JoomlaBridge.zip* file
    2. First, upload the contents of upload/* to your Xenforo installation folder. If you are prompted to overwrite the existing files, be sure to tell your FTP software to overwrite, so that the uploaded files repace the original files.
    3. Login to your XenForo Admin Control Panel, and navigate to *Home->Add-ons->List Add-on*.
    4. You are transfered to a page listing your addons. Find the *A Joomla Bridge* addon.
    5. To the right of the addon is a dropdown called controls, click that.
    6. From the menu that appears, click *Upgrade*. The upgrade page is displayed.
    7. Click the browse button and brose to where you unpacked the addon files.
    8. Select the *addon_JoomlaBridge.xml* file and click the *Open* button on the dialog.
    9. You are returned to the upgrade page.
    10. Click the *Upgrade Add-on* button and wait for the upgrade to complete.
    Joomla Installation

    First, install Joomla and ensure that the normal Joomla installation is working properly. During installation, create an admin account that uses a username that is not used on your forum. This is to ensure you can get back into the Joomla installation if you accidentally lock yourself out.

    Now you need to install version 1.6.0 of the JFusion Joomla plugin. Follow the instructions on the JFusion site here http://www.jfusion.org/docs to complete the JFusion installation.

    Once JFusion is installed, using an FTP program, navigate to the 'administrator/components/com_jfusion' directory and ensure that the 'plugins' sub directory is writable by your web server.
    1. Login to your Joomla admin panel.
    2. Navigate to Components->JFusion->Joomla Options
    3. Configure the Joomla Options to reflect your Joomla installation (the options are documented on the jfusion website). Note that advanced usergroup management is still undergoing testing, so may not work as expected in this release.
    4. Disable registrations in Joomla from the glocbal settings area
    5. Navigate to Components->JFusion->configuration
    6. Ensure that the xenforo plugin is set as the master
    7. Ensure joomla_int is set as the slave
    8. Ensure that the dual login option is ticked
    9. Press the green arrow to the left of the xenForo plugin to configure the plugin settigs.
    10. In the path box, enter the full server path to your XenForo installation directory
    11. Press the Next button
    12. You are now in the XenForo plugin configuration area. Check all settings, in particular, the url to your forums and the full path to your forums.
    13. Configure the appropriate usergroups for awaiting registration users and registered users.
    14. Ensure that the syncsessions and Enable Keep Alive options are set to yes (this is the tested configuration)
    15. Save the settings
    16. Navigate to Components->JFusion->Cpanel
    17. you will notice a red bar at the top right saying that JFusion is disabled with a small link to enable it. Click that link to enable JFusion.
    Joomla Upgrade

    1. Login to your Joomla admin panel.
    2. Navigate to Components->JFusion->Plugin Manager
    3. Scroll to the bottom of the page and select the Browse button to the right of the Package File option
    4. Browse to the location of the xenforo.zip file and select it.
    5. Press the Open button in the dialog. You are returned to the plugin manager page.
    6. Press the Upload File & Install button.
    The plugin is now upgraded. To ensure your settings are correct, you must now reload your settings as follows:

    1. Configuration page of JFusion.
    2. Check the radio button to the left pf the xenforo module.
    3. Click the pen to edit your settings.
    4. Normally, you should just be able to press save to update any settings, but check them just in case.
    That completes the basic configuration. At this point, all new user registrations must be made via XenForo. When a user first logs in via Joomla, there account will be created automatically. From that point onwards, the Joomla and XenForo session will be synchronised, so if you log in to Joomla, you will be logged into Xenforo and vice versa.

    Note that there is an issue that occurs if you login to XenForo prior to visiting the Joomla installation. If you the remain logged into and visit the Joomla installation, you will get an error. This issue is currently being worked on. You can overcome this issue by using the JFusion tools to synchronise users between installations.

    Change Log
    Release 1.0.1:
    * Fixed session sync issue for users that do not yet exist in Joomla
    * Fixed issue with accounts imported from vBulletin to XenForo

    Release 1.0.2:
    * Fixed some small problems that caused notice messages to be issued when PHP is set to display notices.

    Release 1.0.3:
    * Modified the admin script to automatically enable the 'System - JFusion' plugin and turn on the sync sessions and keep alive options.

    Release 1.0.4:
    * Fixed warnings with PHP 5.2.x

    Release 1.0.6:
    * Fixed bug in code that resulted in multiple sessions for each user.

    Release 1.0.7:
    * Added code to synch email addresses when Joomla is set as slave.

    Release 1.0.9:


    * Fixed an issue with Joomla 1.7.2 when using non standard database table prefix.

    Please note that if you are upgrading, you will need to go into the xenforo configuration from the JFusion configuration page and re-save the configuration.


    Note that this plugin now works with Joomla 1.5, Joomla 1.6 and Joomla 1.7 when using the JFusion 1.6.0 plugin for Joomla.
     
  2. Lil.Tee

    Lil.Tee Member

    Bài viết:
    405
    Likes :
    116
    addon tạo trang chủ bác nói là gì thế ạ?
     
  3. svlamnghiep

    svlamnghiep Member

    Bài viết:
    271
    Likes :
    84
    chỉ có xenportal chứ còn gì nữa
     
  4. Lil.Tee

    Lil.Tee Member

    Bài viết:
    405
    Likes :
    116
    À, em tưởng có addon nào khác :D
     
  5. nhiemtran

    nhiemtran New Member

    Bài viết:
    6
    Likes :
    0
    Mình cũng gặp trường hợp giống bạn. Mình có một website, một thời gian sau có nhu cầu làm thêm 4rum nữa. Vấn đề mình gặp phải cấu trúc giữa 2 database: website và 4rum khác nhau rất nhiều, cụ thể là bản user luôn. Và web site chạy được một thời gian nên có một lượng database nhất định.

    Vì vậy mình chọn cách giải quyết là để 2 database chạy song song.

    Nếu trang web của bạn là một trang mới và chưa có database thì bạn có thể add các bản của xenforo vào database của bạn. Nhớ đặt prefix để phân biệt. Sau đó sử dụng bản user của xenforo cho web mình luôn.

    Viết hàm đăng ký đăng nhập ở trang web thì sử dụng bản user của xenforo luôn. cấu trúc hàm đăng ký,đăng nhập có thể xem và copy trong source của xenforo.

    Một số ý kiến cá nhân. Có chổ nào sai các bạn góp ý. Cám ơn :)
     
  6. echipvms

    echipvms New Member

    Bài viết:
    65
    Likes :
    19
    Mình cũng muốn tìm hiểu cái này
     
comments powered by Disqus

Chia sẻ trang này

Đang tải...