Forum Replies Created
We need to create a basic import plugin. — This I have done, it’s experimental and I’d like some more eyes on the code before calling it “done”
I’ve looked for it but haven’t found it. I guess it hasn’t been published yet?
I ask for help in making a single-use script to import topics and posts into existing BBPress installation.
I need to import a legacy Q&A (hundreds of them) stored in a flat file. I need to handle fields missing in the source, which contains: Q poster, Q poster’s e-mail (optional), Q post date, Q content, A content. I want to import those and fill the missing fields with arbitrary values.
I chose to use API to do the task, which is a right choice, what was pointed above. I converted the source file manually and imported it into a multi-dimensional array. Then I want to use functions
bb_insert_postin a simple loop:
$topic_id = bb_insert_topic(array(...));
bb_insert_post(array('topic_id' => $topic_id, ...);
The problem is: I can create topics/posts only for current user. Any
poster_parameters passed to
bb_insert_are ignored. In other words, I can’t create anonymous topics/posts with poster credits I specify. I guess I’m missing a setting or constant?
The PHP script is located in the root folder of BBPress. I do
require('./bb-load.php');and log in to my keymaster user in the browser. All of
$bb_current_userare populated (I used FirePHP to debug).
What am I missing?In reply to: Blocked user login (back link)
Filed a ticket for this issue as it’s still present in r2442:
Unfortunately, no change in r2442. I posted a ticket for this issue:
Exactly. After that I manually deleted
usermetatable for that user but it got back somehow.
I just upgraded to latest revision from the trunk (2442), but the problem persists. This site is still in testing stage so I’m going to reinstall it and see if that helps.