PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming LanguagesPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old February 16th, 2000, 07:54 PM
diana diana is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2000
Posts: 5 diana User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Can I have PHP and SSI output on the same page?

If so, what do I need to add to my .htaccess file? I've tried various combinations, but so far I've managed to get only one or the other on my page.

Any help appreciated.
Thanks, Diana.

Reply With Quote
  #2  
Old February 17th, 2000, 11:25 AM
SneakyDave SneakyDave is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 1999
Posts: 3 SneakyDave User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
If you have Apache Web Server, you may be able to use the virtual() command in PHP to do SSI:

Exmample:
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">code:</font><HR><pre>
if($banner):
virtual('/cgi-bin/banner.cgi');
endif;
[/code]

Its the only thing I've ever got to work.

Reply With Quote
  #3  
Old February 17th, 2000, 07:42 PM
diana diana is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2000
Posts: 5 diana User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Thanks Dave

I have, as you suggest, managed to mimic SSI using include and virtual. This is all I need most of the time. I would like to be able to use true SSI sometimes though on a page that also uses PHP. I suspect it's possible by tweaking the .htaccess. If I'm wrong would someone please let me know?
(And if I'm right, how do I do it?)

Thanks a lot,
diana.

Reply With Quote
  #4  
Old February 18th, 2000, 07:47 AM
rod k rod k is offline
Apprentice Deity
Dev Shed Loyal (3000 - 3499 posts)
 
Join Date: Jul 1999
Location: Niagara Falls (On the wrong side of the gorge)
Posts: 3,237 rod k User rank is Private First Class (20 - 50 Reputation Level)rod k User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 4 m 8 sec
Reputation Power: 17
Send a message via AIM to rod k
I'm curious why you want to do this? There isn't anything that you can do using SSI that can't be done in PHP.

Reply With Quote
  #5  
Old February 18th, 2000, 09:05 AM
PAV PAV is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 1999
Location: Netherlands
Posts: 77 PAV User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 14
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by rod k:
I'm curious why you want to do this? There isn't anything that you can do using SSI that can't be done in PHP.[/quote]

Well, I had the same problem. That is, if PHP isn't installed as an Apache module, you can't use the virtual() function.

Reply With Quote
  #6  
Old February 18th, 2000, 09:27 AM
rod k rod k is offline
Apprentice Deity
Dev Shed Loyal (3000 - 3499 posts)
 
Join Date: Jul 1999
Location: Niagara Falls (On the wrong side of the gorge)
Posts: 3,237 rod k User rank is Private First Class (20 - 50 Reputation Level)rod k User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 4 m 8 sec
Reputation Power: 17
Send a message via AIM to rod k
I was referring to non-virtual() type SSI. Re-read the post I was replying to.

Reply With Quote
  #7  
Old February 19th, 2000, 07:28 AM
diana diana is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2000
Posts: 5 diana User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
I have a 100-page+ site with lots of includes and scripts with SSI calls. I'm moving to a new server which supports PHP. I would like to add PHP functionality, without having to change everything.

Reply With Quote
  #8  
Old February 21st, 2000, 08:33 PM
diana diana is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2000
Posts: 5 diana User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
So now that we've established WHAT I want to do, and WHY I want to do it, does anyone know HOW ?
:-}

Reply With Quote
  #9  
Old February 21st, 2000, 09:38 PM
'tantrum 'tantrum is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2000
Posts: 79 'tantrum User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 14
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by diana:
So now that we've established WHAT I want to do, and WHY I want to do it, does anyone know HOW ?
:-}
[/quote]

Includes can be done in php using the include() function.
eg <? include ("header.txt") ?>

What kind of "scripts with SSI calls" do you have?


Basil

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPHP Development > PHP and SSI on the same page?

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap