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   Go Down

Author Topic: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)  (Read 139197 times)

0 Members and 1 Guest are viewing this topic.

v8central

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 34
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #60 on: November 15, 2005, 11:12:12 am »

Hello ?

can someone give me some tips on how to use CPMFETCH within the bounds of a Mambo/Joomla article please ?
Logged

ksshane

  • Coppermine newbie
  • Offline Offline
  • Posts: 5
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #61 on: November 15, 2005, 12:48:50 pm »

Not exactly sure where I went wrong.

Test page shows everything working, but when I add this code

Code: [Select]
<?php 
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/accgallery");
$objCpm->cpm_viewRandomMedia(3,3);
$objCpm->cpm_close();
?>


To my portal page I get this

Code: [Select]
cpm_viewRandomMedia(3,3); $objCpm->cpm_close(); ?>

Instead of random photos.

Can someone tell me what I did wrong?

Here is a link to my site if that helps

http://www.aircapitalconstrictors.com/forum/portal1.php

Thanks
Shane
Logged

v8central

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 34
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #62 on: November 15, 2005, 10:11:19 pm »

I wrote this email to send to "Bill" from CPMFETCH, but I just got an autoresponder saying use the forums - great :(, but here's the email if it helps :

Quote
Mate,  I'm having real problems getting CPMFETCH working the way I want.

What I want to do is create a site for a car yard.  They upload the pics to a Coppermine album, but the main website is running Joomla.  So they post a Joomla article and use CPMFETCH to put the thumbnails into the Joomla article.  Then using the normal CPMFETCH functionality the users click on the thumb and it opens the full image (in coppermine). 

I can't figure out how this works, or find any demo code.  Queries in forums are largely going unanswered as well :(

Can you help me at all please ?
Logged

CPG Guru

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Female
  • Posts: 40
  • Cool Buddy
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #63 on: November 17, 2005, 08:44:25 pm »


You only need to create the cpmfetch object once before all your calls and close it once after. In between you can do as many calls to get images and stats that you want.

I suspect thats your problem



I agree that we can call it any no. of time , but as i told u i want 1 pic from each category in Horizontal line , but if i used your this code the first category comes in first line 2nd in 2nd line & so on all this executes in vertical manner

<?php   
include "cpmfetch.php";
$objCpm = new cpm('/photos');
$objCpm->cpm_viewRandomMedia (1,4);
$objCpm->cpm_viewRandomMedia (1,3);
$objCpm->cpm_viewRandomMedia (1,35);
$objCpm->cpm_close();
?>

Again, I want to insert 5 pics in Horizontol way, so please suggest the best way.

Quote

A messy way that leaps to mind would be to do it in a table... this would yield tables in tables, but unless you are php-ready and want to code a bit to display the images, you can do:

Code: [Select]
<?php
include "cpmfetch.php";
$objCpm = new cpm('/photos');
?>


<table>
<tr>
<td><?php $objCpm->cpm_viewRandomMediaFrom(1,1,"cat=1"); ?></td>
<td><?php $objCpm->cpm_viewRandomMediaFrom(1,1,"cat=2"); ?></td>
<td><?php $objCpm->cpm_viewRandomMediaFrom(1,1,"cat=3"); ?></td>
<td><?php $objCpm->cpm_viewRandomMediaFrom(1,1,"cat=4"); ?></td>
<td><?php $objCpm->cpm_viewRandomMediaFrom(1,1,"cat=5"); ?></td>
</tr>
</table>
<?php $objCpm->cpm_close(); ?>


I cant remember if the "cat=1" should go before the 1,1 or not. Hmmmm

Anyway, the other way is to get back result sets and build your own img ref tag from it.

This will make a series of 1 image tables inside the table of 5 cells.


Quote


YAHOOOOO    !!!!!!!

It Works Dear as it is !!!!!!!!!!!!!!

Ive PM u my site link , !!@#$   Please Suggest & Have Feel of your Hard work

THANKS DEAR
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #64 on: November 18, 2005, 11:11:40 pm »

I wrote this email to send to "Bill" from CPMFETCH, but I just got an autoresponder saying use the forums - great :(, but here's the email if it helps :

Quote
Mate,  I'm having real problems getting CPMFETCH working the way I want.

What I want to do is create a site for a car yard.  They upload the pics to a Coppermine album, but the main website is running Joomla.  So they post a Joomla article and use CPMFETCH to put the thumbnails into the Joomla article.  Then using the normal CPMFETCH functionality the users click on the thumb and it opens the full image (in coppermine). 

I can't figure out how this works, or find any demo code.  Queries in forums are largely going unanswered as well :(

Can you help me at all please ?

Yeah.  *beep*!!  How dare!  My goodness, why on earth would people NOT want to get e-mails all the time about free software when there is a chance someone else can answer some in the forums?  Geeeze - the nerve.  And how dare it be suggested that you seek help in a forum or even give suggestions as to where else you could look!  Even the HELP page on the cpmfetch site tells you to email, oh wait, no - it tells you to go to the forum.  My bad.   Hmmmm.   Maybe its because if all the problems are in one place in public, along with countless solutions, someone could search on them and figure out the answer. 

Be happy the autoresponder included your message so you could repost it.

Anyway.  People have gotten it running in many many forum systems.  You just need to figure out how to execute an SSI or PHP.  I don't use "joomla" so i have no idea.  Get it to execute some php and you should be okay.

From a solution point of view, do they need to get random or can they just do an img tag to the image?


As for replies going unanswered in fourms - this and joomla (I guess) is free software, community supported.  There are about 1000 messages on cpmfetch, and over 15,000 views I'd say on the all in all its active.  If you want to be helpful post a solution when you figure it out.  I have no idea why messages in joomla would go unanswed.







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

v8central

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 34
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #65 on: November 19, 2005, 05:53:50 am »

Thank you for replying - but I thought I would get more than a truckful of abuse and no real help at all.  I actually sent that email because my post had gone unanswered on here for many days, even when I was bumping and providing more info

Quote
If you want to be helpful post a solution when you figure it out.
You've got to be kidding right ?  I give back to many forums, where the people are helpful.  On forums like this where it seems you are chosen to be ignored, then I choose to do the same.

Thanks for the help so far :(
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #66 on: November 19, 2005, 06:31:12 am »

Thank you for replying - but I thought I would get more than a truckful of abuse and no real help at all.  I actually sent that email because my post had gone unanswered on here for many days, even when I was bumping and providing more info

Quote
If you want to be helpful post a solution when you figure it out.
You've got to be kidding right ?  I give back to many forums, where the people are helpful.  On forums like this where it seems you are chosen to be ignored, then I choose to do the same.

Thanks for the help so far :(

You were not chosen to be ignored.  Someone else was picked this week - seriously, I would tell you who it was, but that would ruin it for everyone.   Apparently no one knows how your system works, hence the lack of answers.  Its better this way than having 50 responses saying "I dont know" right?

There was help in there.  I mentioned two things to look at specifically.  Including PHP in the templates or articles or referencing a SSI or even just calling it from an image tag.  All of which the Joomla forums should be able to help you with.  But you want to ignore this bit of advice i threw in because it still means you have to work at it yourself.

Quote
You've got to be kidding right ?  I give back to many forums, where the people are helpful.  On forums like this where it seems you are chosen to be ignored, then I choose to do the same.

Here is part of the probolem:

* You are asking for tips for a system no one else here has used (that I know of).

* Your posts are all bump, or just asking again, or complaining.  Not one shows that you actually tried, or have been trying, or even made an attempt.

What would you suggest for responses?  Something like:  "I dunno"? 

If you had shown any inkling of even making an effort to try to solve this on your own I probably would have helped.    Sorry you are terribly unhappy with this forum.   If you do figure it out and don't post a solution for some other poor guy who tries to do the same thing later on (trust me no one here right now will benefit from it) regardless of your feelings for me/us then shame on you.  Shame shame shame. FOSS is about giving code out for free.  There is nothing in there entitling you to support.  Honest.  Heck even if you pay for software, rarely do you get any decent support that you don't have to pay for.

Your not hurting me by not doing it.  Just some other complete stranger.  But anyway, in the meantime enjoy the work that has already been done for you in cpmfetch for free...

If you want to actually post what you have tried and what happened maybe someone will have an idea. 

If you don't want to try it yourself, see this page and the item entitled "Pay for CpmFetch Support"
http://www.fistfullofcode.com/projects/copperminefetch/manual/ch03.html

And I recommend you read it before making snide comments.

Regards,

Bill "Vuud" Chmura





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: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #67 on: November 19, 2005, 06:51:13 am »

Not exactly sure where I went wrong.

Test page shows everything working, but when I add this code

Code: [Select]
<?php 
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/accgallery");
$objCpm->cpm_viewRandomMedia(3,3);
$objCpm->cpm_close();
?>


To my portal page I get this

Code: [Select]
cpm_viewRandomMedia(3,3); $objCpm->cpm_close(); ?>

Instead of random photos.

Can someone tell me what I did wrong?

Here is a link to my site if that helps

http://www.aircapitalconstrictors.com/forum/portal1.php

Thanks
Shane

Sorry, started looking at this the other day, but that big ass scorpion on the front page scares me :)  Why i could never live out sou-west.

Anyway - your page has this in the html:

<?php
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/gallery");
$objCpm->cpm_viewRandomMedia(3,3);
$objCpm->cpm_close();
?>

Which means its not getting interpreted as php when the page is constructed. 

I'm an SMF person myself, so I am not sure on the PHPBB - but I know it will work in PHPBB... someone did it here before. 

Yeah, here it is:   http://forum.coppermine-gallery.net/index.php?topic=19528.msg87858#msg87858

This person documented how they did it (thanks fishfreak) after we got it working.

Now, I would chastise you for not searching the board for a solution, but I have already vented for the night...

Hope that helps, if it does not - post where the process broke down.

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

v8central

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 34
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #68 on: November 19, 2005, 08:50:57 am »

Would the situation change if I mentioned that Joomla! is a very recent fork of Mambo ? (Apologies, but I thought that almost everyone knew that anyway). The CPMFETCH documentation says that it works with Mambo, but there are no working examples.  I don't have a problem working things out for myself but this time I need a nudge in the right direction.  I tried CPMFETCH because I want to display the Coppermine images outside the Coppermine code (I want to put them in a news article in Mambo), but where do I start ? I have the code installed and working (via the test script), but apart from that I'm stuck hence the posting on this forum.

I contacted another user via PM (he must have been chosen to be ignored a few months ago :p) because his post helped me out but the question he posed remained unanswered as well.  Now I don't expect EVERY question to be supplied with a fully worked answer within seconds of posting (THAT is unrealistic), but what I do expect is the so-called "experts", "support personnel", whatever you/they are called here to actually respond with SOMETHING .... even if it is just "I don't get what you mean, could you explain it a different way ?" rather than completely ignoring the situation.


I would love to get CPMFETCH working, but without an example of how it works in Mambo (aka Joomla!) I've actually started coding my owm solution which doesn't require CPMFETCH at all .... although I think CPMFETCH will be a more elegant solution for everything.
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #69 on: November 19, 2005, 07:05:18 pm »

Would the situation change if I mentioned that Joomla! is a very recent fork of Mambo ? (Apologies, but I thought that almost everyone knew that anyway). The CPMFETCH documentation says that it works with Mambo, but there are no working examples.  I don't have a problem working things out for myself but this time I need a nudge in the right direction.  I tried CPMFETCH because I want to display the Coppermine images outside the Coppermine code (I want to put them in a news article in Mambo), but where do I start ? I have the code installed and working (via the test script), but apart from that I'm stuck hence the posting on this forum.


I contacted another user via PM (he must have been chosen to be ignored a few months ago :p) because his post helped me out but the question he posed remained unanswered as well.  Now I don't expect EVERY question to be supplied with a fully worked answer within seconds of posting (THAT is unrealistic), but what I do expect is the so-called "experts", "support personnel", whatever you/they are called here to actually respond with SOMETHING .... even if it is just "I don't get what you mean, could you explain it a different way ?" rather than completely ignoring the situation.


I would love to get CPMFETCH working, but without an example of how it works in Mambo (aka Joomla!) I've actually started coding my owm solution which doesn't require CPMFETCH at all .... although I think CPMFETCH will be a more elegant solution for everything.

Lol, I don't think there are any support personnel or anything here really.  I mean its not a job or anything.  I wrote it, then just gave it away.  I originally intended no documentation at all, aiming it at other programmers.  but I did and here we are today.  So there is no real committment to support like a M$ or Apple would have.  But time permitting I help when I can.  Sometimes other post notes, but not as often as I would like to see.  Mostly the forum is here for historical reasons... sometimes your issue has been covered already.

As for examples, I am willing to take any submissions for the docs as far as how to do it, but you have to understand that FOSS is a very self centric thing... I got it to do what I needed, then a bunch more - but I am not willing to cover every contingency.  I will take writeups sent to me and insert them with a big credit to the person though.

But anyway, I think the problem you are going to have with what you are trying to do is when you stick them into an article.  I know the other successes have been with sticking them into templates (which in turn hold the article I am guessing).   Now, I am guessing here, based on my experiences, that the content of the article may not be processed as possibly having executable code in it.    That is where you are going to have the biggest problem. 

Now if you want the cpmfetch in the template thats different.  We could be fighting over semantics.  If you are really just going to stick something into an article instead of the template you really need to find out if / how to execute PHP code.

If you can't execute code you can always use cfimageget to grab a single image into an IMG tag.

I guess thats your next step... clarify what exactly you want to stick exactly where.  Then I will tell you where you can stick cpmfetch.  lol


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

v8central

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 34
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #70 on: November 19, 2005, 10:51:11 pm »

 ::) As I said, I want to post the thumbs in an article, I didn't mention templates at all because I don't want to put the thumbs in a template.

One other problem I found, is that if I'm CPMFETCH and using that within Mambo/Joomla then when I click on the thumb it goes to my full Coppermine install (ie it breaks out of the Mambo template).  This is a whole different problem though.
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #71 on: November 20, 2005, 03:37:51 am »

::) As I said, I want to post the thumbs in an article, I didn't mention templates at all because I don't want to put the thumbs in a template.

One other problem I found, is that if I'm CPMFETCH and using that within Mambo/Joomla then when I click on the thumb it goes to my full Coppermine install (ie it breaks out of the Mambo template).  This is a whole different problem though.

Okay, I know you said it, but you would not believe how many people get the terminology confused.

Pretty much you need to determine if you can execute PHP or make SSI calls, or just call IMG tags from the article.

I am not sure how to keep it contained in Mambo.  You could always just set it to popup a window without going into the CPG (Just display the image)


 
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

ksshane

  • Coppermine newbie
  • Offline Offline
  • Posts: 5
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #72 on: November 20, 2005, 10:44:41 pm »

Thanks for the help.  I could have swore I did a search (im usually pretty good at doing that before posting a question)...   But I really feel bad since the answer to my question was in this exact same thread. :o
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #73 on: November 21, 2005, 12:15:48 am »

Thanks for the help.  I could have swore I did a search (im usually pretty good at doing that before posting a question)...   But I really feel bad since the answer to my question was in this exact same thread. :o

Don't feel bad.  As long as you learn something :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

drunkendave

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #74 on: November 23, 2005, 06:26:22 pm »

Ok I've spent 2 hours reading almost everything in this Forum (which I don't mind I'm on Vacation lol)  I started off by having problems with the cftest.php.  Again from reading post I got it to display Thumbnails. Here are the test results still some errors and I read that using IIS is bad but that's all I have to use.
Code: [Select]
Notice: Undefined index: DOCUMENT_ROOT in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cftest.php on line 213

Notice: Undefined index: DOCUMENT_ROOT in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cftest.php on line 214

Notice: Undefined index: SCRIPT_FILENAME in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cftest.php on line 214

Notice: Undefined index: DOCUMENT_ROOT in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cftest.php on line 221
5 You set your partial URL to ../gallery PASS
10 No dots in partial url PASS
15 coppermine.php not present PASS
20 coppermine_dao.php not present PASS
25 cpmfetch.php found PASS
30 cpmfetch_dao.php found PASS
35 Server OS = Windows NT TOTALWEBHQ01 5.2 build 3790 INFO
40 WebServer = Microsoft-IIS/6.0 INFO
45 PHP Version = 4.3.10 INFO
55 DOCUMENT_ROOT: Not found BAD
60 C_DOCUMENT_ROOT: Not found INFO
65 doc_root: Not found (IIS Servers only) INFO
70 SCRIPT_FILENAME: Not found BAD
75 DOCUMENT_ROOT is a good match PASS
80 Found CPG config file PASS
I understand there is some bad's in there although I created an index.php file with
Code: [Select]
<?php
include "cpmfetch.php";
$objCpm = new cpm('../gallery');
$objCpm->cpm_viewRandomMedia (1,1);
$objCpm->cpm_viewRandomMedia (1,1);
$objCpm->cpm_close();
?>
Load up http://www.canadianrifles.com/cpmfetch/index.php  and it shows the thumbnails.  Now my biggest problem is getting those images to show up on my block on my main page.  I'm just learning all this PhP and website editing but I have a basic knowledge of it.  I tried putting in my block <img src="http://www.canadianrifles.com/cpmfetch/index.php>  but get nothing but a broken image. 
I've also tried using the cfimageget.php.  I've changed direct access to true and changed my $urltocpm = "../gallery/";  i've also tried using /gallery/,  /gallery  and gallery/   but everytime i point my browser to cfimageget.php it comes back as the white screen of death.  If there is anything else you need to know please ask.  Oh and if this has already been answered I give full permission to flame me in every way possible.  I could've looked right at it but after going through 30+ forum pages all i'm seeing when I look away from the screen is code everywhere lol.
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #75 on: November 23, 2005, 06:38:02 pm »

Ok I've spent 2 hours reading almost everything in this Forum (which I don't mind I'm on Vacation lol)  I started off by having problems with the cftest.php.  Again from reading post I got it to display Thumbnails. Here are the test results still some errors and I read that using IIS is bad but that's all I have to use. 
Code: [Select]
Notice: Undefined index: DOCUMENT_ROOT in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cftest.php on line 213

Notice: Undefined index: DOCUMENT_ROOT in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cftest.php on line 214

Notice: Undefined index: SCRIPT_FILENAME in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cftest.php on line 214

Notice: Undefined index: DOCUMENT_ROOT in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cftest.php on line 221
5 You set your partial URL to ../gallery PASS
10 No dots in partial url PASS
15 coppermine.php not present PASS
20 coppermine_dao.php not present PASS
25 cpmfetch.php found PASS
30 cpmfetch_dao.php found PASS
35 Server OS = Windows NT TOTALWEBHQ01 5.2 build 3790 INFO
40 WebServer = Microsoft-IIS/6.0 INFO
45 PHP Version = 4.3.10 INFO
55 DOCUMENT_ROOT: Not found BAD
60 C_DOCUMENT_ROOT: Not found INFO
65 doc_root: Not found (IIS Servers only) INFO
70 SCRIPT_FILENAME: Not found BAD
75 DOCUMENT_ROOT is a good match PASS
80 Found CPG config file PASS
I understand there is some bad's in there although I created an index.php file with
Code: [Select]
<?php
include "cpmfetch.php";
$objCpm = new cpm('../gallery');
$objCpm->cpm_viewRandomMedia (1,1);
$objCpm->cpm_viewRandomMedia (1,1);
$objCpm->cpm_close();
?>
Load up http://www.canadianrifles.com/cpmfetch/index.php  and it shows the thumbnails.  Now my biggest problem is getting those images to show up on my block on my main page.  I'm just learning all this PhP and website editing but I have a basic knowledge of it.  I tried putting in my block <img src="http://www.canadianrifles.com/cpmfetch/index.php>  but get nothing but a broken image. 
I've also tried using the cfimageget.php.  I've changed direct access to true and changed my $urltocpm = "../gallery/";  i've also tried using /gallery/,  /gallery  and gallery/   but everytime i point my browser to cfimageget.php it comes back as the white screen of death.  If there is anything else you need to know please ask. 


Since apache runs fine on windows and is free, I don't buy the IIS is the only thing you have to use... but out of sympathy I will try to help you,  lol.

Lets avoid cfmageget for now unless you really have a need to use it that way.  If you have PHP for your pages, just do it the normal way.  Less complexity

You should be able to just take the code you have in the cpmfetch/index.php file and insert it into your home page.  No need to use img tags or anything.

In theory this should work for you

Code: [Select]
<?php
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm('/gallery');
$objCpm->cpm_viewRandomMedia (1,1);
$objCpm->cpm_close();
?>


Let me know how far that gets you, and if it does not work, leave it in so I can see the source.  I'll be around for a bit.






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

drunkendave

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #76 on: November 23, 2005, 06:51:11 pm »

Quote
Since apache runs fine on windows and is free, I don't buy the IIS is the only thing you have to use... but out of sympathy I will try to help you,  lol.

Well that's the only thing my Webhost offers so unless I wanted to find a new one then yeah it's kinda the only thing I have to work with lol.  But that's besides the point.  I made a block with that code in it...the one thing i didn't try before and got and error that I can finally go and do a search on these boards for. 
Code: [Select]
ERROR: Path to Coppermine incorrect. (/gallery//include/config.inc.php)
Fatal error: Call to a member function on a non-object in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cpmfetch.php on line 770

So basically I have the path called out wrong somewhere and am gonna go take a look for it and check your forums.  Thanks for the quick reply also.  I'll let you know how I make out.  Thanks again.
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #77 on: November 23, 2005, 07:03:12 pm »

Quote
Since apache runs fine on windows and is free, I don't buy the IIS is the only thing you have to use... but out of sympathy I will try to help you,  lol.

Well that's the only thing my Webhost offers so unless I wanted to find a new one then yeah it's kinda the only thing I have to work with lol.  But that's besides the point.  I made a block with that code in it...the one thing i didn't try before and got and error that I can finally go and do a search on these boards for. 
Code: [Select]
ERROR: Path to Coppermine incorrect. (/gallery//include/config.inc.php)
Fatal error: Call to a member function on a non-object in C:\Inetpub\vhosts\canadianrifles.com\httpdocs\cpmfetch\cpmfetch.php on line 770

So basically I have the path called out wrong somewhere and am gonna go take a look for it and check your forums.  Thanks for the quick reply also.  I'll let you know how I make out.  Thanks again.

I see on the provider.  For my personal stuff I use e-rice.net  ($14/year) - comes with everything except shell access and backups.  But in like 3 years I've had no problems.  Anyway.

The problem you are having now is with the document_root not being picked up correctly.  A major PITA for my coding of this thing.  So you are not doing anything wrong - its IIS (and a bunch of others).

Try adding this

$_SERVER['DOCUMENT_ROOT'] = "C:/Inetpub/vhosts/canadianrifles.com/httpdocs/";

just before the

$objCpm = new cpm('/gallery');


I am not sure if that will help, but someone told me that worked for them before.







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

drunkendave

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #78 on: November 23, 2005, 07:11:24 pm »

Ok that did the trick now I just have to add some other stuff to the block and I'm all set.  Thank you very much sir.  It's always nice to see something work after working on it for many hours.  Tonight I shall drink a beer in your honour and hard work.  Thanks  ;D


P.S a friend of mine has a PHP tool on his website that I find useful in case you wanted to check it out.  http://www.canadiancod.com/modules.php?name=PHP-Nuke_Tools
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: CpmFetch - Embedding in templates (SMF, Wordpress, PHPBB, etc, ...)
« Reply #79 on: November 23, 2005, 07:15:39 pm »

Ok that did the trick now I just have to add some other stuff to the block and I'm all set.  Thank you very much sir.  It's always nice to see something work after working on it for many hours.  Tonight I shall drink a beer in your honour and hard work.  Thanks  ;D

No problem.   

Listen, about the beer... well, I tend to stick toward the better end of beers - so if its a mass produced  brand name type thing - I'd just as soon not have it drunk in my honour.  So if you get beer, get something good!

:D

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
Pages: 1 2 3 [4] 5 6   Go Up
 

Page created in 0.036 seconds with 19 queries.