Search Results for 'code'
-
Search Results
-
Topic: Forum Import Tool
I’ve been struggling for a while now to get the forum import tool to run efficiently. I notice that for some forums, the mysql query code is supplied, but for others it is not. It seems that the process would run a lot faster if I performed the entire operation in mysql instead of using the import tool. I have ~2M posts I need to import. Does anyone have the MYSQL queries for converting Xenforo to BbPress?
Thanks!
Hello,
I would like to add 2 more textarea fields in “Create New Topic” page in addition to an original textarea of bbPress.
I added following code to function.php, but an original textarea of bbPress was disappeared and couldn’t become submit, error of “ERROR: Your topic cannot be empty. “.
——————————-
add_action ( ‘bbp_theme_before_topic_form_content’, ‘bbp_extra_fields’);
function bbp_extra_fields() {
$value = get_post_meta( bbp_get_topic_id(), ‘bbp_extra_field1’, true);
echo ‘<label for=”bbp_extra_field1”>textarea1</label><br>’;
echo “<textarea name=’bbp_extra_field1′ rows=’10’ cols=’78’ value='”.$value.”‘></p>”;$value = get_post_meta( bbp_get_topic_id(), ‘bbp_extra_field2’, true);
echo ‘<label for=”bbp_extra_field1″>textarea2</label><br>’;
echo “<textarea name=’bbp_extra_field2′ rows=’10’ cols=’78’ value='”.$value.”‘></p>”;
}add_action ( ‘bbp_new_topic’, ‘bbp_save_extra_fields’, 10, 1 );
add_action ( ‘bbp_edit_topic’, ‘bbp_save_extra_fields’, 10, 1 );function bbp_save_extra_fields($topic_id=0) {
if (isset($_POST) && $_POST[‘bbp_extra_field1’]!=”)
update_post_meta( $topic_id, ‘bbp_extra_field1’, $_POST[‘bbp_extra_field1’] );
if (isset($_POST) && $_POST[‘bbp_extra_field2’]!=”)
update_post_meta( $topic_id, ‘bbp_extra_field2’, $_POST[‘bbp_extra_field2’] );
}add_action(‘bbp_template_before_replies_loop’, ‘bbp_show_extra_fields’);
function bbp_show_extra_fields() {
$topic_id = bbp_get_topic_id();
$value1 = get_post_meta( $topic_id, ‘bbp_extra_field1’, true);
$value2 = get_post_meta( $topic_id, ‘bbp_extra_field2’, true);echo “textarea1: “.$value1.”<br>”;
echo “textarea2: “.$value2.”<br>”;
}
——————————-What I want to do is;
・There are 3 of textarea fields in “Create New Topic” page.
・After submitted, the content being input in 3 textarea are shown in 1 original posted textarea like,<p>
content of textarea1
</p>
<p>
content of textarea2
</p>
<p>
content of textarea3
</p>If anyone know it, please help me.
Thanks,
Hi,
I started to setup my first forum.
For me it is necessary to share files.
I’m using the WordpRess Download Manager PlugIn
https://wordpress.org/plugins/download-manager/
to share files and I have the following problem:I would like to use the Short-Codes (e.g. [wpdm_package id=’120′])
of the Download Manager to insert files into a Topic, but ist doesn’t work.
The Topic displays only the commands and doesn’t display the designed download buttons.Is anyone able to help? Or should I use an other PlugIn to share files?
Thx for your help.