Duplicating logout

Discussion forum for MOD Writers regarding MOD Development.
User avatar
mals69
Registered User
Posts: 595
Joined: Thu Mar 30, 2006 6:37 am

Duplicating logout

Post by mals69 »

Wanting to duplicate forum Log Out onto a custom header of a coppermine gallery.

The gallery will be using a coppermine/phpbb3 bridge so not requiring full site integration.

Is there a simple easy way to duplicate the Logout ?

Cheers
User avatar
mals69
Registered User
Posts: 595
Joined: Thu Mar 30, 2006 6:37 am

Re: Duplicating logout

Post by mals69 »

Not hard to feel like the last kid to be picked to play sport at school when you
come in here over 12 hours later and you are the only one with zero replies on the entire
front page
User avatar
mals69
Registered User
Posts: 595
Joined: Thu Mar 30, 2006 6:37 am

Re: Duplicating logout

Post by mals69 »

Is my question just way beyond the skill set of anybody on this site ?
User avatar
Lumpy Burgertushie
Registered User
Posts: 68182
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Duplicating logout

Post by Lumpy Burgertushie »

either nobody understands what you are asking for, or, nobody is interested in it, or maybe the right person hasn't been here today etc.

you seem to take it personally when your posts are not answered in a time frame that you think is appropriate or if they are not answered in the way you wish.

after all, the MOD request and MOD writers sections are for requesting someone to figure out something for you that maybe only you care about.

robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.3 Styles by PlanetStyles.net

If nobody is in the forest, does a tree really fall?
User avatar
mals69
Registered User
Posts: 595
Joined: Thu Mar 30, 2006 6:37 am

Re: Duplicating logout

Post by mals69 »

If I had put it in mod requests myself I would agree but I put it in support.

Are you trying to tell me the Great Robert does not know how to do what I require ?
User avatar
Lumpy Burgertushie
Registered User
Posts: 68182
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Duplicating logout

Post by Lumpy Burgertushie »

no, if I wanted to figure it out I would do so.
you have been around here a long time. you should have learned something by now.
you should be able to figure out things like this for yourself. that may be why nobody has bothered to reply.


robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.3 Styles by PlanetStyles.net

If nobody is in the forest, does a tree really fall?
User avatar
mals69
Registered User
Posts: 595
Joined: Thu Mar 30, 2006 6:37 am

Re: Duplicating logout

Post by mals69 »

Years ago I suggested to a team member that you should be on the support team, the team member replied "Robert will never be on any team due to his past demeanor with users" Thought it was sad at the time but now I see what they meant.
User avatar
Ibedejo
Registered User
Posts: 243
Joined: Tue Feb 21, 2012 12:12 am

Re: Duplicating logout

Post by Ibedejo »

mals69 wrote:Wanting to duplicate forum Log Out onto a custom header of a coppermine gallery.
Running Coppermine in bridge-mode?
Then: whenever you log out from Coppermine using the corresponding Coppermine menu item you will be redirected to and logged out from phpBB as well - this is standard behaviour unless you modify the corresponding Coppermine code ...

So what would be the logic behind integrating phpBB's logout in a Coppermine-"header", when all you need is already there and working the way you seem to want it?
User avatar
mals69
Registered User
Posts: 595
Joined: Thu Mar 30, 2006 6:37 am

Re: Duplicating logout

Post by mals69 »

Because as I posted the keywords are Custom Header. I want a central point in the custom header for login and logout throughout the site - not login and logout a third of the way down the page contained within the gallery, in my book that is just tacky presentation having login/logout scattered randomly throughout a site.

Just to remove the original login and logout button links I had to use the plug-in final extract, you probably aware how complex coppermine has been coded - to the point where their main support member is not
100% sure how what I need can be achieved.
User avatar
Ibedejo
Registered User
Posts: 243
Joined: Tue Feb 21, 2012 12:12 am

Re: Duplicating logout

Post by Ibedejo »

mals69 wrote:Because as I posted the keywords are Custom Header.
Not quite: the keywords are "bridged" and "a custom header of a coppermine".
mals69 wrote:Wanting to duplicate forum Log Out onto a custom header of a coppermine gallery.
While in bridge mode both login/logout and user management are handeled by phpBB and no longer by Coppermine. So hitting the logout link in Coppermine already calls up phpBB and it's corresponding routines.
In this sense, login/logout is centralized and "throughout the site" allready.
By-pass phpBB and call up Coppermine directly, then hit Coppermine's login and see yourself. Same when logging out: you are being redirected to phpBB that takes over the job ...
mals69 wrote:Just to remove the original login and logout button links I had to use the plug-in final extract,
No need to do so - see above.
mals69 wrote:... not login and logout a third of the way down the page contained within the gallery
Then relocate the menu to the top, that's easy enough, isn't it?
And no: the "coding of coppermine" is not that complex. It's different from phpBB's, true, but that's all.

May I suggest that their support member's not being sure how you can achieve what you want stems from the fact that your request there was as "precise" as it is here? ;)
User avatar
mals69
Registered User
Posts: 595
Joined: Thu Mar 30, 2006 6:37 am

Re: Duplicating logout

Post by mals69 »

Andr'e had no problem comprehending what I required, think as you have now demonstrated twice
its you who does not comprehend. You say its "so easy" but offer up nothing ?

You say no need to use final extract when I needed to remove the original login - as you would have seen in the thread it was Andr'e that instructed me to do so, so you are saying Andr'e does not know what he is on about ?

Only fair to give you the right of reply, but once you have I would appreciate you staying out of this topic
unless you have a practical solution.
kwdamp
Registered User
Posts: 21
Joined: Wed Jun 13, 2012 2:36 am

Re: Duplicating logout

Post by kwdamp »

I just solved this problem myself for my custom php logout script.

This code works to unset the user session. No idea how it is affected by your other software though.

<?php
define('IN_PHPBB', true);
$phpbb_root_path = '../phpBB3/'; //the path to your phpbb relative to this script
$phpEx = substr(strrchr(__FILE__, '.'), 1); //the file extension necessary
include("../phpBB3/common.php"); //the path to your phpbb common relative to this script

$user->session_kill();
echo 'Logged out successfully!';
?>
User avatar
mals69
Registered User
Posts: 595
Joined: Thu Mar 30, 2006 6:37 am

Re: Duplicating logout

Post by mals69 »

Cheers for that - the logout code has to be placed in an html file - let server know by placing the required code in .htaccess but has not worked - just shows code in header.
User avatar
Brf
Support Team Member
Support Team Member
Posts: 52141
Joined: Tue May 10, 2005 7:47 pm
Location: {postrow.POSTER_FROM}
Contact:

Re: Duplicating logout

Post by Brf »

The logout URL must contain the user's sid, so it cannot be put into a pure HTML file.
User avatar
mals69
Registered User
Posts: 595
Joined: Thu Mar 30, 2006 6:37 am

Re: Duplicating logout

Post by mals69 »

Thanks - so to clarify the following will not work ?

You can't run PHP in .html files because the server does not recognize that as a valid PHP extension unless you tell it to. To do this you need to create a .htaccess file in your root web directory and add this line to it:
AddType application/x-httpd-php .htm .html

This will tell Apache to process files with a .htm or .html file extension as PHP files.
Locked

Return to “[3.0.x] MOD Writers Discussion”