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 [2] 3 4 5 6 ... 34   Go Down

Author Topic: CpmFetch - (OLD/LOCKED) stats/thumbnails/randoms/etc from outside CPG  (Read 324474 times)

0 Members and 1 Guest are viewing this topic.

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #20 on: December 19, 2004, 11:39:06 pm »

 ???

I've been trying to duplicate the error here on my test page and no matter what I do I cannot get it to do what yours is doing.  In the case of that function you should either get 1) Errors, 2) a zero if there are none.

One thing I'd like you to grab is the distrobution off my site again... The only thing I can think of is that there is some bug in there that I fixed.

http://www.fistfullofcode.com/projects/copperminefetch

Also, can you change the print "test"; to something wrong like priiiint "test"

I want to see if your PHP installation will report errors at all :)

If it does not report any errors, add in:

error_reporting(E_ALL);

just after the <?php entry
This should force errors to be displayed and perhaps that will shed some light on things



« Last Edit: December 19, 2004, 11:50:40 pm by vuud »
Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #21 on: December 19, 2004, 11:55:04 pm »

still not getting errors
think im gonna change some settings in php.ini
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #22 on: December 19, 2004, 11:57:01 pm »

I updated the post above again with a suggestion to try

error_reporting(E_ALL);

Not sure if you saw it.

Also in the php.ini you will want

display_errors = On
(from what I read)

If you insert a phpinfo(); into your page I can help you look

Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #23 on: December 20, 2004, 12:02:05 am »

yea i saw it, didnt do anything :( this is so weird, all other scripts seem to run fine
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #24 on: December 20, 2004, 12:05:50 am »


Can you add in the phpinfo() so I can look at it?

Was the error reporting off?
Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #25 on: December 20, 2004, 12:12:23 am »

Your display_errors is set to off.

That could be hiding what the problem is
Otherwise we have the same php version
Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #26 on: December 20, 2004, 12:13:37 am »

turned on error reporting now, couldnt get the phpinfo to work when the other code was in the file, flix.php now only contains
the phpinfo tag
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #27 on: December 20, 2004, 12:14:59 am »

Great, lets try the original code in there!
Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #28 on: December 20, 2004, 12:19:32 am »

checkout test.php, put this code in there and getting weird output.

Code: [Select]
<?php
include "./grafflix/include/config.inc.php";
include 
"./grafflix/copperminefetch/coppermine.php";
$objCpm = new cpm($mysql_dbname$mysql_host$mysql_username$mysql_password$cpm_mysql_tableprefix$urltocpm);
$objCpm->cpm_viewRandomMediaFromCategory(1,1,9);
$objCpm->cpm_close();
?>


Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #29 on: December 20, 2004, 12:23:50 am »

Your back to the original set... you need to change to the other parameters I gave you a few posts back.  The ones you are using are if you want to define your own... the coppermine include/config.inc.php uses different ones:

$objCpm = new cpm($CONFIG['dbname'], $CONFIG['dbserver'], $CONFIG['dbuser'],$CONFIG['dbpass'], $CONFIG['TABLE_PREFIX'], '/grafflix');

At least we are seeing errors now!
Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #30 on: December 20, 2004, 12:37:42 am »

gettint this error, just changed my password for security reasons :P

Code: [Select]

Notice: Undefined index: coppermine in c:\program files\easyphp1-7\www\test.php on line 4

Notice: Undefined index: localhost in c:\program files\easyphp1-7\www\test.php on line 4

Notice: Undefined index: root in c:\program files\easyphp1-7\www\test.php on line 4

Notice: Undefined index: ***** in c:\program files\easyphp1-7\www\test.php on line 4

Notice: Undefined variable: cpm in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine.php on line 66

Notice: Undefined variable: cpm in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine.php on line 97

Warning: mysql_connect(): Access denied for user: 'ODBC@localhost' (Using password: NO) in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine_dao.php on line 154

Warning: mysql_select_db(): supplied argument is not a valid MySQL-Link resource in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine_dao.php on line 155

Warning: mysql_error(): supplied argument is not a valid MySQL-Link resource in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine_dao.php on line 156

Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine_dao.php on line 169

Warning: mysql_error(): supplied argument is not a valid MySQL-Link resource in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine_dao.php on line 170

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine_dao.php on line 171

Warning: mysql_error(): supplied argument is not a valid MySQL-Link resource in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine_dao.php on line 172

Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine_dao.php on line 57

Notice: Undefined variable: cpm in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine.php on line 87

Warning: mysql_close(): supplied argument is not a valid MySQL-Link resource in c:\program files\easyphp1-7\www\grafflix\copperminefetch\coppermine_dao.php on line 161
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #31 on: December 20, 2004, 12:47:22 am »

Do you have a password in your includes/config.inc.php assigned to $CONFIG['dbpass'] ?

It looks like that is what is failing... although your gallery still works, so that should not be it

And you have the newest one from my site right?
 

Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #32 on: December 20, 2004, 12:49:30 am »

yea i got a password in the include/config.inc.php file, the correct password aswell :P

Yup, just downloaded the last version from your website, so that should be ok :)

