Coding:How to fetch user profile data with SSI.php from a SMF forum database 코딩 : 어떻게 SMF 포럼 SSI.php와 데이터베이스에서 사용자 프로필 데이터를 가져올 수
Posted on 20. 20 게시됨. Jul, 2009 by Dragos in Coding , MySQL , PHP 7월, 2009 코딩, 마이 SQL, PHP로의 드라 고스에 의해
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 모든 웹사이트에 자신의 포럼을 통합하는 방법을 제공하고, 그들이하는 방법을 몇 가지 기본적인 작업에, 데이터베이스에서 해당 회원의 프로필 내용을 가져오는 예, 충분한 정보를 제공하지 않습니다. Fortunately, Netbeans has a very helpful feature, the code Navigator which shows an instant preview of all functions available in an open file. 다행히도, 넷빈즈 매우 유용한 기능을 가지고 코드를 네비게이터 모든 기능이 열려있는 파일에서 사용 가능한 인스턴트 미리보기를 보여줍니다. So finding the function which does our job was pretty easy (though I couldn't find it on SMF's website). 그래서 우리가이 일을 아주 쉽게되었다 않는 함수를 찾는 (비록 내가 SMF의 웹사이트에) 그것을 찾을 수없습니다.
Anyway, to fetch data from the SMF database, using SMF's functions, we need to include SSI.php into our website. 어쨌든,이 함수를 사용하여 SMF SMF 데이터베이스에서 데이터를 가져오기 위해, 우리는 우리의 웹사이트에 SSI.php 포함해야합니다.
include_once('path/to/your/forum/SSI.php'); // replace path/to/your/forum with your path to the SMF forum include_once ( '경로 / / 귀하의 / 포럼 / SSI.php'); / / 경로를 대체할 / 위해 / SMF 포럼에 귀하의 경로로 귀하의 / 포럼 $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 () 두 개의 매개 변수 : 첫 번째 : 회원 정수 또는 하나 이상의 id를 배열로 전달 id를, 두 번째 매개 변수 : 문자열로 출력하는 방법 : '메아리'또는 ''; print_r($userData); //display the array containing the member's profile data print_r ($ UserData를); / / 배열의 멤버의 프로필 데이터를 포함하는 디스플레이
Related posts: 관련 게시물 :












































