The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#4
|
|||
|
|||
![]()
I came a bit closer to the solution I guess, got some help from another guy regarding the importing problem from a csv file. But I can't get it working.
Anyone, any help here? ![]() Code:
$row = 1; if (($handle = fopen("yourdata.csv", "r")) !== FALSE) { while (($data = fgetcsv($handle, 1000, ",")) !== FALSE) { $num = count($rowfields); echo "<p> $num fields in line $row: <br /></p>\n"; $row++; ... $post_title = $rowfields[0]; $post_content = $rowfields[1]; ... // then you call the thread creator PostCreator(... } fclose($handle); } function PostCreator($title, $content... ) { ... // here you call the code to create the thread // it's not real code, just to help you figure it out $thread = $api->callApi('content_text', 'add', [ 'data' => [ 'rawtext' => $content, 'title' => $title, 'parentid' => 3, // ID of the forum section (or node as they call it in vBulletin 5) 'userid' => 1 // ID of the user to post the thread as ], 'options' => [ 'nl2br' => true ] ]); } |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|