It's 0:04 AM here so... woot! Happy new year!!!
352 2008-12-31 20:58
Re: BBcode in RSS feeds (12 replies, posted in PunBB 1.3 discussion)
I think you should get rid of the BBCode instead. Having HTML inside the RSS is not a good idea.
My regex skills are not very good, but you could try something like:
$cur_post['message'] = preg_replace("/\[([a-z0-9*]+)([^\[]+?)?\]([^\[]+?)\[(\/[a-z0-9*]+)\]/i", '$3', $cur_post['message']);
On line 335.
353 2008-12-31 20:28
Re: How to turn off brd crumbs EITHER at top or bottom (12 replies, posted in PunBB 1.3 discussion)
On Line 277 of header.php you can disable top breadcrumbs by adding "//" at the beginning of the line.
Line 280 for the bottom breadcrumbs.
354 2008-12-31 18:19
Re: text/xml is deprecated (15 replies, posted in PunBB 1.3 discussion)
How could the script know if the client accepts application/rss+xml (or atom, etc)?
355 2008-12-31 16:04
Re: text/xml is deprecated (15 replies, posted in PunBB 1.3 discussion)
Do you approve this code?
if(empty($_SERVER['HTTP_ACCEPT']) || !in_array('application/xml', explode(',', $_SERVER['HTTP_ACCEPT']))
//No HTTP_ACCEPT header or no application/xml support, use text/xml
else
//We can use application/xml
About application/rss+xml: http://duncanmackenzie.net/blog/applica … fault.aspx
I know the article is really old, but Wikipedia still shows "(Registration Being Prepared)" for the MIME type.
356 2008-12-31 15:35
Re: [Tutorial] Show PunBB info in Wordpress (16 replies, posted in PunBB 1.3 additions)
Yes, works on WP 2.2 and later.
357 2008-12-31 14:16
Re: text/xml is deprecated (15 replies, posted in PunBB 1.3 discussion)
So... RSS and Atom - application/xml and XML - text/xml? I'll commit the changes to SVN depending on your answers
358 2008-12-30 22:43
Re: Comment moderation (4 replies, posted in PunBB 1.2 modifications, plugins and integrations)
I think he wants to know where the moderation control panel is?
359 2008-12-30 21:25
Re: [request] Last 20 topics on first page (7 replies, posted in PunBB 1.3 extensions)
is it anyhow possible to put latest 10 active topics on wordpress index?
Yes, here's how.
360 2008-12-30 21:24
Topic: [Tutorial] Show PunBB info in Wordpress (16 replies, posted in PunBB 1.3 additions)
Things you need
PunBB 1.3.2 Installation
Wordpress 2.2.1+ Installation
Preparation: Install the "Widgetize Anything" Plugin
Download the plugin.
Extract its contents (a folder called "widgetize-anything") into 'wp-content/plugins/'.
Go to Plugins on your Wordpress dashboard.
Install the plugin.
Widgetize Anything: Adding more widgets
Go to Settings/Options»Widgetize Anything on your Wordpress dashboard.
Change the number to your needs.
Update the options.
Steps
Go to Appearance»Widgets (depends on your WP version) and add the "Widgetize Anything (number)" widget to your sidebar.
Edit the "Widgetize Anything (number)" widget.
Set the widget title to your liking.
If you want to show the forum's active topics, paste Code 1 into the text box. If you want to show how many online users there are, paste Code 2. If you want to show your board stats, paste Code 3.
Replace '{replace_this}' with the relative URI to your PunBB installation. See Example 1.
Save the changes.
Code 1:
$show = '10'; //How many active topics we want to show
define('FORUM_ROOT', '{replace_this}');
echo '<ul>';
echo file_get_contents(FORUM_ROOT . '/extern.php?show=' . $show);
echo '</ul>';
Code 2:
define('FORUM_ROOT', '{replace_this}');
echo '<ul>';
echo file_get_contents(FORUM_ROOT . '/extern.php?action=online');
echo '</ul>';
Code 3:
define('FORUM_ROOT', '{replace_this}');
echo '<ul>';
echo file_get_contents(FORUM_ROOT . '/extern.php?action=stats');
echo '</ul>';
Example 1:
You have Wordpress installed in www.example.com and PunBB on www.example.com/forums/. Your relative URI to PunBB will then be "./forums". If Wordpress is installed on www.example.com/blog/ and www.example.com/forums/, your relative URI to PunBB will be "../forums"
Advanced users:
Read the instructions found inside 'extern.php', edit the following code to your liking and use it on step 4.
$variables = ''; //Example: action=feed&fid=1&show=30
define('FORUM_ROOT', '{replace_this}');
echo '<ul>';
echo file_get_contents(FORUM_ROOT . '/extern.php?' . $variables);
echo '</ul>';
I hope you understood my messy tutorial
361 2008-12-30 18:07
Re: Need ideas (22 replies, posted in PunBB 1.3 extensions)
Ok, I'll start working on that sometime after new year. I got lots of stuff to do
362 2008-12-30 18:01
Re: Need ideas (22 replies, posted in PunBB 1.3 extensions)
No no, I meant to ask if that looks good. A white box under the post with all attached images.
And yes, the images will be stored in the local server.
364 2008-12-30 15:41
Re: Problem installing on local server: Chmod (11 replies, posted in PunBB 1.3 troubleshooting)
Create a new PHP with:
<?php
var_dump(chmod('./cache', 0777));
echo "<br />";
var_dump(chmod('./img/avatars', 0777));
?>
and save it on your PunBB root by the name of 'chmod.php', then use your browser to open it (once it's uploaded to your server).
You should see:
bool(true)
bool(true)
If not, something else is wrong...?
365 2008-12-30 04:21
Re: Need ideas (22 replies, posted in PunBB 1.3 extensions)
I don't know about specific changes on the CSS, but I could probably make an extension that will allow you to edit your styles (as text) from within PunBB (kinda like Wordpress does), without having to upload with FTP to your server and all that hassle.
Is that good?
366 2008-12-30 04:17
Re: [Release] Improved Smilies System (31 replies, posted in PunBB 1.3 extensions)
I'll post a screenshot right away.
That link I posted on top is the latest PunBB 1.3.2. It's a "nightly build" of PunBB, of a sort.
Btw, I love the Nissan Skyline GTR, I use it on NFS: Undercover
367 2008-12-29 16:14
Re: [Release] Improved Smilies System (31 replies, posted in PunBB 1.3 extensions)
That's really weird... the uninstall doesn't pass the $ext_info variable. I think this is a bug...
Edit: Fixed.
368 2008-12-29 01:13
Topic: [Release] Improved Smilies System (31 replies, posted in PunBB 1.3 extensions)
This extension needs at least rev1002 of PunBB 1.3 from SVN found here.
Integrates an improved smilies system.
You can manage your smiley sets on Administration » Settings » Smilies
Download Link: http://punbb.informer.com/unofficial/pu … milies.zip
Screenshot:
If you find any bugs or have any tips, please post them here.
Updates
1.0: First release
370 2008-12-28 22:45
Re: [release] show latest registrations (6 replies, posted in PunBB 1.3 extensions)
Why only admins? Anyone can just go to (i.e.) http://punbb.informer.com/forums/userli … t_dir=DESC and get the same list.
371 2008-12-28 00:15
Re: Spoiler Mod for 1.3.2,it's possible? (4 replies, posted in Feature requests)
It is.
372 2008-12-28 00:13
Re: Bosnian language please. (6 replies, posted in PunBB 1.3 additions)
What do you mean fix? You can't write those characters on the lang files?
373 2008-12-27 14:57
Re: Time Stamp in the format "3 days ago" or "2 hours ago" (10 replies, posted in Feature requests)
$base = gmdate('Y-m-d', $timestamp);
$today = gmdate('Y-m-d', $now + $diff);
$yesterday = gmdate('Y-m-d', $now + $diff - 86400);
if ($base == $today)
$formatted_time = $lang_common['Today'];
else if ($base == $yesterday)
$formatted_time = $lang_common['Yesterday'];
374 2008-12-27 10:55
Re: PunBB 1.3.2 (27 replies, posted in News)
Well, how would it know who to show the link to? If it showed it only to the IP stored on your admin's account, it could make fixing your forum nearly impossible if your IP changes.
375 2008-12-26 17:18
Re: Time Stamp in the format "3 days ago" or "2 hours ago" (10 replies, posted in Feature requests)
Oh... I forgot a line from the code! I edited the code. It should work now.