Coding:How to fetch user profile data with SSI.php from a SMF forum database Kodlama: Nasıl Bir SMF forumunun veritabanından SSI.php ile kullanıcı profili veri almak için
Posted on 20. 20 tarihinde gönderildi. Jul, 2009 by Dragos in Coding , MySQL , PHP Temmuz, 2009 Kodlama, MySQL, PHP ve Dragos tarafından
Even though SMF offers a way to integrate their forum into any website, they do not provide enough information on how to do some basic tasks, eg fetching a member's profile details from the database. SMF rağmen herhangi bir web sitesi haline onların forumu entegre için bir yol sunuyor, onlar nasıl bazı temel görevleri yapmak için, veritabanından bir üyenin profil bilgilerini alma gibi yeterli bilgi vermemektedir. Fortunately, Netbeans has a very helpful feature, the code Navigator which shows an instant preview of all functions available in an open file. Neyse ki, Netbeans çok yararlı özelliği varsa, kodu Gezgin tüm fonksiyonları açık bir dosya mevcut bir anlık önizleme gösterir. So finding the function which does our job was pretty easy (though I couldn't find it on SMF's website). Böylece bizim iş oldukça kolay oldu öğrenin fonksiyon bulmak (gerçi SMF web sitesinde) bulamadım.
Anyway, to fetch data from the SMF database, using SMF's functions, we need to include SSI.php into our website. Her neyse, SMF's fonksiyonlarını kullanarak SMF veritabanından veri almak için web sitemizi içine SSI.php eklemeniz gerekir.
include_once('path/to/your/forum/SSI.php'); // replace path/to/your/forum with your path to the SMF forum include_once ( 'yol / sizin / forum / SSI.php'); / / yol yerine / to / SMF Forum için yolu ile / forum $userData=ssi_fetchMember(1,''); //ssi_fetchMember() takes two parameters: first: the member id as an integer or more than one id passed in an array; second parameter: output method as string: 'echo' or ''; $ userdata = ssi_fetchMember (1 ,''); / / ssi_fetchMember () iki parametre alır: ilk: üyesi bir tamsayı veya birden fazla olarak id bir dizi geçti id, ikinci parametre: string olarak çıkış yöntemi: echo '' veya ''; print_r($userData); //display the array containing the member's profile data print_r ($ userdata); / / dizi üye profili veri içeren ekran
Related posts: Ilgili posta:












