Logged

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #33 on: December 20, 2004, 01:05:13 am »

gonna turn in.

spreek to you later, tnx for the help
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #34 on: December 20, 2004, 01:06:14 am »

Alright, I think its a windows / odbc issue with the call. I will come up with some way to test it'
Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

Nibbler

  • Guest
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #35 on: December 20, 2004, 01:21:09 am »

You wouldn't be putting actual values into the $CONFIG bits would you? ie. $CONFIG['localhost'], $CONFIG['root'] ...
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #36 on: December 20, 2004, 01:34:51 am »

gonna turn in.

spreek to you later, tnx for the help

Okay, here are a few things to try.  Add a new php page and use this for the content:

Code: [Select]
<?php
// HELP FOR YOU - PLEASE COMPLETE THE VARIABLES BELOW MANUALLY
$dbuser '';
$dbhost '';
$dbpass '';
$dbname '';

$dbconnection mysql_connect($dbhost$dbuser$dbpass);

print 
"Using user: $dbuser   host: $dbhost   name: $dbname";
mysql_select_db($this->dbname$dbconnection);
print (
mysql_error($dbconnection));
?>


Make sure that you fill in the variables with the correct data.  If this works, then change your other test.php page to pass the exact values (replace all the variables with the actual information) - like 'localhost' instead of $CONFIG['dbhost'] or whatever.

I am convinced something is not reading right.  If that works, please post a copy of your config.inc.php with the password XXXXX'd out

I hope something here works!
Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #37 on: December 20, 2004, 01:41:36 am »

(still awake for a sec)

got this output with your code

Code: [Select]
Using user: root host: localhost name: coppermine
Notice: Undefined variable: this in c:\program files\easyphp1-7\www\test.php on line 11
No Database Selected

my config.inc.php:

Code: [Select]
<?php
// Coppermine configuration file

// MySQL configuration
$CONFIG['dbserver'] =                         'localhost';        // Your database server
$CONFIG['dbuser'] =                         'root';        // Your mysql username
$CONFIG['dbpass'] =                         'XXXXX';                // Your mysql password
$CONFIG['dbname'] =                         'coppermine';        // Your mysql database name


// MySQL TABLE NAMES PREFIX
$CONFIG['TABLE_PREFIX'] =                'cpg132_';
?>


Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #38 on: December 20, 2004, 01:48:27 am »


whoops.  Take out the $this->dbname and replace it with $dbname

but that all means the other part was working...

Try the changes to the test.php with the real variables....




Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #39 on: December 20, 2004, 11:10:50 am »

new cpm('coppermine', 'localhost'

did it like that and so on, is that what you meant ? got a whole load of errors with that.
Logged
Pages: 1 [2] 3 4 5 6 ... 34   Go Up
 

Page created in 0.03 seconds with 20 queries.