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 ... 10 11 12 13 [14] 15 16 17 18 ... 34   Go Down

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

0 Members and 1 Guest are viewing this topic.

unknown_girl

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 23

Hello! can anyone tell me a way to put in my site the 2 last images uploaded? like in htm if possible (not in php)
Logged

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149

Not possible in html. The difference between html and php is like the difference between walking and driving.
Logged

Nibbler

  • Guest

You can create a php page to get the pic, and link to it using an img tag from an html page.
Logged

unknown_girl

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 23

Thanks, can you know explain me so how to do it in a php file?
Logged

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149

The script comes with instructions.
Logged

unknown_girl

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 23

the coppermine Fetch?? I download it, but I only know the random way, thats way I am asking, specila because my english is not so good
Logged

n704fn

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 31

Thanks again for this awesome script!  I've recently decided to make my gallery private, but would still like to use cpmfetch for avatars, and cpm_viewLastAddedMediaFromCategory, etc...  Can someone give me a hint as to how to use cpm_unlock_private  and the ramifications of doing so? Got that figured out, but...

Is it possible to use cpm_unlock_private with cpmfetch? Or is it even possible to use cpmfetch with a private gallery?
OK, looks like that won't work.  Guess you can't have everything :)

Thanks,

Mark


 
« Last Edit: March 04, 2005, 10:05:41 pm by n704fn »
Logged
(https://forum.coppermine-gallery.net/proxy.php?request=http%3A%2F%2Fwww.thechouinards.com%2Fcfetch%2Fcfig_random.php&hash=562ee9e4ceefcfa4cca83d45f784b926a8235733)

Rodinou

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 346
  • Tournicoti, Tournicota
    • http://www.sortons.net

tried, and don't work for me

http://www.sortons.net/cfimageget.php?category=7

nothing ...


but

http://www.sortons.net/cftest.php

works well.


in cfimageget.php

Code: [Select]

include "coppermine_dao.php";
include "/photos/include/config.inc.php";

// This is the path (NOT URL) from where your cfimageget.php file is to your coppermine directory
$pathtocpm = "../photos";

// This is the partial url (part AFTER your domain name, to get to the coppermine directory
$urltocpm = "/photos";


// This is the prefix your Coppermine databse uses for thumbnails  (default shown)
$thumbnailprefix='tn_';

// This is the prefix coppermine uses for intermediate sizes (default shown)
$intermedprefix='normal_';

in cftest.php

Code: [Select]
<?php
// You need to change this variable to the directory that the Coppermine photo gallery is installed in.
$ChangeThisToYourPartialUrlToCPG "/photos";
?>


<html>
<head>
<title>CoppermineFetch Install Test page</TITLE>
</head>
<body>

<h1>CoppermineFetch Install test page</h1>
<p>Thank you for using CoppermineFetch...</p>

<hr>


in coppermine.php

Code: [Select]
var $thumbnailprefix = "tn_";
var $intermedprefix = "normal_";
var $fullsizeprefix = '';

var $defaultimagesize = "tn_";
var $cpm = "";
var $urltocpm = "";       //from a web client point of view without domain name /photos
var $filepathtocpm = "";  //server path to cpm directory  /home/vuud/cpm

Where am I wrong ?

unknown_girl

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 23

Hello! I was trying to reach the file rss_lastadded.php, and it says in my server: I'ts not possible to show the XML 
It's not possible to se the files introduction of the XML, user by the style sheet. Correct your error, and then refresh the site, or try later.
--------------------------------------------------------------------------------

The sistem doesn't supports the specific codification. Error processing : 'http://hilaryduff.hostingportugal.com/copperminefetch/cpmfetch/rss_lastadded.php'.

Can you help me? (I translate this becauste it was in portuguese, so sorry if there's any mistake)

Logged

BZRK

  • Coppermine newbie
  • Offline Offline
  • Posts: 2


You can probably just override the alt with a blank - although I am not sure.  Try this:

$cpmobj->cpm_viewRandomMedia(1,1,array("alttag" => ""));

That should just add an empty alttag

Hope that helps


Thank you, it did help :)
Logged

canelli

  • Translator
  • Coppermine novice
  • **
  • Offline Offline
  • Gender: Male
  • Posts: 36
  • Fetched by CpmFetch
    • Centro Vela Dervio Sailing club

I installed the mod on my test web but i had two problems

1) DOCUMENT_ROOT is not set in anyinstallation (any of that ) - IIS 5.0 - php 4.3.2  and IIS 6.0 - php 4.3.10

2) I have the albums directory outside of the coppermine tree and not with standard name. Now the dricetory is hardcoded
it is not possible  get the album directory from the cpg's configuration CONFIG['fullpath']  ?
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code

I installed the mod on my test web but i had two problems

1) DOCUMENT_ROOT is not set in anyinstallation (any of that ) - IIS 5.0 - php 4.3.2  and IIS 6.0 - php 4.3.10

2) I have the albums directory outside of the coppermine tree and not with standard name. Now the dricetory is hardcoded
it is not possible  get the album directory from the cpg's configuration CONFIG['fullpath']  ?



Its really starting to bother me that I dont get email notifications about new postings :(

The CONFIG is read by the program, but it finds it based on the DOCUMENT_ROOT

You can probably do something with cpm_init to start it instead of using the normal cpm constructor.  After that you can also call

cpm_OverridePathToCoppermine($path)
cpm_OverrideUrlToCoppermine($path)

The first should override where it looks for images from a filesystem point of view, the second is from a web browser point of view.  These are probably only available in the lastest version

Hope that makes sense to someone :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

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code

Is it possible to use cpm_unlock_private with cpmfetch? Or is it even possible to use cpmfetch with a private gallery?
OK, looks like that won't work.  Guess you can't have everything :)

