Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: How can I login from a non-CPG script?  (Read 2344 times)

0 Members and 1 Guest are viewing this topic.

cftranslate

  • Coppermine newbie
  • Offline Offline
  • Posts: 13
How can I login from a non-CPG script?
« on: May 25, 2004, 02:59:49 pm »

I use another application that requires login and I want the user to login in to that application and be logged in in CPG at the same time.

I have not been able to figure out exactly what login method CPG uses.

In my application I have a table with username,pword,tipe (1-administrator 2-regular user).

When the user enters his name if the username and pword are found in the database a
session variable = tipe of user is set and checked for on every page with limited access.

¿Is there a way to implement simultaneous CPG login following this scheme?

Thanks.
Logged

Casper

  • VIP
  • Coppermine addict
  • ***
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 5231
Re: How can I login from a non-CPG script?
« Reply #1 on: May 25, 2004, 04:37:58 pm »

What is this 'other application'?

We have bridge files to several of the popular forum software, that integrates the 2 user managements.
version 1.2.1 has phpbb, invisionboard, yabbse and vbulletin.
version 1.3 will also have smf and woltlab.

There are other apps that have created there own bridges/portals etc.  For instance, E107 has an integration with standalone coppermine, and there are cms versions of coppermine for use with nuke etc.
Logged
It has been a long time now since I did my little bit here, and have done no coding or any other such stuff since. I'm back to being a noob here

cftranslate

  • Coppermine newbie
  • Offline Offline
  • Posts: 13
Re: How can I login from a non-CPG script?
« Reply #2 on: May 25, 2004, 08:47:25 pm »

It is an application that I developed myself, a module to create news articles, I want the jounalist to  be able to create both articles and albums using the same user and pword and without being prompted for user and pword twice, having to enter user and pword twice.
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: How can I login from a non-CPG script?
« Reply #3 on: May 31, 2004, 11:30:57 am »

just use
Code: [Select]
<?php
define
('IN_COPPERMINE'true);
require(
'include/init.inc.php');
?>
on your other page and you should be able to use coppermine's login. If you have developed another php app already it should be easy for you to use coppermine authentification method and find out what vars are defined.

GauGau
Logged
Pages: [1]   Go Up
 

Page created in 0.021 seconds with 14 queries.