Okies, solved. To get the prev_url to work properly also forum footer.php is required. After adding this, you can use for instance a direct login link in your own custom pages that leads to PunBB login page and you'll get redirected to that custom page after login. smile

require FORUM_ROOT.'footer.php';

This post lead me to the right track, still not getting this to work. I believe set_default_user() is the answer but why I can't get it to update the prev_url column on the online table when I call it from my custom pages? hmm

It does update the $forum_user['prev_url'] array but doesn't update the online table in the database, what am I missing here?

My site structure is the following if it makes a difference:
/forum/ (here's PunBB)
/section1/ (here's a custom page that queries PunBB db located in the forum dir)
/section2/ (here's another custom page that queries PunBB db located in the forum dir)
etc.

Using set_default_user() I got the prev_url variable to update correctly outside the forum too but as soon as I go to login the variable is replaced and after login I get redirected to forum index again.

Have to correct that, the issue is that only the array gets updated as descriped above, not the online table in the db so after I locate to the login.php the hidden redirect_url is fetched from the db table which has the old referer/prev_url.

Edit: The code I'm using on the custom pages is here:

// Integrate PunBB
define('FORUM_ROOT', '../forum/');
require FORUM_ROOT.'include/common.php';

// Set prev url for redirecting properly after logging in
set_default_user();

Thanks for the reply, nerdtopia, but that's not what I'm asking for. I'm talking about the PunBB user variable that holds the previous page URL where the user is redirected to after logging in.

I have pages "outside" the PunBB forum that uses PunBB data thru integration. I want user to get redirected back to the custom page where the user clicked login link (login link redirects to PunBB login page) when a user browses these custom pages, the same way as the user is redirected back to the topic/post after logging in at PunBB forum area.

The issue is currently that when a user comes to the login page from a custom page, the user gets redirected to forum index instead of the custom page where the user came from in real.

Edit: Just realized I posted this to a wrong forum, Integration would have been the correct place for this. A kindly moderator will move this there, will ya? cool

How to define $forum_user['prev_url'] properly from outside the forum? What I'm after is to redirect the user back to the page that is outside the forum (but still in the same domain of course) where the user was before logging in.

Is there a dedicated method/function to do that already or does it require a hack? Tried everything and nothing worked. Using set_default_user() I got the prev_url variable to update correctly outside the forum too but as soon as I go to login the variable is replaced and after login I get redirected to forum index again.

SQLite is the latest, version 3. No other extensions installed at the moment than Topic online users v1.0a but uninstalling it doesn't make a difference.

Thanks and keep up the good work.

When trying to install the extension I get the following error and the extension doesn't get installed:

--
An error was encountered

The error occurred on line 30 in [path]\PunBB\admin\extensions.php(164) : eval()'d code
Database reported: SQL logic error or missing database (Errno: 1).
--

My database is SQLite and everything else is working fine including other extensions. Searched the forum but didn't find any similar topics about the same issue with the extension. Any clues what's happening or is this a bug?

List examples on BBCode help are all the same basic lists although the descriptions talk about different list types.

Admin > Settings > Setup

The general forum timezone setup should have the DST option as well. Causes problems for guests visiting the forum and seeing the time one hour wrong if DST is in effect. Not a big issue tho but thought to report. cool

9

(12 replies, posted in Feature requests)

Damn I'm blind! big_smile

Feel so stupid I didn't see that. Thanks! smile

10

(12 replies, posted in Feature requests)

I think I found it! Reply only mod but the download link on that thread appears to be dead. Can anyone here point out an alternative download link for it?

11

(12 replies, posted in Feature requests)

Yeah you missed the point. I don't want to allow members to add topics for a specific forums but still want to allow them to post replys to the existing topics on those forums. Currently (using v1.2.14) it's possible only to deny posting topics entirely by user group. So what I am looking for is a possibility to define posting permissions for user groups (add reply, add topic) by forums.

12

(12 replies, posted in Feature requests)

This is quite an old thread but I would definitely like this sort of feature as well. This was the only thread I found via search since I'm looking this kind of ability. Is there a mod yet that ables this or any change to add this for the next release (have this been requested lately)?

Without seeing the whole error message it's hard to say, but that specific 503 error code sounds like the SMTP server requires authentication (SSL probably) and authentication settings were not enabled/specified.

Just great, exactly what I was looking for! Thanks a lot Tubby! smile

Okay, the default data in the last post column is "last post time" + "poster". On the forum index page (the mainpage) I would like to show the last post info like this: "last post time" + "topic" + "poster", how to include the topic in there?

Thanks in advance.