Search Results for 'code'
-
AuthorSearch Results
-
October 16, 2006 at 9:04 am #49755
In reply to: Problems after installation
jazzle
MemberThis is probably because you have have
$bb->mod_rewrite = true;but no.htaccessfile.Have a look at https://bbpress.org/forums/topic/13
October 16, 2006 at 9:01 am #49461In reply to: Are there any localization files?
Elad Salomons
MemberPotter_System – your update did the trick – thanks
October 16, 2006 at 3:21 am #49585In reply to: Emoticons For bbPress?
gnawph
MemberI wanted that functionality as well so I ripped some WP code, played around, and finally got something I could use. This is a highly sloppy work as I am out of practice and not really a great PHP programmer anyway. The plugin is mostly a rip of the WordPress code with a filter. It is not elegant or tested completely but so far it has been getting the job done.
Note: This plugin will not work without a default install of WordPress.
You have to create a directory called /my-plugins/, copy this code into a file called whatever-you-want.php, upload and enjoy!
Feedback appreciated! Maybe I can improve on this and increase my PHP/*press skills.

<?php/*
Plugin Name: WordPress Smiley Integrator .0002
Plugin URI: none
Description: Gives WordPress Smiley Functionality to bbPress
Author: John Farrell
Version: 1.0
Author URI: none
*/
function convert_smilies($text) {
$wpsmiliestrans = array(
':mrgreen:' => 'icon_mrgreen.gif',
':neutral:' => 'icon_neutral.gif',
':twisted:' => 'icon_twisted.gif',
':arrow:' => 'icon_arrow.gif',
':shock:' => 'icon_eek.gif',
':smile:' => 'icon_smile.gif',
'
??:' => 'icon_confused.gif',':cool:' => 'icon_cool.gif',
':evil:' => 'icon_evil.gif',
':grin:' => 'icon_biggrin.gif',
':idea:' => 'icon_idea.gif',
':oops:' => 'icon_redface.gif',
':razz:' => 'icon_razz.gif',
':roll:' => 'icon_rolleyes.gif',
':wink:' => 'icon_wink.gif',
':cry:' => 'icon_cry.gif',
':eek:' => 'icon_surprised.gif',
':lol:' => 'icon_lol.gif',
':mad:' => 'icon_mad.gif',
':sad:' => 'icon_sad.gif',
'
' => 'icon_cool.gif','8-O' => 'icon_eek.gif',
'
' => 'icon_sad.gif','
' => 'icon_smile.gif','
' => 'icon_confused.gif','
' => 'icon_biggrin.gif','
' => 'icon_razz.gif',':-o' => 'icon_surprised.gif',
':-x' => 'icon_mad.gif',
'
' => 'icon_neutral.gif','
' => 'icon_wink.gif','
' => 'icon_cool.gif','8O' => 'icon_eek.gif',
'
' => 'icon_sad.gif','
' => 'icon_smile.gif','
' => 'icon_confused.gif','
' => 'icon_biggrin.gif','
' => 'icon_razz.gif',':o' => 'icon_surprised.gif',
':x' => 'icon_mad.gif',
'
' => 'icon_neutral.gif','
' => 'icon_wink.gif',':!:' => 'icon_exclaim.gif',
'
:' => 'icon_question.gif',);
// generates smilies' search & replace arrays
foreach($wpsmiliestrans as $smiley => $img) {
$wp_smiliessearch[] = $smiley;
$smiley_masked = htmlspecialchars( trim($smiley) , ENT_QUOTES);
$wp_smiliesreplace[] = " <img src='/wp-includes/images/smilies/$img' alt='$smiley_masked' class='wp-smiley' /> ";
}
$output = '';
// HTML loop taken from texturize function, could possible be consolidated
$textarr = preg_split("/(<.*>)/U", $text, -1, PREG_SPLIT_DELIM_CAPTURE); // capture the tags as well as in between
$stop = count($textarr);// loop stuff
for ($i = 0; $i < $stop; $i++) {
$content = $textarr[$i];
if ((strlen($content) > 0) && ('<' != $content{0})) { // If it's not a tag
$content = str_replace($wp_smiliessearch, $wp_smiliesreplace, $content);
}
$output .= $content;
}
return $output;
}
//add the filter
add_filter('post_text', 'convert_smilies');
?>
October 16, 2006 at 2:37 am #49723In reply to: installing … error
chaaban
Memberno it cant be this because i used the same folder on both , 1 worked great but it was on root the other dident work because it wasnt on root …
is there any error in those 2 lines ?
$bb->domain = ‘http://www.thai-boxing.org’;
$bb->path = ‘/muay-thai-forum/’;
if i’m installing it on a folder called : muay-thai-forum ?
here is what i will make to make it easy on my self , i will take the exported .sql database of the bbpress that worked and install it and see what it will do … i’ll let u updated

thank’s
October 16, 2006 at 1:37 am #678Topic: Using WP template tags
in forum ThemesVicente Ruiz Gálvez
ParticipantCan I use my own WP template tags (or functions) into the bb templates?
I tried to add
require_once('http://www.mydomain.com/wp-config.php');into the config.php file, but don’t work.If I add
require_once('../wp-config.php');, it works, but crash the bb-admin panel.Can anyone help me?
October 16, 2006 at 12:24 am #49460In reply to: Are there any localization files?
potter_system
Memberlstelie: The Views links’ names are used in another place (view.php), so at this time it’s difficult. I think it’s possible to add another array value to make the names get-text-able, or even use the values the array currently have for next version
== Update ==
BTW, if you don’t want to wait, you can replace the
echo $viewin your front-page.php file withecho $titleOctober 15, 2006 at 10:15 pm #49404In reply to: Importing from phpBB
spencerp
MemberThanks for sharing that Detro, the thought saving the PMs is important as well, now if *only* there was a way to grab ALL of the informations from a phpBB board, that’d be awesome.
If no one around here can do one up, I’ll see if I can get *someone* I know, to do it..
spencerp
October 15, 2006 at 9:23 pm #49721In reply to: installing … error
chaaban
Memberthis is so sick , i tried to install it on another website on the root and it work , but when installing on a sub directory it dont

ahhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
i feel better now
October 15, 2006 at 8:14 pm #49458In reply to: Are there any localization files?
Elad Salomons
Memberlstelie,
These strings are hard-coded in:
bb-includes/functions.php
line 1394:
$views = array(‘no-replies’ => __(‘Topics with no replies’), ‘untagged’ => __(‘Topics with no tags’), ‘unresolved’ => __(‘Unresolved topics’));
Just translate them in the code and you are done
October 15, 2006 at 4:49 pm #49565In reply to: No .htaccess file for “pretty” URLS?
bpartch
MemberI did the “bb-admin/rewrite-rules.php” and all is fine except the “tags” links give me a internal server error.
ergate yours seems to work perfectly.
October 15, 2006 at 1:15 pm #49449In reply to: Are there any localization files?
Elad Salomons
MemberYou need to translate the po file (see 4 messages above). Then the mo file should go to bb-includes/languages.
But… I could not get it to work
October 15, 2006 at 12:48 pm #671Topic: Can’t Login!
in forum Troubleshootingastereo
MemberI seem to be having trouble logging in at all in bbpress. I integrated it successfully with WordPress, but I can’t login with my wordpress user name and password. I figured, something must be up, so I registered a new account in bbpress to try it out – password was mailed and everything – and when I went to login, still nothing. The page refreshes but goes nowhere and doesn’t say I’m logged in. Seems like a mod rewrite issue, but I can’t figure out what it is. During the initial install I set the config to clean urls, then used an .htaccess like the following:
# BEGIN BBPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /location_of_install/
Options +MultiViews
</IfModule>
# END BBPress
After doing so I kept getting 404’s when clicking on topics, etc (only to find out later I needed to fix my url at the beginning of config). Now everything is working except logins. Any ideas?
October 15, 2006 at 3:11 am #49562In reply to: No .htaccess file for “pretty” URLS?
Aaron
ParticipantThis is what I am using
# BEGIN BBPress<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /location_of_install/
Options +MultiViews
</IfModule>
# END BBPress
October 15, 2006 at 2:39 am #49675In reply to: Akismet key
kyte
MemberAhhhh so it actually requires quote marks. Well I am no php person so I did not realise that. Thanks, Jeremy
October 15, 2006 at 2:38 am #49669In reply to: Changing the style.css file
kyte
Memberarghhhh! I had actually already posted here (well I thought I had) to say I needed new specs because I had not noticed that I had uploaded the altered style.css to the admin directory (god knows why, I must have looked in there for something and forgotten to select the templates dir afterwards.).
anyway, all is well now.
Thanks for your reply
October 15, 2006 at 2:03 am #49674In reply to: Akismet key
JeremyVisser
MemberThis is due to a PHP syntax error. My Akismet line looks like this:
$bb->akismet_key = "12345678";(key censored)October 14, 2006 at 10:12 pm #49522In reply to: Installation to sub domain Error 400
Matt Mullenweg
KeymasterThe path is for the URL.
So if
forums.example.comispublic_html/forums/on your server, you still just want/to be your path because when you load it in a browser it’s:http://forums.example.com/.October 14, 2006 at 9:06 pm #49402In reply to: Importing from phpBB
spencerp
MemberI just had a chat with Patrick on Live Messenger, the guy that runs phpBBhacks.com , and he said, you’ll mostly have to work directly with the database.
Or atleast that’s how he does it, he said. Also, I’m not sure if this would, or could possibly help in any way, but.. they wrote up this article: “Write a converter with the Unified Convertor System.”
Of course, like anyone would do, they made it up for the people to convert from their current forum software, to their’s, but, wasn’t sure if maybe you devs could use it to benefit yourselves or not?
Just wanted to throw this out onto the table for ya’ll..
I think it’s great that bbPress made a official release finally.. and *hopefully* soon, I’ll get to making themes for it.
spencerp
/Sidenote quick: I had dealt with phpBB before, for a few good years, installed it for peoples, for money, and shot out a few themes too. Submitted them to the phpBBhacks.com site, and had patrick in the MSN mess list for a few years..
October 14, 2006 at 6:36 pm #49520In reply to: Installation to sub domain Error 400
Michael Adams (mdawaffe)
MemberWhat is the url you’re tring to install it to?
http://subdomain.domain.com/forums/?If that’s the case, you need to install bbPress in the directory on your server that that url points to. You config should then look like:
$bb->domain = 'http://subdomain.domain.com';$bb->path = '/forums/';October 14, 2006 at 1:36 pm #49444In reply to: Are there any localization files?
Elad Salomons
MemberCan you please send me the po file:
selad at optiwater dot com
thanks
October 14, 2006 at 12:57 pm #49442In reply to: Are there any localization files?
Elad Salomons
MemberSteveAgl,
What exactly did you enter in the config file?
If you do get it to work please post here how.
Thanks
October 14, 2006 at 10:25 am #49441In reply to: Are there any localization files?
Stefano Aglietti
MemberI generated a it_IT.mo files with few strings translated (mostly from the templates) and tried to set define (‘WPLANG’, ‘it_IT’); in config file using BBLANG and WPLANG that seem used in the code, but the strings wont’ get translated… why?
October 14, 2006 at 8:07 am #49439In reply to: Are there any localization files?
Elad Salomons
MemberJust one more quick one: how many strings are still hard coded into bbPress?
October 14, 2006 at 7:02 am #49433In reply to: *sigh* installation error
shinka
MemberThanks guys.
October 14, 2006 at 6:54 am #49397In reply to: New bbPress Forums
winnopeg
MemberPlugins? Awesome, now I really, really want to get using this.
-
AuthorSearch Results