Previous Thread
Next Thread
Print Thread
Rate Thread
Joined: Mar 2001
Posts: 644
Member
Member
Offline
Joined: Mar 2001
Posts: 644
I've searched the net and dug through so many sites I'm cross eyed.

So, I'm hoping one of you wizards will have the answer.

Basically, I am running a Perl based album on my site, integrated to use the Threads database for authentication.

What I'd like to do is call a built in SSI function that was created to select a random photo from the album.

Problem is, any time I do the include, it throws an error.

Any thoughts or ideas folks?

Sponsored Links
Joined: Mar 2001
Posts: 644
Member
Member
Offline
Joined: Mar 2001
Posts: 644
Ok, guessing this is either:

a) Not possible

or

b) No one knows a way to do it.

I might just re-write the SSI into a PHP script, will be easier in the long run I guess.

Joined: Aug 2000
Posts: 1,290
Addict
Addict
Offline
Joined: Aug 2000
Posts: 1,290
what include syntax are you using, and what type of page?


- Custom Web Development
http://www.JCSWebDev.com
Joined: Oct 2000
Posts: 117
Member
Member
Offline
Joined: Oct 2000
Posts: 117
got a link? there's several ways to pull an ssi perl file into a php page


Duke

"Life is tough, it's tougher if you're stupid."
Joined: Oct 2000
Posts: 117
Member
Member
Offline
Joined: Oct 2000
Posts: 117
try one of these 2 to begin

Code
<br /><?php virtual('/url to/album.cgi');<br />?><br />


Code
<br /><?php print implode("\n", file("http://www.yoursite.com/url to/album.cgi"));<br />?><br />


Duke

"Life is tough, it's tougher if you're stupid."
Sponsored Links
Joined: Mar 2001
Posts: 644
Member
Member
Offline
Joined: Mar 2001
Posts: 644
Hmm that's a new one there DukeofUrl. Haven't tried the implode statement. I'm only about 1/3 of the way through my PHP book. Learning as I go and enjoying every minute. hehe

Ok, the album in question is Mike Bobbitt's album script. Which I love. And love even more since he added in the ability to authenticate based on my .threads user database.

The URL to my album is http://album.sofguild.com, the built-in SSI grabs a thumbnail of a random image. Works fine if you click the link, http://album.sofguild.com/cgi-bin/album/album.pl?random=1;ssi=1, but throws errors when included on a PHP page.

I can't give the PHP code just now, since I'm at work, but will drop by this evening and paste the code I'm currently using. Basically I've tried a variety of include statements, using URL and disk paths.

Here's the error thrown by my site, I'm including this in a PAL box, using the IIP index page.

Code
<br />Warning: Failed opening 'http://album.sofguild.com/cgi-bin/album/album.pl?random=1;ssi=1' for inclusion<br /> (include_path='.;c:\php4\pear') in c:\webs\sofguild\threads\pals\custombox5pal.php on line 30<br />


FYI, line 30 is the include statement, I'm pretty sure I need to clean up the included URL, probably not liking the ; in there.

Thanks all.

Joined: Oct 1999
Posts: 282
Enthusiast
Enthusiast
Offline
Joined: Oct 1999
Posts: 282
<?php virtual('/url to/album.cgi');?> won't work if your provider runs PHP in cgi mode. That once was the problem in my case

Joined: Mar 2001
Posts: 644
Member
Member
Offline
Joined: Mar 2001
Posts: 644
[]
Code
 <br /><?php print implode("\n", file("http://www.yoursite.com/url to/album.cgi")); <br />?> <br />
[/]

That did the trick! YAY.

Thanks for the suggestions everyone.

Virtual doesn't work on my server, I had tried it already. I run my own server from my house, so umm... I'm my own host.

Man I love this site. Don't know why I don't ask stupid questions of you guys more often.

[EDIT: For those who want to see it in action, it's on my index page here. ]

Last edited by Zackary; 08/05/2003 6:03 PM.

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
badfrog
badfrog
somewhere on the coast of Maine
Posts: 94
Joined: March 2007
Forum Statistics
Forums63
Topics37,575
Posts293,931
Members13,823
Most Online6,139
Sep 21st, 2024
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,834
Greg Hard 4,625
Top Posters(30 Days)
Gizmo 1
Top Likes Received
isaac 82
Gizmo 20
Brett 7
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2025 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.1
(Snapshot build 20240918)