Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for '"wordpress'

Viewing 25 results - 25,301 through 25,325 (of 26,836 total)
  • Author
    Search Results
  • #59479
    _ck_
    Participant

    In theory it should be possible to use the topic_status field to set a future topics flag ie. “4” and check the database everytime bbpress runs for that flag, then change it to 0 when the time has passed.

    I don’t see this as a big need for forums (wordpress is another matter) but it’s a simple enough plugin so maybe I’ll try later this weekend.

    #59441
    _ck_
    Participant

    There are many other things you will need to do to get it working properly with wordpress.

    1. cookies paths need to be fixed in both programs

    2. the integration plugin should be installed

    3. the allow spaces in usernames plugin should be installed

    4. force all registrations/logins through wordpress from the several places they are buried on the forum (the WP interfaces are far more developed)

    5. add the ” set default role when registering new user though forum” plugin tweak

    There are probably a few others I’ve forgotten by now.

    #59241
    Sam Bauers
    Participant

    > it works, yay!

    Great!

    > idea: “power user toggle” that will turn the revision number into a hotlink to the svn directory

    Good idea, I’ll ad it to my “to do” list.

    > maybe show the filesize since curl/fopen has to pull the entire file down anyway so it knows the size

    It only completely pulls down the .php files from the trunk of each plugin to interrogate then and create the list, so I could only accurately report on the size of those. Otherwise I would have to traverse through all the subdirectories and add up the totals. Which would be a bit onerous.

    > a tally at the bottom of how many plugins shown would be interesting to see too

    A bit superfluous, but I’ll add it.

    > will it paginate if one day there are over a hundred plugins?

    That wouldn’t be too hard. But there aren’t that many plugins right now.

    For a lark I pointed the plugin to the WordPress Plugin SVN. It got about 1/4 of the way through retrieving the list of plugins and died (script timeout). Ultimately if this plugin is going to remain in use I’ll have to either compile the plugin list on a server somewhere and serve it as a single file to all plugins, or build a “specs” file format for plugins to use if they want to be in the browser. But that is what the WordPress plugin I mentioned earlier is attempting to do, so I’m more likely to assist in porting that plugin over to bbPress than extending this one to do it.

    #54080
    _ck_
    Participant

    Automatically adding a user’s new topic to their own favorites is as simple as this plugin. I’ve unhooked the notification plugin so users don’t get emailed for their own new topics starting.

    <?php
    /*
    * Plugin Name: User Topics To Favorites
    * Plugin Description: automatically adds new topics created by a user to their favorites
    * Author: _ck_
    * Author URI: http://CKon.wordpress.com
    * Plugin URI: http://CKon.wordpress.com
    * Version: 0.1
    */

    function user_topics_to_favorites($topic_id) {
    remove_action('bb_new_post', 'notification_new_post'); // don't email users about their new topic
    $topic = get_topic( get_topic_id( $topic_id ) ); // fetch topic poster's id
    bb_add_user_favorite( $topic->topic_poster, $topic_id );
    }
    add_action('bb_new_topic', 'user_topics_to_favorites');

    ?>

    #2167
    izzypop
    Member

    I have a WP install with BBPress installed on the same database in a subdirectory of WP. Install went well, looked in the database and my new forum topic was written in the database but all links on the BBPress forum lead to “No input file specified”. I’m suspecting that it has something to do with the config file. Let me know if you see something wrong here:

    // Change the prefix if you want to have multiple forums in a single database.

    $bb_table_prefix = ‘bb_’; // Only letters, numbers and underscores please!

    // The full URL of your bbPress install

    $bb->uri = ‘http://theasianman.com/wordpress/bbpress&#8217;;

    // What are you going to call me?

    $bb->name = ‘The Asian Man Forum’;

    // Set to true if you want pretty permalinks, set to ‘slugs’ if you want to use slug based pretty permalinks.

    $bb->mod_rewrite = false;

    // Your Akismet Key. You do not need a key to run bbPress, but if you want to take advantage

    // of Akismet’s powerful spam blocking, you’ll need one. You can get an Akismet key at

    // http://wordpress.com/api-keys/

    $bb->akismet_key = ”; // Example: ‘0123456789ab’

    // The rest is only useful if you are integrating bbPress with WordPress.

    // If you’re not, just leave it as it is.

    $bb->wp_table_prefix = ‘wp_’; // WordPress table prefix. Example: ‘wp_’;

    $bb->wp_home = ‘http://theasianman.com/wordpress&#8217;; // WordPress – Options->General: Blog address (URL) // Example: ‘http://example.com&#8217;

    $bb->wp_siteurl = ‘http://theasianman.com/wordpress&#8217;; // WordPress – Options->General: WordPress address (URL) // Example: ‘http://example.com&#8217;

    I’ve turned permalinks off because it seems people are having trouble with them in conjunction with GoDaddy (my clients host : ( ).

    I’ve created a .htaccess file with:

    Options +MultiViews

    Not sure what’s up. The default forum content is not even showing up.

    Cheer all and thanks in advance

    #49628

    In reply to: Emoticons For bbPress?

    mazdakam
    Member

    <?php

    /*

    Plugin Name: bbEmoticons

    Plugin URI:

    Description: A Clickable Smilies hack for bbPress. Thanks to kohaku and aka. Original WP Grins by Alex King.

    Author: hiromasa

    Author URI: http://hiromasa.zone.ne.jp/blog/

    Version: 0.72

    */

    /******************************************************************************

    * bbEmoticons version 0.72

    *

    * A Clickable Smilies hack for bbPress.

    *

    * @Author hiromasa (http://hiromasa.zone.ne.jp/blog/)

    * @Thanks kohaku (http://www.orioa.com/)

    * aka (http://plasticdreams.org/)

    * @Original WP Grins By Alex King

    * (http://www.alexking.org/software/wordpress/)

    * WordPress convert_smilies function and images

    * (https://wordpress.org/)

    *****************************************************************************/

    /* Copyright 2006 hiromasa (email : webmaster@hiromasa.zone.ne.jp)

    This program is free software; you can redistribute it and/or modify

    it under the terms of the GNU General Public License as published by

    the Free Software Foundation; either version 2 of the License, or

    (at your option) any later version.

    This program is distributed in the hope that it will be useful,

    but WITHOUT ANY WARRANTY; without even the implied warranty of

    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the

    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License

    along with this program; if not, write to the Free Software

    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

    */

    /******************************************************************************

    * bbEmoticons

    *

    * @author hiromasa

    * @version 0.72

    *

    *****************************************************************************/

    class bbEmoticons {

    var $bb_grins;

    var $bb_smiliessearch = array();

    var $bb_smiliesreplace = array();

    /**

    * The Constructor

    *

    * @param none

    * @return none

    */

    function bbEmoticons() {

    if (isset($_GET)) {

    switch ($_GET) {

    case “javascript”:

    $this->outputGringJS();

    }

    exit(0);

    }

    $bb_smiliestrans = array(

    :)‘ => ‘icon_smile.gif’,

    :D‘ => ‘icon_biggrin.gif’,

    :-D‘ => ‘icon_biggrin.gif’,

    ‘:grin:’ => ‘icon_biggrin.gif’,

    :)‘ => ‘icon_smile.gif’,

    :-)‘ => ‘icon_smile.gif’,

    ‘:smile:’ => ‘icon_smile.gif’,

    :(‘ => ‘icon_sad.gif’,

    :-(‘ => ‘icon_sad.gif’,

    ‘:sad:’ => ‘icon_sad.gif’,

    ‘ :o’ => ‘icon_surprised.gif’,

    ‘ :-o’ => ‘icon_surprised.gif’,

    ‘:eek:’ => ‘icon_surprised.gif’,

    ‘ 8O’ => ‘icon_eek.gif’,

    ‘ 8-O’ => ‘icon_eek.gif’,

    ‘:shock:’ => ‘icon_eek.gif’,

    :?‘ => ‘icon_confused.gif’,

    :-?‘ => ‘icon_confused.gif’,

    :???:’ => ‘icon_confused.gif’,

    8)‘ => ‘icon_cool.gif’,

    8-)‘ => ‘icon_cool.gif’,

    ‘:cool:’ => ‘icon_cool.gif’,

    ‘:lol:’ => ‘icon_lol.gif’,

    ‘ :x’ => ‘icon_mad.gif’,

    ‘ :-x’ => ‘icon_mad.gif’,

    ‘:mad:’ => ‘icon_mad.gif’,

    :P‘ => ‘icon_razz.gif’,

    :-P‘ => ‘icon_razz.gif’,

    ‘:razz:’ => ‘icon_razz.gif’,

    ‘:oops:’ => ‘icon_redface.gif’,

    ‘:cry:’ => ‘icon_cry.gif’,

    ‘:evil:’ => ‘icon_evil.gif’,

    ‘:twisted:’ => ‘icon_twisted.gif’,

    ‘:roll:’ => ‘icon_rolleyes.gif’,

    ‘:wink:’ => ‘icon_wink.gif’,

    ;)‘ => ‘icon_wink.gif’,

    ;-)‘ => ‘icon_wink.gif’,

    ‘:!:’ => ‘icon_exclaim.gif’,

    :?:’ => ‘icon_question.gif’,

    ‘:idea:’ => ‘icon_idea.gif’,

    ‘:arrow:’ => ‘icon_arrow.gif’,

    :|‘ => ‘icon_neutral.gif’,

    :-|‘ => ‘icon_neutral.gif’,

    ‘:neutral:’ => ‘icon_neutral.gif’,

    ‘:mrgreen:’ => ‘icon_mrgreen.gif’,

    );

    foreach($bb_smiliestrans as $smiley => $img) {

    $this->bb_smiliessearch[] = $smiley;

    $smiley_masked = htmlspecialchars(trim($smiley), ENT_QUOTES);

    $this->bb_smiliesreplace[] =

    ” <img src='” . bb_get_option(‘uri’) .

    “bb-images/smilies/$img’ alt=’$smiley_masked’ class=’wp-smiley’ /> “;

    }

    $this->grins = ”;

    $smiled = array();

    foreach ($bb_smiliestrans as $tag => $grin) {

    if (!in_array($grin, $smiled)) {

    $smiled[] = $grin;

    $tag = str_replace(‘ ‘, ”, $tag);

    $this->grins .=

    ‘<img src=”‘. bb_get_option(‘uri’) .

    ‘bb-images/smilies/’.$grin.'” alt=”‘ .$tag .

    ‘” onclick=”grin(‘ ‘.$tag.”);”/> ‘;

    }

    }

    }

    /**

    * post_text filter

    *

    * @param $text

    * @return $output

    */

    function convert_smilies($text) {

    $output = ”;

    $textarr = preg_split(“/(<.*>)/U”, $text, -1, PREG_SPLIT_DELIM_CAPTURE);

    $stop = count($textarr);

    for($i=0; $i<$stop; $i++) {

    $content = $textarr[$i];

    if((strlen($content) > 0) && (‘<‘ != $content{0})) {

    $content = str_replace(

    $this->bb_smiliessearch,

    $this->bb_smiliesreplace,

    $content);

    }

    $output .= $content;

    }

    return $output;

    }

    /**

    * bb_grins action

    *

    * @param none

    * @return none

    */

    function bb_grins() {

    echo ‘<div id=”bb_grins”>’ . $this->grins . ‘</div>’;

    }

    /**

    * bb_head action

    *

    * @param none

    * @return none

    */

    function bb_grins_head() {

    echo

    ‘<script type=”text/javascript” src=”‘. bb_get_option(‘uri’) .

    ‘my-plugins/bb-emoticons.php?bb_grins_output=javascript”></script>’ .

    “n”;

    }

    /**

    * Output Grins JavaScript

    *

    * @param none

    * @return none

    */

    function outputGringJS() {

    ?>

    function grin(tag) {

    var myField;

    if (document.getElementById(‘post_content’) && document.getElementById(‘post_content’).type == ‘textarea’) {

    myField = document.getElementById(‘post_content’);

    }

    else if (document.getElementById(‘comment’) && document.getElementById(‘comment’).type == ‘textarea’) {

    myField = document.getElementById(‘comment’);

    }

    else {

    return false;

    }

    if (document.selection) {

    myField.focus();

    sel = document.selection.createRange();

    sel.text = tag;

    myField.focus();

    }

    else if (myField.selectionStart || myField.selectionStart == ‘0’) {

    var startPos = myField.selectionStart;

    var endPos = myField.selectionEnd;

    var cursorPos = endPos;

    myField.value = myField.value.substring(0, startPos)

    + tag

    + myField.value.substring(endPos, myField.value.length);

    cursorPos += tag.length;

    myField.focus();

    myField.selectionStart = cursorPos;

    myField.selectionEnd = cursorPos;

    }

    else {

    myField.value += tag;

    myField.focus();

    }

    }

    <?php

    }

    }

    /******************************************************************************

    * – Define for bbPress interface

    *****************************************************************************/

    $bbemoticons = & new bbEmoticons();

    bb_add_filter(‘post_text’, array(&$bbemoticons, ‘convert_smilies’));

    //bb_head is not called always. :-)

    //bb_add_action(‘bb_head’, array(&$bbemoticons, ‘bb_grins_head’));

    bb_add_action(‘bb_feed_head’, array(&$bbemoticons, ‘bb_grins_head’));

    bb_add_action(‘bb_grins’, array(&$bbemoticons, ‘bb_grins’));

    ?>

    #49625

    In reply to: Emoticons For bbPress?

    mazdakam
    Member

    <?php

    /*

    Plugin Name: bbEmoticons

    Plugin URI:

    Description: A Clickable Smilies hack for bbPress. Thanks to kohaku and aka. Original WP Grins by Alex King.

    Author: hiromasa

    Author URI: http://hiromasa.zone.ne.jp/blog/

    Version: 0.72

    */

    /******************************************************************************

    * bbEmoticons version 0.72

    *

    * A Clickable Smilies hack for bbPress.

    *

    * @Author hiromasa (http://hiromasa.zone.ne.jp/blog/)

    * @Thanks kohaku (http://www.orioa.com/)

    * aka (http://plasticdreams.org/)

    * @Original WP Grins By Alex King

    * (http://www.alexking.org/software/wordpress/)

    * WordPress convert_smilies function and images

    * (https://wordpress.org/)

    *****************************************************************************/

    /* Copyright 2006 hiromasa (email : webmaster@hiromasa.zone.ne.jp)

    This program is free software; you can redistribute it and/or modify

    it under the terms of the GNU General Public License as published by

    the Free Software Foundation; either version 2 of the License, or

    (at your option) any later version.

    This program is distributed in the hope that it will be useful,

    but WITHOUT ANY WARRANTY; without even the implied warranty of

    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the

    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License

    along with this program; if not, write to the Free Software

    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

    */

    /******************************************************************************

    * bbEmoticons

    *

    * @author hiromasa

    * @version 0.72

    *

    *****************************************************************************/

    class bbEmoticons {

    var $bb_grins;

    var $bb_smiliessearch = array();

    var $bb_smiliesreplace = array();

    /**

    * The Constructor

    *

    * @param none

    * @return none

    */

    function bbEmoticons() {

    if (isset($_GET)) {

    switch ($_GET) {

    case “javascript”:

    $this->outputGringJS();

    }

    exit(0);

    }

    $bb_smiliestrans = array(

    :)‘ => ‘icon_smile.gif’,

    :D‘ => ‘icon_biggrin.gif’,

    :-D‘ => ‘icon_biggrin.gif’,

    ‘:grin:’ => ‘icon_biggrin.gif’,

    :)‘ => ‘icon_smile.gif’,

    :-)‘ => ‘icon_smile.gif’,

    ‘:smile:’ => ‘icon_smile.gif’,

    :(‘ => ‘icon_sad.gif’,

    :-(‘ => ‘icon_sad.gif’,

    ‘:sad:’ => ‘icon_sad.gif’,

    ‘ :o’ => ‘icon_surprised.gif’,

    ‘ :-o’ => ‘icon_surprised.gif’,

    ‘:eek:’ => ‘icon_surprised.gif’,

    ‘ 8O’ => ‘icon_eek.gif’,

    ‘ 8-O’ => ‘icon_eek.gif’,

    ‘:shock:’ => ‘icon_eek.gif’,

    :?‘ => ‘icon_confused.gif’,

    :-?‘ => ‘icon_confused.gif’,

    :???:’ => ‘icon_confused.gif’,

    8)‘ => ‘icon_cool.gif’,

    8-)‘ => ‘icon_cool.gif’,

    ‘:cool:’ => ‘icon_cool.gif’,

    ‘:lol:’ => ‘icon_lol.gif’,

    ‘ :x’ => ‘icon_mad.gif’,

    ‘ :-x’ => ‘icon_mad.gif’,

    ‘:mad:’ => ‘icon_mad.gif’,

    :P‘ => ‘icon_razz.gif’,

    :-P‘ => ‘icon_razz.gif’,

    ‘:razz:’ => ‘icon_razz.gif’,

    ‘:oops:’ => ‘icon_redface.gif’,

    ‘:cry:’ => ‘icon_cry.gif’,

    ‘:evil:’ => ‘icon_evil.gif’,

    ‘:twisted:’ => ‘icon_twisted.gif’,

    ‘:roll:’ => ‘icon_rolleyes.gif’,

    ‘:wink:’ => ‘icon_wink.gif’,

    ;)‘ => ‘icon_wink.gif’,

    ;-)‘ => ‘icon_wink.gif’,

    ‘:!:’ => ‘icon_exclaim.gif’,

    :?:’ => ‘icon_question.gif’,

    ‘:idea:’ => ‘icon_idea.gif’,

    ‘:arrow:’ => ‘icon_arrow.gif’,

    :|‘ => ‘icon_neutral.gif’,

    :-|‘ => ‘icon_neutral.gif’,

    ‘:neutral:’ => ‘icon_neutral.gif’,

    ‘:mrgreen:’ => ‘icon_mrgreen.gif’,

    );

    foreach($bb_smiliestrans as $smiley => $img) {

    $this->bb_smiliessearch[] = $smiley;

    $smiley_masked = htmlspecialchars(trim($smiley), ENT_QUOTES);

    $this->bb_smiliesreplace[] =

    ” <img src='” . bb_get_option(‘uri’) .

    “bb-images/smilies/$img’ alt=’$smiley_masked’ class=’wp-smiley’ /> “;

    }

    $this->grins = ”;

    $smiled = array();

    foreach ($bb_smiliestrans as $tag => $grin) {

    if (!in_array($grin, $smiled)) {

    $smiled[] = $grin;

    $tag = str_replace(‘ ‘, ”, $tag);

    $this->grins .=

    ‘<img src=”‘. bb_get_option(‘uri’) .

    ‘bb-images/smilies/’.$grin.'” alt=”‘ .$tag .

    ‘” onclick=”grin(‘ ‘.$tag.”);”/> ‘;

    }

    }

    }

    /**

    * post_text filter

    *

    * @param $text

    * @return $output

    */

    function convert_smilies($text) {

    $output = ”;

    $textarr = preg_split(“/(<.*>)/U”, $text, -1, PREG_SPLIT_DELIM_CAPTURE);

    $stop = count($textarr);

    for($i=0; $i<$stop; $i++) {

    $content = $textarr[$i];

    if((strlen($content) > 0) && (‘<‘ != $content{0})) {

    $content = str_replace(

    $this->bb_smiliessearch,

    $this->bb_smiliesreplace,

    $content);

    }

    $output .= $content;

    }

    return $output;

    }

    /**

    * bb_grins action

    *

    * @param none

    * @return none

    */

    function bb_grins() {

    echo ‘<div id=”bb_grins”>’ . $this->grins . ‘</div>’;

    }

    /**

    * bb_head action

    *

    * @param none

    * @return none

    */

    function bb_grins_head() {

    echo

    ‘<script type=”text/javascript” src=”‘. bb_get_option(‘uri’) .

    ‘my-plugins/bb-emoticons.php?bb_grins_output=javascript”></script>’ .

    “n”;

    }

    /**

    * Output Grins JavaScript

    *

    * @param none

    * @return none

    */

    function outputGringJS() {

    function grin(tag) {

    var myField;

    if (document.getElementById(‘post_content’) && document.getElementById(‘post_content’).type == ‘textarea’) {

    myField = document.getElementById(‘post_content’);

    }

    else if (document.getElementById(‘comment’) && document.getElementById(‘comment’).type == ‘textarea’) {

    myField = document.getElementById(‘comment’);

    }

    else {

    return false;

    }

    if (document.selection) {

    myField.focus();

    sel = document.selection.createRange();

    sel.text = tag;

    myField.focus();

    }

    else if (myField.selectionStart || myField.selectionStart == ‘0’) {

    var startPos = myField.selectionStart;

    var endPos = myField.selectionEnd;

    var cursorPos = endPos;

    myField.value = myField.value.substring(0, startPos)

    + tag

    + myField.value.substring(endPos, myField.value.length);

    cursorPos += tag.length;

    myField.focus();

    myField.selectionStart = cursorPos;

    myField.selectionEnd = cursorPos;

    }

    else {

    myField.value += tag;

    myField.focus();

    }

    }

    }

    }

    /******************************************************************************

    * – Define for bbPress interface

    *****************************************************************************/

    $bbemoticons = & new bbEmoticons();

    bb_add_filter(‘post_text’, array(&$bbemoticons, ‘convert_smilies’));

    //bb_head is not called always. :-)

    //bb_add_action(‘bb_head’, array(&$bbemoticons, ‘bb_grins_head’));

    bb_add_action(‘bb_feed_head’, array(&$bbemoticons, ‘bb_grins_head’));

    bb_add_action(‘bb_grins’, array(&$bbemoticons, ‘bb_grins’));

    ?>

    #59404

    In reply to: forum.wp-persian.com

    _ck_
    Participant

    That’s actually pretty impressive to see.

    I think I’ve seen wordpress/bbpress on some Israeli sites too but in Hebrew.

    #59417
    _ck_
    Participant

    And a report post plugin is born – tested working!

    Needs a few features but gets the job done for now:

    <?php
    /*
    Plugin Name: report post
    Description: allows members to report a post to admin/moderators
    Plugin URI: http://CKon.wordpress.com
    Author: _ck_
    Author URI: http://CKon.wordpress.com
    Version: 0.1
    */

    /*
    instructions: install, activate and put <? report_post_link(); ?> in your post.php template where you want the link to be seen
    optional in stylesheet: a.report_post {color:red;}

    todo:
    1. don't let them report more than once on a post - or more than too many times per minute/hour
    2. auto-delete post if more than x reports from different members
    3. auto-post report into a specified moderator's forum #
    4. maybe ajax xmlhttp call instead of real form post so there's no page movement
    5. it's technically possible to alert a browing mod with a popup directing to the reported post, no email needed
    */

    function report_post_link($post_id=0) {
    if (bb_current_user_can('participate') ) :
    $post_id= get_post_id( $post_id );
    if (get_post_author_id($post_id) != bb_get_current_user_info( 'id' )) {
    echo '<a class=report_post title="report post to moderator" href="#post-'.$post_id.'" onClick="report_post('.$post_id.');return false;">Report</a>';
    }
    endif;
    }

    function report_post_form() {
    if (bb_current_user_can('participate')) :
    if (isset($_POST['report_post_id']) && isset($_POST['report_post_reason'])) {
    echo '<scr'.'ipt type="text/javascript">alert("Thank you for the report. A moderator has been notified.");</scr'.'ipt>';
    $post_id=intval($_POST['report_post_id']);
    // todo: custom response if invalid id, problem sending email - maybe flush output buffer so member gets alert faster
    $to = bb_get_option('admin_email');
    $subject = " reported post by member for moderation";
    $headers = "From: ".bb_get_option('admin_email');
    $message ="report by: ".bb_get_current_user_info( 'name' )." (".bb_get_current_user_info( 'id' ).") email: ".bb_get_current_user_info( 'email' )."rnrn";
    $message.="report: ".wordwrap(strip_tags(substr($_POST['report_post_reason'],0,255)),70)."rnrn".get_post_link($post_id)."rn";
    $message.="post by: ". get_post_author($post_id)."rn"; // add "member since", total posts, blah blah
    $message.="rnrnReport Trace:rn";
    $message.="IP: ".$_SERVER['REMOTE_ADDR']."rn";
    $message.="Host: ".gethostbyaddr($_SERVER['REMOTE_ADDR'])."rn"; // useful but can add a few seconds
    $message.="Agent: ".$_SERVER['HTTP_USER_AGENT']."rn";
    $message.="Refer: ". $_REQUEST['refer']."rn";
    $message.="URL: http://".$_SERVER['HTTP_HOST'].$GLOBALS["HTTP_SERVER_VARS"]["REQUEST_URI"]."rn";
    mail( $to, $subject, $message,$headers);
    }
    echo '<form method="POST" name="report_post_form" id="report_post_form" style="display:none;visibility:hidden"><input type=hidden name="report_post_id"><input type=hidden name="report_post_reason"></form>';
    echo '<scr'.'ipt type="text/javascript">
    function report_post(post_id) {
    var report_post_reason = prompt("Please enter a short but descriptive reason why a moderator needs to review this post:", "");
    if (report_post_reason && report_post_reason.length>9) {
    document.report_post_form.report_post_id.value=post_id;
    document.report_post_form.action="#post-"+post_id;
    document.report_post_form.report_post_reason.value=report_post_reason;
    document.report_post_form.submit();
    } else {alert("report cancelled, incomplete description"); }
    }
    </scr'.'ipt>';
    endif;
    }
    add_action('bb_foot', 'report_post_form');

    ?>

    #59398
    _ck_
    Participant

    I’ve created couple of enhancements to the view count plugin which I’ve attached to the plugin’s page.

    It’s very easy to edit the templates.

    (Oh and xml-rpc is the first thing I disable in any blog configuration – it’s a spammer & evil hacker’s dream)

    The WordPress (and bbpress) community is very dis-organized, which is probably to be expected given the nature of blogging itself, everyone just does their own thing and hopes someone else shows up and comes along for the ride.

    #2160
    mousehunter
    Member

    I would like to display the “tag” field in the widget, however, I’m not sure how to do it. I know where to put the code to make it display, but how do I actually get the value from the DB (which table/field). I thought $bbTopic might contain it, but i was wrong. Any help would be appreciated. Thanks.

    #2158

    Topic: forum.wp-persian.com

    in forum Showcase
    mazdakam
    Member

    Official support place for Persian WordPress just lunch

    Detective
    Member

    I think it should not be hard to code such a plugin. It would have to create a new database table, like bb_read, with the following fields:

    – bb_user

    – bb_post

    – bb_last_comment_read

    This way you could modify the posts query, left joining it with this table. If the join is NULL (please correct me if i’m wrong, i haven’t done these things in a lot of time), then the user has never read the post. If bb_last_comment_read is less than the actual number of comments or replies, then he hasn’t read the last post.

    Another interesting alternative is what the folks at wordpress.org are doing … for non-visited links they have a font with a font-weight: bold style. So you can see which topics are new.

    #59321
    oledole
    Member

    Odd it is. I’ve posted this over att the WP forum as well, https://wordpress.org/support/topic/127302?replies=3. Nothing there that has worked for me, so far. There are a lot of htaccess-issues regarding password protection problems, but nothing I’ve found so far has fixed this.

    #58101

    In reply to: bbSync

    crowspeaker
    Member

    fel,

    Using a forum name instead of a number in the Write Post screen while the default is left blank also results in no post to the forum.

    Anything I put in bbsync ~ forum box in the Write Post screen is overridden by what is in the default screen.

    So a summary; no posts if default is empty on config screen; posts only if the default screen is filled in and then posts only to that forum, overriding anything in the Write screen.

    BTW, I have two additional integration plugins running: in BBPress, I have WordPress Integration 0.7 by Michael D Adams; in WP I have bbPress Integration 0.74 also by Michael D Adams.

    #59318
    berniesteak
    Member

    Having the very same issue here. Main wordpress site is at / bbpress at /forum/ and although all appears fine the headers returned are 404 not found.

    If anyone can shed any light on this weirdness that would be much appreciated.

    I attempted moving the htaccess content into a vhost file on my server and put them in <Directory> sections, to see if that made any difference. No surprise really it didn’t.

    I’m not an htaccess ot http expert and this seems just weird to me.

    #57454
    vlp
    Member

    Thanks for this tutorials guys, it really helps.

    One more thing is not straightforward to me, how to integrate the forum Titles. I tried it like it was written here but it didn’t work out.

    You can see my integration on http://www.tasty.sk/forum

    #2151
    Trent Adams
    Member

    I came across this post in the wp.org forums and it seems to work from what I hear.

    Trent

    #58905
    M
    Member

    @_ck_ – “Hack” core files = baaad. Try localization… it works for bbPress and WordPress. Easy to do as well.

    I want to change bbPress’ default text

    If you don’t like the “favorites” text, you can change it without losing the changes on an update. Not updating because of some little changes you made is bad news indeed. Might as well wear a sign that says “hack me.”

    #58683
    M
    Member

    Funny you mention this… I’m doing some work for a client at the moment using WordPress and I wanted to change some of the admin backend text without modifying core files. Localization using an en.mo file turned out to be the way to go.

    I believe bbPress supports localization as well. It’s probably going to be the route you’ll want to take. (edit: it does, BBLANG in config.php, drop the .mo file in /bb-includes/languages/ I would assume)

    The file you’ll need to edit is a compiled binary, so you’ll have to get the bbpress.pot file, probably from the bbPress site somewhere. (edit: http://svn.automattic.com/bbpress-i18n/pot/tags/)

    Once you’ve got the file, check out poEdit (http://sourceforge.net/projects/poedit/). It’s an open-source cross-platform mo/po/pot editor. Create a New catalog from .pot file, make sure the option to compile to .mo is checked in the preferences, and you should be good to go.

    The top-left box contains the text to be translated, the bottom-left contains the “translation.” Ctrl-F, find the string, and you’re good from there.

    Note: I haven’t tried this with bbPress but it works great with WordPress. Hope it helps.

    #52444

    In reply to: blockquote?

    I just installed bbpress yetserday on a new domain and have integrated it with wordpress using the plugin, etc. I also have found that the default template has no blockquote support. Even by including the blockquote definition given above by Trent verbatim in my bb-admin/style.css file does no good, here is a view source excerpt of the source file:

    <blockquote><p>[Shakir 5:57] O you who believe! do not take for guardians those who take your religion for a mockery and a joke...</p></blockquote>

    as a test…

    testing blockquote here in bbpress support

    nope. above line doesnt render in blockquoted indent either.

    i think the problem is the insertion of <p></p> tags around every paragraph. Since blockquote is an inline style, the p tags override it. we could get around this by using a div class=blockquote kind of construction instead but wouldt it be nicer if blockquote just worked out of the box?

    #2149
    bobbyh
    Member

    A lot of bbPress forums have taken advantage of easy user integration with WordPress. The next step to integrating a WordPress blog and bbPress Forum is to create a bbPress Theme to match your WordPress Theme. bbPress doesn’t ship with built-in support for a sidebar, although I found it trivial to add this with a small plugin. What I really missed was a lightweight way to access WordPress’ wp_list_bookmarks Template Tag function, which lets you display your WordPress Blogroll links.

    To add this functionality, I wrote this bbPress List Bookmarks plugin. To install this plugin, download the zip and unzip it to your bbPress server under your /my-plugins folder. The zip should extract to a folder named “list_bookmarks”, so the location of these files should be /my-plugins/list_bookmarks. Then, in your bbPress theme, add a wp_list_bookmarks Template Tag with whatever parameters you want (just like you would when editing a WordPress Theme). You shouldn’t need to hack any of the plugin files to get this to work, although of course you’ll have to edit your bbPress Theme to take advantage of this plugin.

    This plugin should work whether or not these WordPress tables are located in the same database as your bbPress tables, as long as your WordPress tables are located in the same database as your integrated user tables.

    I’ve tested this plugin on my site, which currently uses bbPress v0.8.2.1 and WordPress v2.2.1. If you use WordPress 2.0 or earlier and you want to use this plugin, you should probably upgrade your WordPress first as wp_list_bookmarks is a new function introduced in WordPress v2.1. I don’t think it should matter what version of bbPress you use.

    This plugin ships with a database class called bbwpdb.php that lets us access the WordPress database tables. The bbwpdb.php file is basically a clone of the bbPress /bb-includes/db.php file, edited to let us retrieve WordPress tables. The remaining files are simply three WordPress PHP pages needed (wp-admin/admin-db.php, wp-includes/bookmark-templates.php, and wp-includes/bookmark.php), with slight edits to make it use the bbwpdb database class, instead of the WordPress or bbPress database class. The last file (list_bookmarks.php) just glues everything together.

    #59269
    M
    Member

    People that are attracted to bbPress will be attracted because of its out-of-the-box simplicity and its extensibility.

    It’s great… if you want a plugin and you’ve messed around with WordPress for any length of time, you’ll feel right at home. I personally dislike polls… _ck_ obviously doesn’t, and he’s not alone. That’s the beauty of bbPress. These features aren’t crammed down your throat; rather they are completely optional.

    Also, I don’t think that bbPress was built to win a popularity contest. It was built with certain things in mind and is continuing in that trend. I think that’s great.

    One more thing… those people who were attracted to other forum software solutions (ie, SMF, IPB, vB), wanted something feature-bloated. All kinds of things pouring out of every corner. They wouldn’t be attracted to bbPress unless it became a miniature of what they were already using. And what’s the point in that, eh?

    #59350
    M
    Member

    Stick with the ezSQL format… it’ll be much easier.

    Something like this (using foreach instead of while):

    $query = "SELECT * FROM $bbdb->menu
    WHERE set = 'inactive' ORDER BY order ASC";
    $r = $bbdb->get_results( $query );

    foreach( $r as $rw ) {
    // now mess with $rw
    echo $rw->database_row . "<br>n";
    }

    Something that might be helpful would be to browse the source of the ezSQL class in /wp-includes/wp-db.php

    The latest from Justin Vincent, the author

    http://www.woyano.com/jv/ezsql

    The version used in bbPress and WordPress

    https://trac.wordpress.org/browser/trunk/wp-includes/wp-db.php

    It might help you… you’d be able to see where mysql_query is begin used, and how to use the ezSQL format best.

    I think the reason you’re running into problems with mysql_fetch_array is because it’s already used.

    Not sure on that one though… I would have to check.

    Also, what might cause an error: $bbdb->query will not return anything at all. $bbdb->get_results needs to be used for multi-dimensional array data, $bbdb->get_row or $bbdb->get_col need to be used for single array data, and $bbdb->get_var needs to be used for non-array/string data. $bbdb->query is used for inserting data, the others are used for retrieving it.

    Someone correct me if I’m wrong, but I’m pretty positive that’s how it goes.

    ezSQL is lovely. It certainly takes the pain out of MySQL data manipulation.

    So I guess that makes the answer to your question “Neither.” $bbdb->get_results should do the trick.

    And sorry for the screed. :D

    #57453
    Vili
    Participant

    kenzor — That would indeed work the same way and be far easier to do. It remains a mystery to me why I didn’t do it that way to begin with. I must have lost my +5 Blessed Boots of Intelligence at some point.

Viewing 25 results - 25,301 through 25,325 (of 26,836 total)
Skip to toolbar