Thanks,

Mark



I think it would be possible... you'd have to edit the cfimageget.php and add in a call to the coppermine_dao to that function.  OR, you can wait till I finish the next release which will have a 100% redone cfimageget.php (I assume thats what you were referring too)

The code to enter would be:

$cpm->setPriviteLockOn(false);

At line 65 in the version 1.1.3 (Just after the setPhotoPrefix

That should get you 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

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code


What version are you using?  The 1.1.3 is much better with cfimageget - try that if you are still using the stable version (which is old)

My bad, I decided to redo all the cfimageget stuff again before the next release - then got real busy.  I want to finish it, but wont be able to for at least a few days.  The new way will be much better



tried, and don't work for me

http://www.sortons.net/cfimageget.php?category=7

nothing ...


but

http://www.sortons.net/cftest.php

works well.


in cfimageget.php

Code: [Select]

include "coppermine_dao.php";
include "/photos/include/config.inc.php";

// This is the path (NOT URL) from where your cfimageget.php file is to your coppermine directory
$pathtocpm = "../photos";

// This is the partial url (part AFTER your domain name, to get to the coppermine directory
$urltocpm = "/photos";


// This is the prefix your Coppermine databse uses for thumbnails  (default shown)
$thumbnailprefix='tn_';

// This is the prefix coppermine uses for intermediate sizes (default shown)
$intermedprefix='normal_';

in cftest.php

Code: [Select]
<?php
// You need to change this variable to the directory that the Coppermine photo gallery is installed in.
$ChangeThisToYourPartialUrlToCPG "/photos";
?>


<html>
<head>
<title>CoppermineFetch Install Test page</TITLE>
</head>
<body>

<h1>CoppermineFetch Install test page</h1>
<p>Thank you for using CoppermineFetch...</p>

<hr>


in coppermine.php

Code: [Select]
var $thumbnailprefix = "tn_";
var $intermedprefix = "normal_";
var $fullsizeprefix = '';

var $defaultimagesize = "tn_";
var $cpm = "";
var $urltocpm = "";       //from a web client point of view without domain name /photos
var $filepathtocpm = "";  //server path to cpm directory  /home/vuud/cpm

Where am I wrong ?

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


To say the least, the cpmFetch RSS stuff is not ready for primetime.    It seems like you are sending a feed, so I do not understand if this is fixed, or if its a problem with your newsreader.

I just dont know  ???



Hello! I was trying to reach the file rss_lastadded.php, and it says in my server: I'ts not possible to show the XML 
It's not possible to se the files introduction of the XML, user by the style sheet. Correct your error, and then refresh the site, or try later.
--------------------------------------------------------------------------------

The sistem doesn't supports the specific codification. Error processing : 'http://hilaryduff.hostingportugal.com/copperminefetch/cpmfetch/rss_lastadded.php'.

Can you help me? (I translate this becauste it was in portuguese, so sorry if there's any mistake)


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

unknown_girl

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 23

vuud, thanks any way
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code

vuud, thanks any way

Are you sure your reader is working correctly?  I am working on a new release right now, then the RSS functionality will get a good going over for the next one. 

Good luck
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

n704fn

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 31

Is it possible to use cpm_unlock_private with cpmfetch? Or is it even possible to use cpmfetch with a private gallery?
OK, looks like that won't work.  Guess you can't have everything :)

Thanks,

Mark



I think it would be possible... you'd have to edit the cfimageget.php and add in a call to the coppermine_dao to that function.  OR, you can wait till I finish the next release which will have a 100% redone cfimageget.php (I assume thats what you were referring too)

The code to enter would be:

$cpm->setPriviteLockOn(false);

At line 65 in the version 1.1.3 (Just after the setPhotoPrefix

That should get you there


Tried that, but it just broke cfimageget.  No errors, just no image.  Looking forward to the next version.

Mark
Logged
(https://forum.coppermine-gallery.net/proxy.php?request=http%3A%2F%2Fwww.thechouinards.com%2Fcfetch%2Fcfig_random.php&hash=562ee9e4ceefcfa4cca83d45f784b926a8235733)

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code

Tried that, but it just broke cfimageget.  No errors, just no image.  Looking forward to the next version.
Mark

Hmmm, okay.  Well, I have been working today on it, and have the cfimageget up to where I think I want it.  Depending on a few other things I could have the new development version (which is really going to be a release candidate for the next stable) out later today or tomorrow.  Depending on how much I feel like testing later on today.

Private message me with an email addr if you have time and want to try this one in the meantime...

Happy days





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

pierse

  • Coppermine newbie
  • Offline Offline
  • Posts: 11

I have been trying to re-create this:
Quote
$objCpm->cpm_formatStats("Here is a percent sign %% There are
   %f files in %c categories containing %a albums,
   having served %v views and getting %n comments");
but I cannot get it to work.  I wanted to include this line in my template.php for my forum I use and I always get an error page that is standard for my portal.  (Tiny Portal (SMF)).  I do not know php code. so, please forgive me in advance. ;)
Logged
Pages: 1 ... 10 11 12 13 [14] 15 16 17 18 ... 34   Go Up
 

Page created in 0.027 seconds with 13 queries.