Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 31,726 through 31,750 (of 32,431 total)
  • Author
    Search Results
  • #1126

    Topic: My forum

    in forum Themes
    veb
    Member

    This forum I am creating for a small indie game (www.toribash.com) and SMF just didnt cut it. Way too difficult to change core code, and to me, make new plugins!

    This is a temporary link, seeing I’m not anywhere NEAR finnished. As you can see I am using the emotions plugin, avatar plugin, PM plugin and a few of my own.

    http://veb.bounceme.net/bbpress/

    Comments welcome :)

    #52630
    veb
    Member

    I think combining them would do the job nicely, and even having it so you can have a small image as a signature too :)

    #51675
    chrishajer
    Participant

    I may have downloaded the wrong version. This is from the file notification_all.php

    * Plugin URI: http://www.la-school.com/2006/bbpress-notification/

    * Version: 1.1

    Oops! “notification all” – haha

    I will download the new version now, with the enhancement on the last poster’s name. Thanks a bunch. Merry Christmas.

    #52273
    ardentfrost
    Member

    Anyone who is having trouble with the server please do this:

    -open a command line and type tracert www.rayd.org

    -Copy the resulting text and email it to thansen@qualitytech.com

    -If it starts timing out over and over, just press CTRL-C to stop the process, copy and send it on.

    Due to spammers, sometimes a lot of the countries in the far east get blocked. Sending that tracert text will allow us make sure legitimate users are allowed through the firewalls.

    Thanks!

    #52329
    implicated
    Member

    Your PHP version is rather old, use this:

    if (!function_exists('file_put_contents')) {

    function file_put_contents($filename, $content) {

    if ($fp = fopen($filename, 'w')) {

    $result = fwrite($fp, $content);

    fclose($fp);

    return $result;

    }

    else {

    return false;

    }

    }

    }

    #51673
    chrishajer
    Participant

    Enhancement request: could the notification include the name of the member who made the post?

    So,

    There is a new post on: POSTTITLE

    By: MEMBERNAME

    URL

    #52572
    weirdtherapy
    Member

    I should have made that sooner because it could have caused confusion. The Link in the first posting no longer shows the first template because I changed the template, cause of problems that coud happen with google.

    That’s how the first one looks like:

    http://www.weirdtherapy.com/images/borderline-green-01-shot.jpg

    can some Mod change the link in the first posting pls? :)

    I also added a note at the template that people should keep the policys in mind – I will try to make one that is more policy friendly :)

    #52629
    ardentfrost
    Member

    Alright veb, it’s updated… so make your change ;)

    Although it MIGHT mess you up a little because I think your plugin will have to be added into mine when Avatar is used (open the new bb-avatar.php file and you’ll see why). Plus, with the new release of Avatar, if people do Signature the way you describe, it won’t work.

    I don’t know, what do you think? Maybe we should just combine the two, or have multiple releases. I don’t know how people are going to want to implement.

    #52628
    ardentfrost
    Member

    Glad you used my code as a base :) I will be updating my Avatar code very soon so that functions.php no longer has to be changed. I’ll expect you to update this when I finish ;)

    #52702

    I think this would be an idea for later versions (around 1.0 or so) … very nice idea =)

    #52270
    nekketsu
    Member

    Table creation is automatic. It should install if you navigate to your domain/pm.php or put the message code on your front page.


    Not automatic for me :/

    #52619

    You want to read out the two single vars from the db, am I right?

    So I suggest using $variable = $bbdb->get_var("SELECT...");.

    #52269
    drtech
    Participant

    I also had to hard code message.php for it to work.

    <– “if (wp_knu_)

    $touser = $bbdb->get_row(“SELECT * FROM “.wp_knu_.”users WHERE ID = $toid”);

    else

    $touser = $bbdb->get_row(“SELECT * FROM “.bb_knu_.”users WHERE ID = $toid”);

    pm_user_form( $touser, ” );

    exit;”–>

    #52267
    Trent Adams
    Member

    message.php is the main one. That is where you would hardcode it.

    Trent

    #52266
    suleiman
    Member

    hmmm…I’m having the same problem, where I get the error about the bbpress database not existing. I’m integrating with WPMU instead of regular wordpress but that shouldn’t really cause an issue should it?

    Is there a place we can hardcode it to wp_ instead of bb_?

    #52700

    In reply to: Plugin: Warn users

    veb
    Member

    That about sums it up, sorry I didn’t mention what it actually did. :D

    #52698
    Trent Adams
    Member

    If someone can help me with the code to call the right browser in a plugin, then I will work on the templates needed to show up in the browser. It is just the plugin code and calling /mytemplates/mobile/ for the templates that would be difficult for me!

    Trent

    #52519
    chrishajer
    Participant

    I was able to edit that file and the option is removed when creating a new topic, and old threads will still accept replies.

    Here is the change I made:

    Remove lines 22 through 28:

    <?php if ( is_tag() || is_front() ) : ?>

    <label for="forum_id"><?php _e('Pick a section:'); ?>

    <?php forum_dropdown(); ?>

    </label>

    <?php endif; ?>

    and insert:

    <input type="hidden" name="forum_id" id="forum_id" value="1" />

    so that it looks like this:

    <?php endif; ?>

    <input type="hidden" name="forum_id" id="forum_id" value="1" />

    <p class="submit">

    That assumes your forum_id is 1. You can check the HTML source of your rendered page to verify the forum_id.

    Making those changes worked for me. The drop down for selecting a forum to move a topic is still available for admin.

    #52518
    basinalders
    Member

    I tried that first thing. The problem is that removing that section of the code makes every thread appear “closed” to replies.

    #1122
    veb
    Member

    Hi,

    Heres my first plugin which was pretty much copied from the Avatar plugin, but hey, now I can contribute my 2 cents :) (Thanks to the guy who made that too)

    To install you must open functions.php (in bb-includes, line 1388) and add:

    'sig' => array(0, __('Signature'))

    to the end (before last closing bracket)

    This is the code:

    <?php

    /*

    Plugin Name: Signature

    Author: veb

    Version: 1.0

    */

    function post_sig() { // function to use in page php to get the sig

    if ( get_sig( get_post_author_id() ) )

    echo get_sig( get_post_author_id() );

    }

    function get_sig ( $id ) { //function to return sig lfrom database

    global $bbdb, $bb_current_user;

    $user = bb_get_user( $id );

    $profile_info_keys = get_profile_info_keys();

    if ( $id && false !== $user )

    if ( is_array( $profile_info_keys ) )

    foreach ( $profile_info_keys as $key => $label ) {

    if ( 'sig' == $key )

    return $user->$key;

    }

    }

    ?>

    Save as bb-signature.php in my-plugins.

    Have fun :D

    #52261
    ardentfrost
    Member

    Table creation is automatic. It should install if you navigate to your domain/pm.php or put the message code on your front page.

    #51427

    Hehe … I think I found the bug. You’ve said, you’re using the latest Trac-Version of bbPress?

    Then I think you have to change line 48 of my plugin from

    add_action('init', 'online_update');

    to

    add_action('bb_init', 'online_update');

    then … it should work! (for me it did)

    #52617
    Null
    Member

    Hmm it was part of a larger plugin code, took the part out and put it in the plugins folder and it worked here aswell. Problem must be elswhere with the other plugin code.

    This results in a new question. My plugin has this code and works:

    <?php

    // Get Portal topics

    function get_portal_topics() {

    global $bbdb;

    $pforum_id = 1;

    $number_of_topics = 10;

    return $bbdb->get_results("SELECT * FROM $bbdb->topics WHERE forum_id = $pforum_id ORDER BY topic_time DESC LIMIT 0,$number_of_topics");

    }

    ?>

    But I also want to pull the 1 and the 10 from the database $pforum_id = 1; and $number_of_topics = 10; are now manually done…

    How to do this then?

    #52616

    Ehm … I dont know what’s wrong, I put your code on my site … and it worked. Do all the other plugin-functions work?

    #52615
    Null
    Member

    changed some things it’s now:

    function get_portal_topics() {

    global $bbdb, $bb_table_prefix;

    return $bbdb->get_results("SELECT * FROM $bbdb->topics WHERE forum_id = 1 ORDER BY topic_time DESC LIMIT 0,10");

    }

    Still same error when calling using:

    <?php $portal_topics = get_portal_topics(); ?>

    <?php foreach($portal_topics as $topic) :

    Etc etc

    Error:

    Fatal error: Call to undefined function get_portal_topics()

Viewing 25 results - 31,726 through 31,750 (of 32,431 total)
Skip to toolbar