Anh chị em Việt Nam
COME AS GUESTS. STAY AS FAMILY.
Resource icon

Redirection script for SMF 2.0 2.1

No permission to download
Script to help you redirect from SMF 2.0 to Xenforo 1.5 / 2.x

There are a few things for this script to work correctly:
  • SMF 2.0 was using normal URLs, like "https://www.domain.com/smf/index.php?board=5.0"
    So "Search engine friendly URLs" and other SEO/Pretty URL's where not enabled. You will need to change the script if you where using one of those.
  • During the import to Xenforo, you choose to retain ID's
  • Both forums are installed in separate directories (or domains)
Configuration:

Download this script and modify to your needs.
Put it in the original location of your old SMF forum, overwriting the original index.php file.

You will need to change these variables in the script:
PHP:
// *** Variables ***

$redir_url = 'https://www.yourdomain.com';    // URL of your new forum, without trailing slash
$forums = 'forums';                            // Default path to index (only change this if you are using route filters)
$threads = 'threads';                        // Default path to topic (only change this if you are using route filters)
$posts = 'posts';                            // Default path to posts (only change this if you are using route filters)
$members = 'members';                        // Default path to members (only change this if you are using route filters)
$threads_count = 20;                        // Make sure the number of messages per page is the same for SMF and XenForo.
$mode = 0;                                    // 0 = testing / 1 = temp redirect / 2 = perm redirect
Note 1: If you installed Xenforo in a subdirectory, you can use something like $redir_url = 'https://www.yourdomain.com/subdir';

Note 2: Make sure you use the same value for the number of messages per page for both forums.
So, if SMF was setup for 10 messages per page, you should do the same for Xenforo (Setup > Options > Threads > Discussions per page) and modify $threads_count to 10. This way you can also redirect thread pages correctly!

Examples of the redirections this script handles:
Author
RAMZES
Downloads
3
Lượt xem
43
First release
Last update
Rating
0,00 star(s) 0 ratings

More resources from RAMZES

About us

VietFriend community được xây dựng với mục đích kết nối mọi người lại với nhau, là nơi để giao lưu, học hỏi và chia sẻ mọi thứ trên đời.
Top