Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for '+.+default+.+'

Viewing 25 results - 6,526 through 6,550 (of 6,788 total)
  • Author
    Search Results
  • #57617
    chrishajer
    Participant

    If you are getting a blank page, you probably have a syntax problem in one of your template files that’s creating a PHP error, and your host just stops on errors. Try using the default theme and see if things work. If they do, then try looking at the files you modified for a PHP syntax error.

    If you have access to a php error log, you can look there for information too.

    #1852
    #57398
    fel64
    Member

    h2.postform is in /bb-templates/k2/style.css, line 194. It’s stretched like that because it by default takes up the whole width of the parent element, which is Secondary. It is more effective to set the width for Secondary than for the child elements, because the Secondary width will automatically control all the child elements too. :)

    Firebug is an invaluable HTML, CSS and JS debugger. :)

    #1845
    neziniux
    Member

    Hello, i trying to integrate the avatar function. However, when i choose the picture and press Upload, i get a following error message: "The image file does not appear to have been uploaded - did you select an image?"

    The default folder is avatars/ and the default picture shows up too. I even chaged the avatar folder permission to 777 but the message remains the same. Where elese can i change something?

    Thank you.

    Hello,

    I am intergrating BB into WordPress and am hitting a wall.

    When I attempt to go to step three of installation I meet the following text:

    bbPress database error: [Column ‘post_text’ cannot be part of FULLTEXT index]

    CREATE TABLE bb_posts ( post_id bigint(20) NOT NULL auto_increment, forum_id int(10) NOT NULL default ‘1’, topic_id bigint(20) NOT NULL default ‘1’, poster_id int(10) NOT NULL default ‘0’, post_text text NOT NULL, post_time datetime NOT NULL default ‘0000-00-00 00:00:00’, poster_ip varchar(15) NOT NULL default ”, post_status tinyint(1) NOT NULL default ‘0’, post_position bigint(20) NOT NULL default ‘0’, PRIMARY KEY (post_id), KEY topic_id (topic_id), KEY poster_id (poster_id), KEY post_time (post_time), FULLTEXT KEY post_text (post_text) ) TYPE = MYISAM

    1. Created table bb_forums

    2. Created table bb_posts

    3. Created table bb_topics

    4. Created table bb_topicmeta

    5. Created table bb_tags

    6. Created table bb_tagged

    7. Changed type of wp_usermeta.meta_key from varbinary(255) to varchar(255)

    8. Changed type of wp_usermeta.meta_value from longblob to longtext

    9. Changed type of wp_users.user_login from varbinary(60) to varchar(60)

    10. Changed type of wp_users.user_pass from varbinary(64) to varchar(64)

    11. Changed type of wp_users.user_nicename from varbinary(50) to varchar(50)

    12. Changed type of wp_users.user_email from varbinary(100) to varchar(100)

    13. Changed type of wp_users.user_url from varbinary(100) to varchar(100)

    14. Changed type of wp_users.display_name from varbinary(250) to varchar(250)

    15. Added index wp_users UNIQUE KEY user_login (user_login)

    bbPress database error: [Table ‘louise.bb_posts’ doesn’t exist]

    INSERT INTO bb_posts (forum_id, topic_id, poster_id, post_text, post_time, poster_ip, post_status, post_position) VALUES (‘1’, ‘1’, ‘1’, ‘

    First Post! w00t.

    ‘,’2007-05-10 15:35:23’, ‘192.168.2.4’, ‘0’, 1)

    bbPress database error: [Table ‘louise.bb_posts’ doesn’t exist]

    SELECT post_id, poster_id FROM bb_posts WHERE topic_id = 1 AND post_status = 0 ORDER BY post_time

    bbPress database error: [Table ‘louise.bb_posts’ doesn’t exist]

    SELECT * FROM bb_posts WHERE post_id = 0

    Finished!

    I am doing everything to the letter and cannot see what I’m doing wrong…..

    The only things I change to install is the directory titles from:

    wordpress to ‘journal’

    and

    bbpress to ‘message_board’

    Help would be greatly appreciated. As its driving me mental. All of this just so I can have people sign in to both wordpress and bbpress at the same time.

    Thanks

    #57395
    bozzy
    Member

    I’m not sure I get it… here is what my css file looks like:

    /*

    Theme Name: K2 for bbPress

    Theme URI: http://www.linickx.com/blog/archives/253/k2-for-bbpress/

    Description: A port of the famous k2 to bbpress

    Version: 0.01 theta-beta

    Author: Nick [LINICKX] Bettison

    Author URI: http://www.linickx.com

    */

    /*

    Derrived from Bryan Veloso orriginal style sheet that ships with bbpress, added a little style from the sheet availble from http://getk2.com, copyright of that to the people at http://binarybonsai.com !

    */

    /* Globals

    =================================== */

    * { margin: 0; padding: 0; }

    body {

    font: 62.5% ‘Lucida Grande’, Verdana, Arial, Sans-Serif; /* 62.5% sets 1em to about 10px */

    background: #EDEDED;

    color: #444;

    text-align: center;

    margin-bottom: 30px;

    }

    a { color: #27d; text-decoration: none; }

    a:hover { color: #27d; text-decoration: underline; }

    .alt { background: #fff; }

    code { font: 1.0em Monaco, ‘Courier New’, monospace; }

    p { margin-bottom: 1.0em; }

    .left { float: left; }

    .right { float: right; }

    .delete:hover {

    background: #c00;

    color: #fff;

    }

    h1 { font-size: 2em; }

    h2 { font-size: 1.5em; }

    /* Structure

    =================================== */

    #wrapper {

    width: 780px; /* controls the main width of the page, if changed also change #content and .sidebar */

    margin: 0 auto;

    background: white;

    text-align: left;

    }

    #header {

    padding: 0;

    margin: 0;

    position: relative;

    height: 200px;

    background: #3371A3; /* header color default is #3371A3, for images – background-image: url(example.jpg); */

    }

    h1, h2, h3, h4 {

    font-family: ‘Trebuchet MS’, Verdana, Sans-Serif;

    }

    #header h1 {

    font-size: 3em;

    font-weight: bold;

    letter-spacing: -1px;

    margin: 0;

    padding: 75px 0 0 40px;

    }

    #header p { margin-bottom: 0; }

    #header h1 a, #header h1 a:visited { color: #fff; text-decoration: none; }

    #header h1 a:hover, #header h1 a:active{ text-decoration: underline; }

    #main {

    font-size: 1.2em;

    width: 760px;

    margin: 10px auto 25px;

    position: relative;

    }

    .bbcrumb {

    text-transform: uppercase;

    font-size: 0.9em;

    letter-spacing: 1px;

    }

    #footer {

    margin: auto;

    color: #666;

    font-size: 1.0em;

    letter-spacing: 2px;

    text-transform: uppercase;

    padding-top: 10px;

    clear: both;

    text-align: center;

    width: 760px;

    }

    #footer a:link, #footer a:visited { /* more link link color fixes for nav & admin stuff */

    color: #777;

    text-decoration: none;

    font-weight: bold;

    }

    #footer a:hover, #footer a:active {

    color: #000;

    text-decoration: underline;

    font-weight: bold;

    }

    .notice {

    border: 2px solid #4c9545;

    background: #abd8a2;

    color: #4c9545;

    font-size: 1.1em;

    font-weight: bold;

    padding: 10px 15px;

    margin: 0 0 1.1em;

    }

    .notice p { margin-bottom: 0; }

    /* Login Form

    =================================== */

    .login {

    color: #000;

    margin: 10px 40px;

    }

    .login a, .login a:visited { color: #000; text-decoration: none; }

    .login a:hover, .login h1 a:active{ text-decoration: underline; }

    .login p { padding: 0 0 5px; }

    .login label {

    display: block;

    float: left;

    padding-right: 10px;

    }

    .login #submit {

    font-size: 1.2em;

    margin-top: 13px;

    float: left;

    }

    p.login {

    font-weight: normal;

    font-size: 1.2em;

    }

    form.login input {

    margin-top: 3px;

    border: 1px solid #999;

    }

    /* Front Page

    =================================== */

    #front-page #hottags {

    position: absolute;

    top: 0;

    left: 0;

    width: 150px;

    overflow: hidden;

    }

    #front-page #discussions {

    margin-left: 0px;

    width: 500px;

    float: left;

    }

    .frontpageheatmap {

    font-weight: normal;

    line-height: 30px;

    padding-bottom: 10px;

    }

    #front-page #main h2, h2.post-form, #userlogin, #currentfavorites, #register {

    color: #333;

    border-bottom: 1px solid #ddd;

    margin: 0 0 10px;

    padding: 0 0 5px;

    }

    #front-page #discussions ul { padding: 0 0 0 14px; }

    .sticky {

    background: #EDEDED;

    }

    /* Topic Page

    =================================== */

    .infobox {

    border: 1px solid #ccc;

    border-width: 1px 0;

    padding: 1em;

    width: 500px;

    }

    .infobox ul {

    margin: 10px 0 10px 12px;

    padding: 0;

    }

    .infobox ul li { padding-bottom: 3px; }

    #topic-tags {

    border-left: 1px solid #ccc;

    float: right;

    margin-top: -2em;

    padding: 0 1em 1em;

    }

    .nav {

    margin: 15px 0;

    padding: 12px 0;

    }

    .nav span { font-weight: bold; }

    .nav span, .nav a { padding: 6px; }

    #thread {

    background: #eee;

    list-style: none;

    margin: 0 0 0 100px;

    padding: 0;

    width: 500px;

    }

    #thread li {

    padding: 1.5em 1.0em;

    line-height: 1.5em;

    }

    #thread li ol, #thread li ul { margin-left: 40px; }

    #thread li ol li, #thread li ul li { padding: 0; }

    .threadauthor {

    margin-left: -110px;

    overflow: hidden;

    position: absolute;

    width: 95px;

    }

    .threadauthor small { font: 11px Verdana, Arial, Helvetica, sans-serif; }

    .poststuff {

    border-top: 1px dotted #ccc;

    margin: 10px 0 0;

    padding: 5px 0 0;

    font: 10px Verdana, Arial, Helvetica, sans-serif;

    text-transform: uppercase;

    width: 500px;

    }

    .num, #forumlist small {

    font: 11px Verdana,Arial,Helvetica,sans-serif;

    text-align: center;

    }

    .postform {

    background: #fff;

    padding: 1em;

    width: 500px;

    }

    .postform textarea {

    height: 12em;

    margin: 5px 0;

    padding: 5px;

    width: 500px;

    display: block;

    }

    .postform label { display: block; width: 500px;}

    .admin { padding: 10px 0 0; }

    #manage-tags {

    margin: 10px 0;

    list-style: none;

    }

    #manage-tags li {

    float: left;

    width: 200px;

    padding-bottom: 10px;

    }

    .submit { text-align: right; }

    .topiclink { display: block; }

    .topictitle {

    font-size: 26px;

    font-weight: normal;

    display: inline;

    }

    /* Other

    =================================== */

    #content .frontpageheatmap a {

    font-weight: normal;

    text-decoration: none;

    }

    #content .infobox li { margin-bottom: 2px; }

    #content .nav a {

    border: 1px solid #ccc;

    font-weight: normal;

    }

    #content .nav a:hover {

    border: 1px solid #999;

    }

    #content a:visited {

    font-weight: normal;

    }

    #front-search {

    float: right;

    margin-top: -8px;

    }

    #latest td, #forumlist td, #favorites td { padding: 5px 10px; }

    #latest tr:hover, #forumlist tr:hover, #favorites tr:hover { background: #cbd9e4; }

    #latest th, #forumlist th, #favorites th {

    /* border-bottom: 1px solid #aaa; */

    background: #3371A3;

    color: #fff;

    padding: 5px 10px;

    text-transform: uppercase;

    font-weight: bold;

    }

    #latest th a:link, #latest th a:visited, #latest th a:active {

    color:#fff;

    }

    #latest, #forumlist, #favorites {

    background: #f7f7f7;

    margin-bottom: 2em;

    width: 100%;

    }

    .bozo { background: #eeee88; }

    .alt.bozo { background: #ffff99; }

    .deleted { background: #ee8888; }

    .alt.deleted { background: #ff9999; }

    /* Profile Page

    =================================== */

    #profile-menu {

    margin: -35px 0px;

    padding: 0 0 30px 0;

    float:right;

    }

    #profile-menu ul {

    margin: 0;

    padding: 0;

    position: absolute;

    bottom: 0;

    left: 20px;

    width: 90%;

    }

    #profile-menu li {

    display: inline;

    margin: 0;

    }

    #profile-menu,

    #profile-menu li a {

    padding: 5px 15px 6px;

    }

    #profile-menu li a {

    font-size: 1em;

    color: white;

    margin: 0;

    }

    #profile-menu li a:hover {

    background: #333;

    color: #eee !important;

    text-decoration: none;

    }

    #profile-menu li.current a,

    ul.menu li.current a:hover {

    color: #333 !important;

    background: white;

    text-decoration: none;

    }

    #userinfo { margin-top: 10px; }

    #userinfo dt { font-weight: bold; }

    #userinfo dd { margin: 0 0 5px; }

    #useractivity { margin: 15px 0 5px; }

    .user-recent { margin: 0 0 10px; }

    .user-recent ol { margin: 5px 0 0 28px; }

    .user-recent ol li { margin: 0 0 3px; }

    /* Profile Edit

    =================================== */

    fieldset {

    border-top: 3px double #ccc;

    border-bottom: 1px solid #ccc;

    border-left: none;

    border-right: none;

    padding: 10px 0 10px 10px;

    margin-bottom: 15px;

    width: 500px;

    }

    legend {

    font-weight: bold;

    padding: 0 15px;

    }

    fieldset table {

    text-align: left;

    margin: 0 15px;

    }

    fieldset table td { padding: 2px 0; }

    fieldset p {

    font-size: 11px;

    margin: 10px 16px;

    }

    /* further additions by Nick */

    /* this is for my 48 x 48 avatars */

    .post {

    min-height: 60px;

    }

    Can you tell me if it’s right?

    #57194
    fel64
    Member

    Okay, I promise in future I’ll be all mature and responsible and test these things first. Sorry for the inconvenience. This works on my forum now; just copy and paste this into a new plugin file. Then put <?php aposttime(); ?> for default time output, or <?php aposttime( 'DATE FORMAT' ); ?> for your own time formatting.

    <?php
    /*
    Plugin Name: Accurate Post Time
    Plugin URI:
    Description: Outputs an accurate post time in, optionally, your choice of formatting. Use <?php aposttime( 'DATE FORMAT' ); ?> in your template, <a href="http://uk3.php.net/date">date formatted according to PHP standards.</a>
    Author: fel64
    Version: Phi
    Author URI: http://www.loinhead.net/
    */

    function aposttime ( $dtformat = "jS F 'y" ) {
    global $bb_post;
    $aposttime = date( $dtformat, strtotime( $bb_post->post_time ) );
    echo $aposttime;
    }
    ?>

    #56695

    In reply to: Plugin: Avatar Upload

    fel64
    Member

    * added a ‘default avatar image’ option (if you don’t want to use fel64’s identicons — see previous posts in this thread).

    fel – how would you like me to link to the identicon’s plugin? Currently, I’m just linking to your post in this thread.

    IMO identicons make the perfect default avatar and I would like it if you include them or at least make it an option choosable through the admin panel. (If it reassures you, the Identicon creator is happy with this being included as part of such a plugin too.)

    If you don’t want to do that, again IMO this should go into a branch for your plugin (I’d need to update it first). It’s not possible to add this as a plugin so that it will work with yours, nor is it distinct enough to be its own plugin; if not part of the core plugin, I see the only alternatives to be making it a branch or just leaving it here as unofficial hack.

    #56694

    In reply to: Plugin: Avatar Upload

    LMD
    Participant

    Version 0.3 is now available for download from the plugin browser.

    Version 0.3 is not compatible with previous versions, so you will have to go through your templates and make some changes to the template functions (check the Readme file).

    New Features

    * added an ‘Avatar’ tab to the profile menu

    * added a ‘default avatar image’ option (if you don’t want to use fel64’s identicons — see previous posts in this thread).

    * can access just the avatar’s URI for use in other plugins.

    fel – how would you like me to link to the identicon’s plugin? Currently, I’m just linking to your post in this thread.

    Oh and I have hacked together an Über-Avatar plugin which pulls together the various avatar plugins into one ‘api’. It iterates through some logic based on a specified order of preference (set by the admin), checking to see if the user has specified an avatar using each plugin.

    For example:

    Order to check: avatar-upload, bb-avatar. bb-myavatars, identicon

    Has user uploaded an avatar?

    — Yes: Invoke the ‘avatar-upload’ plugin template function and break.

    — No… continue

    Has the user specified an external URL?

    — Yes, invoke ‘bb-myavatar’ template function and break.

    — No… continue

    Has the user got a Gravatar?

    — Yes, invoke ‘bb-myavatars’ template functions and break.

    — No… continue

    Has the user got an identicon?

    — Yes, invoke the same code as ‘avatar-upload’ and break.

    — No. create an identicon and then invoke the ‘avatar-upload’ code.

    It’s not perfect yet though, so no release.

    #57367
    gh3
    Member

    When i had a look at it, it redirected me on install page, but now it redirect me to the blank page.

    It seems that someone using the link have installed it, but it seems no to work… because bbpress on install made a default post, that you can look at: http://nerdsgonewildmagazine.com/forum/topic.php?id=1

    But it is blank too.

    Btw i suggest you first of all to remove the bb_ data on mysql if you are not the man who made the install process.

    Then dunno, it seems that it doesn’t process at all any php command.

    Mhh do you know if your host is linux or win, and if it use php4 or 5?

    ps. do you have any rewrite rule in .htaccess file?

    #1810
    dprice
    Member

    Being both a web nerd and Physics student, I decided it was time for BBpress to meet up with MathML.

    Here’s the steps I took to get it crankin’:

    1. Made a copy of the default ‘kakumei’ template, then renamed the folder ‘physics’, my new template name. I then put a copy of ASCIImath.js in there. This does all the hard work.
    2. Changed the physics/header.php from:
      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
      <html xmlns="http://www.w3.org/1999/xhtml" <?php bb_language_attributes( '1.1' ); ?>>

      to:

      <?xml version='1.0' encoding='iso-8859-1'?>
      <?xml-stylesheet type="text/xsl" href="http://www.w3.org/Math/XSL/mathml.xsl"?>

      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN" "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg-flat.dtd" >

      <html xmlns="http://www.w3.org/1999/xhtml"
      xml:lang="en"
      xmlns:pref="http://www.w3.org/2002/Math/preference"
      pref:renderer="css">

      It’d probably still work if you didn’t bother with this step, but seeing as BBpress is making XML we may as well.

    3. Added <script type="text/javascript" src="<?php echo bb_path_to_url( dirname(__FILE__) . '/ASCIIMathML.js'); ?>"> to physics/header.php – this loads the ASCIIMathML.js javascript and does a majority of the MathML magic.
    4. Opened bb-includes/formattingfunctions.php and edited this:
      function code_trick( $text ) {
      $text = str_replace(array("rn", "r"), "n", $text);
      // $text = preg_replace("|<code>(.*?)</code>|e", "'<code>' . encodeit('$1') . '</code>'", $text);
      // $text = preg_replace("|n<code>(.*?)</code>|se", "'<pre><code>' . encodeit('$1') . '</code></pre>'", $text);
      return $text;
      }

      To turn off the backtick code replacement – this is what ASCIIMath.js does!

    That was it. I’ll zip it all up then post it up here. Ideally, it’d be better to not comment out any of the bb-include/ files – if anyone has any suggestions, let me know.

    #56961
    Vili
    Participant

    Ok, here’s what I have, commented. The comments that start with “VILI” are mine.

    Please keep in mind two things:

    a) This is strictly speaking a WordPress plugin, not a bbPress one. The functionality is simply extended to also cover an integrated bbPress installation. (And yes, this means that you need to install this in your WordPress, not your bbPress.)

    b) I hacked this for my own purposes, so it may not be pretty, and it certainly won’t be ready for use without you reading through the code. If someone is interested in working to make it functional as an “out of the box” solution, then by all means go ahead.

    Finally, the original Dan’s Avatar Thingy can be found here.

    <?php
    /*
    Plugin Name: Vili's Avatar Thingy
    Plugin URI: http://www.vertebratesilence.com/
    Description: Displays an avatar next to posts or comments based on username. Based on Dan's Avatar Thingy (http://www.cheesemasterdan.com/).
    Version: 0.1
    Author: Vili Maunula
    Author URI: http://www.vertebratesilence.com/
    */

    // Variable declarations
    // VILI: These were changed from Dan's Avatar Thingy, in which you only had default
    // size settings into which all avatars were resized.

    $avatar_max_width = 100; // Max avatar width
    $avatar_max_height = 100; // Max avatar height
    $avatar_max_upload_size = 15360; // Max file size in bytes
    $avatars_path = ABSPATH."wp-content/avatars";

    function cmd_show_avatar()
    {
    global $wpdb;
    global $avatars_path;

    // VILI: The following is a boolean setting I use to detect whether the page
    // being served is a forum page. In practice, I have
    // <?php global $forumpage;
    // $forumpage = TRUE; ?>
    // at the beginning of each forum page (I use WordPress headers in my integrated
    // setup, but if your bbPress uses its own headers, just stick it there). If
    // anyone knows a more cost-efficient way of detecting whether a page shown is
    // a forum page, let me know.
    global $forumpage;

    if ($forumpage == FALSE) {
    $the_author_name = get_comment_author();
    if($the_author_name == "" or $the_author_name == __('Anonymous'))
    { // Avatar for posts
    $the_author = get_the_author_id();
    $the_author_name = get_the_author();
    } else { // Avatar for comments - only for registered users
    $the_comment_ID = get_comment_ID();
    $the_author = $wpdb->get_var("SELECT user_ID FROM $wpdb->comments WHERE comment_ID='$the_comment_ID'");
    }
    } else {
    $the_author_name = get_post_author();
    $the_author = get_post_author_id();
    }

    $image_path = get_bloginfo('wpurl')."/wp-content/avatars/";
    $the_avatar = $image_path.$the_author.".jpg";
    if(file_exists("$avatars_path/$the_author.jpg"))
    {
    echo '<img src="' . $the_avatar. '" alt="' . $the_author_name . '" class="cmd-avatar" />';
    } elseif(file_exists("$avatars_path/default.jpg")) {
    echo '<img src="' . $image_path . 'default.jpg" alt="Unregistered" class="cmd-avatar" />';
    }
    // If the file doesn't exist then return nothing...
    }

    add_action ('admin_menu', 'cmd_avatar_menu');

    function cmd_avatar_menu()
    {
    add_submenu_page('profile.php', '', 'Your Avatar', 0, __FILE__, 'cmd_avatar_profile');
    }

    function cmd_avatar_profile()
    {
    global $userdata;
    global $avatar_max_width;
    global $avatar_max_height;
    global $avatar_max_upload_size;
    global $avatars_path;
    get_currentuserinfo();

    if(!file_exists($avatars_path))
    {
    $mkdir_result = @mkdir($avatars_path, "0755");
    if(!$mkdir_result)
    {
    echo '<div id="message" class="error fade">The folder' . $avatars_path . ' does not exist and could not be created automatically. Please create it and assign 0755 permissions then try using this plugin again.
    </div>';
    die();
    }
    }

    if ($_POST['cmd_action'] == 'upload_avatar')
    {
    if ($_FILES['cmd_avatar_file']['size'] > 0 && $_FILES['cmd_avatar_file']['size'] < $_POST['MAX_FILE_SIZE'])
    {
    $uploaddir = ABSPATH."wp-content/avatars/";
    $uploadfile = $uploaddir . $userdata->ID . '.jpg';
    list($width, $height, $type, $attr) = getimagesize($_FILES['cmd_avatar_file']['tmp_name']);

    // VILI: The following calculates the size into which the
    // image needs to be put. If it's under the MAX limits, nothing
    // is done, otherwise resizing takes place. This probably
    // could be written more elegantly.

    $widthratio = $width / $avatar_max_width;
    $heightratio = $height / $avatar_max_height;
    if ($widthratio > 1 && $heightratio > 1 && $widthratio > $heightratio) {
    $usewidth = $width / $widthratio;
    $useheight = $height / $widthratio;
    } elseif ($widthratio > 1 && $heightratio > 1 && $widthratio < $heightratio) {
    $useheight = $height / $heightratio;
    $usewidth = $width / $heightratio;
    } elseif ($widthratio > 1) {
    $usewidth = $width / $widthratio;
    $useheight = $height / $widthratio;
    } elseif ($heightratio > 1) {
    $useheight = $height / $heightratio;
    $usewidth = $width / $heightratio;
    } else {
    $usewidth = $width;
    $useheight = $height;
    }

    $cmd_avatar_image = imagecreatetruecolor ($usewidth, $useheight);
    switch ($type)
    {
    case 1: // GIF
    $image = imagecreatefromgif($_FILES['cmd_avatar_file']['tmp_name']);
    imagecopyresampled($cmd_avatar_image, $image, 0, 0, 0, 0, $usewidth, $useheight, $width, $height);
    $avatar_created = (imagejpeg($cmd_avatar_image, $uploadfile, 100) ? TRUE : FALSE);
    imagedestroy($image);
    imagedestroy($cmd_avatar_image);
    break;
    case 2: // JPEG
    $image = imagecreatefromjpeg($_FILES['cmd_avatar_file']['tmp_name']);
    imagecopyresampled($cmd_avatar_image, $image, 0, 0, 0, 0, $usewidth, $useheight, $width, $height);
    $avatar_created = (imagejpeg($cmd_avatar_image, $uploadfile, 100) ? TRUE : FALSE);
    imagedestroy($image);
    imagedestroy($cmd_avatar_image);
    break;
    case 3: // PNG
    $image = imagecreatefrompng($_FILES['cmd_avatar_file']['tmp_name']);
    imagecopyresampled($cmd_avatar_image, $image, 0, 0, 0, 0, $usewidth, $useheight, $width, $height);
    $avatar_created = (imagejpeg($cmd_avatar_image, $uploadfile, 100) ? TRUE : FALSE);
    imagedestroy($image);
    imagedestroy($cmd_avatar_image);
    break;
    default:
    $avatar_created = FALSE;
    break;
    }
    if ($avatar_created) {
    echo '<div id="message" class="updated fade">File uploaded successfully.
    </div>';
    } else {
    echo '<div id="message" class="error fade">File upload failed.
    </div>';
    }
    }
    }
    echo '
    <div class="wrap">
    <h2>Your Avatar</h2>
    <form name="cmd_avatar" id="your-profile" action="' . $PHP_SELF . '" method="post" enctype="multipart/form-data">
    <fieldset>
    <legend>Avatar</legend>';

    $the_user = $userdata->ID;

    $avatars_path = ABSPATH."wp-content/avatars";
    $image_path = get_bloginfo('wpurl')."/wp-content/avatars/";
    $the_avatar = $image_path.$the_user.".jpg";

    if(file_exists("$avatars_path/$the_user.jpg")){
    echo '
    <img src="' . $the_avatar . '" alt="' . $userdata->user_login . '" class="cmd-avatar">';
    } else {
    echo 'No avatar found...';
    }
    echo '

    <label>Filename: </label>
    <input type="file" accept="Pictures" name="cmd_avatar_file" />

    <input type="hidden" name="MAX_FILE_SIZE" value="' . $avatar_max_upload_size . '" />
    <input type="hidden" name="cmd_action" value="upload_avatar" />
    Click browse to find your avatar image. It can be JPG, GIF or PNG and should be ' . $avatar_max_width . ' x ' . $avatar_max_height . ' pixels or less (if bigger, it will be resized).Images should also be no larger than ' . $avatar_max_upload_size / 1024 . 'KBCurrently animated GIFs are not supported.
    </fieldset>
    <br clear="all" />
    <p class="submit">
    <input type="submit" name="cmd_avatar_update" value="Update Profile &raquo;" />

    </form>
    </div>';
    }

    ?>

    #55004
    Trent Adams
    Member

    I will take a look and play around to have it working with the default install again, np!

    Trent

    #1785
    wittmania
    Member

    Version 1.0

    This plugin automatically turns scripture references into links that will take the visitor to BibleGateway.com, where they can view the verse(s). The administrator can set the default version to one of more than a dozen available versions, including ESV, NIV, KJV, NASB, The Message, and so on.

    The links are created dynamically each time a topic is loaded, so the actual text of the post is left alone. This is nice because it allows you to disable/delete the plugin without having to go back through and edit your posts to remove the extra markup.

    This plugin is ideal for forums that are religious/spiritual in nature, as it will save your users a lot of time from having to hard-code links to passages they reference in their posts.

    This plugin is almost entirely based on a similar WordPress plugin that does the same thing to WP posts. You can view the WP plugin here:

    http://dev.wp-plugins.org/wiki/Scripturizer

    You can read more about the plugin, or download the latest version of bb-Scripture-Links, here:

    http://blog.wittmania.com/bb-scripture-links

    You can see a working demo here:

    http://blog.wittmania.com/bbpress/topic/2

    #57219
    cpjolicoeur
    Member

    so, I looked in the bb-templates/kakumei/post-form.php file and it is completely blank???

    is this correct or should there be an edit form in this file?? This is the default theme included in the bbpress installation and i havent edited the file at all

    #57181

    In reply to: custom roles?

    fel64
    Member

    No problem. Are you using the default theme? That should certainly show a changed user title. Have you checked the database to see if it’s there? You would use phpMyAdmin to look into the usermeta table (look for the ID of that particular user).

    #57136
    benbeltran
    Member

    yeah :O it should … li uses display:list-item and uses different properties … like line-height instead of height and it behaves differently in some contexts.

    In some cases using the default display mode it would overlap with other items, but with display:block; it stretches properly

    #56881

    In reply to: Outlet

    fel64
    Member

    In MCE it always assumes the next paragraph to be b-quoted too, unless you specify otherwise. I think it’s default behaviour.

    You could probably modify the Quote plugin so that instead of returning <blockquote> quoted stuff </blockquote> it attached a newline character or two. Something like <blockquote> quoted stuff </blockquote>nn might be enough as a modification, I’m not sure. MCE should interpret the two new lines as a new paragraph, hopefully without blockquotage.

    #56880

    In reply to: Outlet

    AphelionZ
    Participant

    It’s a hard problem to explain – if you go into a thread and quote somebody, it shows up in the MCE as <blockquote> quote </blockquote>

    In the editor, it kind of locks you into blockquote mode – first, the quote is indented, which isnt so much of a problem as it is just a display discrepancy as the quotes aren’t indented in posts..

    however, when you hit return, the next paragraph shows up as a new blockquote and doesnt default back to plain text inside the editor, and you have to hit tinyMCE’s ‘outdent’ button.

    More or less a pain, but one that might get people to stop posting :(

    #57176

    In reply to: Display Username

    fel64
    Member

    <?php echo bb_get_current_user_info( 'name' ); ?>

    Drop that into HTML wherever you want it. :)

    The default theme puts a “Welcome, USER! View your profile (Log out)” at the top left of every page, right where the login box would be otherwise.

    Edit: strange, is the overflow: hidden property gone again?

    #56151
    eddd54
    Member

    Hi,

    i’m having the same problem with my WordPress and bbPress integrated install – (href tags getting stripped and extra slashes getting added)

    See here: https://bbpress.org/forums/topic/641 and here: https://bbpress.org/forums/topic/670

    I’m running:

    WordPress 2.1.3

    bbPress 1.0-alpha

    The 2 fixes worked for me but rather than editing the bb-includes/default-filters.php file.. i put the temporary fixes in a quick bbPress Plugin so that i don’t end up forgetting about the modifications after an upgrade and can now easily deactivate the plugin should this issue get permenantly resolved.

    I put the plugin up online. If you’re interested, you can download it here: http://indyish.googlepages.com/fix-href-slashes.php

    Sam Bauers
    Participant

    Can you create a ticket for this here. You can login with the same user/pass you use on this forum.

    Sjon
    Member

    Hope this is the right place. I just installed the latest svn version on my local pc, and got the forementioned error twice (also with topic_slug field). Running mysql 5.0.

    Patch:

    Index: upgrade-schema.php
    ===================================================================
    --- upgrade-schema.php (revision 805)
    +++ upgrade-schema.php (working copy)
    @@ -4,7 +4,7 @@
    $bb_queries = "CREATE TABLE $bbdb->forums (
    forum_id int(10) NOT NULL auto_increment,
    forum_name varchar(150) NOT NULL default '',
    - forum_slug text NOT NULL default '',
    + forum_slug text NOT NULL,
    forum_desc text NOT NULL,
    forum_parent int(10) NOT NULL default '0',
    forum_order int(10) NOT NULL default '0',
    @@ -31,7 +31,7 @@
    CREATE TABLE $bbdb->topics (
    topic_id bigint(20) NOT NULL auto_increment,
    topic_title varchar(100) NOT NULL default '',
    - topic_slug text NOT NULL default '',
    + topic_slug text NOT NULL,
    topic_poster bigint(20) NOT NULL default '0',
    topic_poster_name varchar(40) NOT NULL default 'Anonymous',
    topic_last_poster bigint(20) NOT NULL default '0',

    Regards,

    #56689

    In reply to: Plugin: Avatar Upload

    fel64
    Member

    Now if only there was a way to display a default image if the user hasn’t uploaded one.

    That’s the point of the identicon jobbie, it assigns everyone a unique and easily distinguishable image when they sign up. :)

    Louisedade, bb_init is called before bb_head I think. In your avatar.php template file it should also be class="bbcrumb" rather than id="breadcrumb", at least if you want the same styling as everything else.

    #56686

    In reply to: Plugin: Avatar Upload

    smurfdude
    Member

    W00t! I’ve figured out how to display the avatar next to comments in wordpress. Though the way I have done it i’m worried it’s going to cause problems.

    Now if only there was a way to display a default image if the user hasn’t uploaded one. Not that it’s a big deal. Thanks :D

Viewing 25 results - 6,526 through 6,550 (of 6,788 total)
Skip to toolbar