Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: 1 2 [3] 4 5 6 7 ... 34   Go Down

Author Topic: CpmFetch - (OLD/LOCKED) stats/thumbnails/randoms/etc from outside CPG  (Read 387818 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 #40 on: December 20, 2004, 06:11:20 pm »

new cpm('coppermine', 'localhost'

did it like that and so on, is that what you meant ? got a whole load of errors with that.


No, that line should now read

$objCpm = new cpm('coppermine', 'localhost', 'root','XXXXXXXX', 'cpg132_', '/grafflix');

You need to replace the XXXX with your password (inside the quotes).  Otherwise the error I am seeing on test.php is some sort of syntax error.  If you do the above then please post the exact code you have again. 
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 #41 on: December 20, 2004, 07:16:36 pm »

ooh, major breakthrough, got a pic :D still getting few error lines though, checkout test.php
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 #42 on: December 20, 2004, 07:28:26 pm »


Okay, thats probably something I need to fix on this end.  I have a few other things I need to take care of and then I will fix that and let you know to update to it.

I am thinking I had the error levels too high on my test box so I did not get those... my bad.

Glad to see you are getting pics!  Brings me great joy and relief.

 ;D

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 #43 on: December 20, 2004, 07:54:55 pm »

Yea me too, tnx alot for all the help, and happy holidays !

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 #44 on: December 20, 2004, 08:19:39 pm »

okay, there is a new version up on the site that eliminates all the errors,  my bad.

give that a whirl....

Since your thumbnails are so small, would you like to have an option to show normal size instead of just thumbnails?

Have a nice day

 ;D
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 #45 on: December 20, 2004, 09:21:50 pm »

Yea that would be a nice function :D

tnx for the new version, gonna test it right away
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 #46 on: December 20, 2004, 10:16:29 pm »


Okay, I have a few things I want to roll into a new version... That will be one of them then.

In the one you downloaded there is another file called cfimageget.php - that one is there so that you can get a random image from an html page via the img tag

<img src="url/cfimageget.php" />

But its only good for one image at a time and the code is still very *new*.

It will probably be a day or two, but I should have the new featues worked out and documented.  Plan is also to change the stylehash to an optionshash - that can contain style information amongst neat new features.

More on this later

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 #47 on: December 21, 2004, 01:20:34 am »

tnx for the new version, tested it and get 0 errors with all_error enabled in php.ini :)

also gonna give the html thingie a try, first finding out how to position the images on a page.
Logged

peeps

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 29
  • Image pulled by Coppermine Fetch
    • philpeeps.com
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #48 on: December 21, 2004, 02:09:41 am »

It seems to work if I comment out this line:

Code: [Select]
header ("Content-Length: " . filesize($filetoget));
As soon as I uncomment, I just get a broken image (red x).

Also, it seems to display a broken image (red x) when it trys to display a pic from a private gallery...

http://www.philpeeps.com/wp/test.php

refresh it a bunch and you will see what I mean.

It would also be helpful to allow it to be a link to that picture.....
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 #49 on: December 21, 2004, 03:13:12 am »


Okay, the cfimageget.php is still kind of under development.  So bear with me - I am glad someone is trying it though... it helps,

Well, you've hit some items that are still in the ironing out stage.

* None of the code here will allow a gallery marked private to be displayed.  So unless you have it marked as viewable by the public, you will not get an image back.

* If it can't return an image then you get the broken image, because your image tag did not get an image back.  It made sense to me at the time, but perhaps I should have it return a transparent pixel or something.  What do you think?  I'm open to suggestions here.  It will probably end up being a programmable behavior.

The private gallery thing is going to be overrideable.  Just have to work it in (I don't have any so the whole private gallery thing snuck up on me at the last momemt)
 
The filesize line seems to work here... I will tamper with it some more and maybe comment it out until I can determine why it is breaking for you.  Are you on a linux / apache / php combo?

Thanks for playing

 ;D




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

peeps

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 29
  • Image pulled by Coppermine Fetch
    • philpeeps.com
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #50 on: December 21, 2004, 03:22:38 am »


Okay, the cfimageget.php is still kind of under development.  So bear with me - I am glad someone is trying it though... it helps,

Well, you've hit some items that are still in the ironing out stage.

* None of the code here will allow a gallery marked private to be displayed.  So unless you have it marked as viewable by the public, you will not get an image back.

* If it can't return an image then you get the broken image, because your image tag did not get an image back.  It made sense to me at the time, but perhaps I should have it return a transparent pixel or something.  What do you think?  I'm open to suggestions here.  It will probably end up being a programmable behavior.

The private gallery thing is going to be overrideable.  Just have to work it in (I don't have any so the whole private gallery thing snuck up on me at the last momemt)
 
The filesize line seems to work here... I will tamper with it some more and maybe comment it out until I can determine why it is breaking for you.  Are you on a linux / apache / php combo?

Thanks for playing

 ;D
IMO, I think if it tries to get a private image, it should loop until it gets a public image.

Currently, I have a script outside of cpg that returns an image with a link to that image but does not obey album permissions, so I am very intersted in getting yours to work....

Keep it up!
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 #51 on: December 21, 2004, 04:22:36 am »


Oh no, you misunderstand me...  The only way to get into the situation of getting a private image is if you specifically request an album id that is private.  The queries it does will never return any image from a private album... no way no how.

As for returning a link, I am not sure how to do this.  The normal php calls can do this easily, but from a straight html page I don't know if it is reliably possible.

Hmmmm

What kind of media do you have in your gallery?  just jpg mostly?
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

peeps

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 29
  • Image pulled by Coppermine Fetch
    • philpeeps.com
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #52 on: December 21, 2004, 04:44:31 am »

just jpeg and 1 video....

wonder why i get the broken images if it cannot request private galleries....

my code is the minimum....

Code: [Select]
<img src="http://www.philpeeps.com/gallery/CoppermineFetch/cfimageget.php" />
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 #53 on: December 21, 2004, 08:57:54 am »

I did some more work on it tonight and posted a dev version for you to download.  There are a few things you should know.

Download from here:
http://cpmfetch.fistfullofcode.com
(Look for the lastest dev version in the download area)
[this has been edited due to a broken link from here]

I was not able to reproduce the error here, but I have only jpegs.  I will try putting in some videos and filtering them out.  The code is simple, so I am guessing that it is getting your video. 

The version of cfimageget.php has a new var named $debug at the top.  When set to true, it will attempt to create a file in the same directory each time it serves an image.  I had to change my file perms to allow it on my server, so if you get it on yours then please relax the file permissions temporarily in that directory.

Once installed, keep hitting the code until you get the broken image.  Then look in the file:  "cfimageget.last" I think that was the name anyway.  it should have a line of data in it (only one) with the extention and then the file it tried to serve.  let me know what that was.

Sorry for the issues, but the code is really new and I am still getting over it.

Also, the default if you dont request a size now is the thumbnail size. 

Bill



« Last Edit: February 16, 2005, 06:00:54 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

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 #54 on: December 21, 2004, 09:00:50 am »

Yea that would be a nice function :D

tnx for the new version, gonna test it right away

The development version now will take an extra parameter in the stylehash called imagesize.  That can be:

thumb, int, large

It will cause the program to return back a larger or really big image.

Here is an example

<?php
   $styleguide = array(
      "alttag" => "One of the last photos submitted",
      "imageSIZE" => "large");

$objCpm->cpm_viewRandomMedia(1,1,$styleguide);
?>

Download from here:
http://cpmfetch.fistfullofcode.com  - look in the download section
You can play with it if you want or wait till its all done.

See ya

Bill
« Last Edit: February 16, 2005, 06:01:48 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

tedd

  • Coppermine newbie
  • Offline Offline
  • Posts: 5
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #55 on: December 21, 2004, 09:55:10 am »

Heyy, when i'm jusing your code for the random image or any other code im getting this error:
Code: [Select]
Notice: Undefined variable: cpm in /home/bandc/public_html/loerbeek.vandulmen.net/gallery/CoppermineFetch/coppermine.php on line 67

Notice: Undefined variable: cpm in /home/bandc/public_html/loerbeek.vandulmen.net/gallery/CoppermineFetch/coppermine.php on line 140

Notice: Undefined variable: cpm in /home/bandc/public_html/loerbeek.vandulmen.net/gallery/CoppermineFetch/coppermine.php on line 88

And i would like to have a counter on my website (outside the gallery). Your counter only shows:  xx pictures. Correct me if im wrong!

I want to have this on my site: "171 files in 7 albums with 17 comments viewed 6520 times"
Logged

cxprod

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 21
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #56 on: December 21, 2004, 10:10:17 am »


I really want to use the last added media syntax...
the thing is...
I have one category full of wmv files...
when i put the include on my page it came up with just the alt text

i put up a test album with a few jpg files and it worked... since the jpgs were the last added media

so.... do you think you'll be able to call the thumbs from the video files? and link them to the page with the video.. or the album with the video...

and if not... is there a way to call last added media from a certain category... I already played with a few different versions of the include and i kept getting errors...
such as..

<?php $objCpm->cpm_viewLastAddedMediaFromCategory(1,1,2) ?>


Great job with this btw!!!!! I love it already
Logged

n3n

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

tedd checkout the new version he posted on his website, it doesnt give any errors.
Logged

n3n

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 173
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #58 on: December 21, 2004, 10:44:09 am »

and vuud, tnx for the work, gonna give it all a go when im done with school.
Logged

tedd

  • Coppermine newbie
  • Offline Offline
  • Posts: 5
Re: CoppemineFetch - stats / thumbnails / randoms / last added outside cpm
« Reply #59 on: December 21, 2004, 11:06:55 am »

indeed, no errors anymore.

now i see nothing  ???  :-\\
Logged
Pages: 1 2 [3] 4 5 6 7 ... 34   Go Up
 

Page created in 0.028 seconds with 20 queries.