Including file

  • inewview
  • Born
  • Born
  • inewview
  • Posts: 3
  • Loc: Toronto

Post 3+ Months Ago

Whats the easist way of including a remote html file in a window? I used Iframes, but they suck. Any php way of doing it? Anyone have a snippet?
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • Johan007
  • Guru
  • Guru
  • User avatar
  • Posts: 1080
  • Loc: Aldershot, UK

Post 3+ Months Ago

Make a page then re-name it to .php file then place this where you want the new code (maybe nested inside one of your table) this is VERY much more simple than frames:

Code: [ Select ]
<?php include("menu.htm") ?>


Or in ASP its maybe a little tricky at first so best look it up on the web but its something like this:

Code: [ Select ]
<!-- #Include virtual="/page.asp" -->
  • inewview
  • Born
  • Born
  • inewview
  • Posts: 3
  • Loc: Toronto

Post 3+ Months Ago

This is the site I am working on, http://www.inewview.com/clients/mls/new.shtml copied onto my local server and put in using iframes. The issue with this site is that the search box on the right is being hosted on a third server, and needs to have some way of being included even though it is on a remote server. I think it dosent look so great now, and every link opens in the same field, which is not what I am looking for at all. Is it possible that a click in that box would open in a new field? (I dont have access to the code on that page)
  • Johan007
  • Guru
  • Guru
  • User avatar
  • Posts: 1080
  • Loc: Aldershot, UK

Post 3+ Months Ago

erm what is shtml?
  • inewview
  • Born
  • Born
  • inewview
  • Posts: 3
  • Loc: Toronto

Post 3+ Months Ago

Web pages that contain SSIs (server side include) often end with an shtml extension, though this is not a requirement. The filename extension enables the Web server to differentiate those pages that need to be processed before they are sent to the browser.
  • _Leo_
  • Proficient
  • Proficient
  • User avatar
  • Posts: 279
  • Loc: Buenos Aires, Argentina

Post 3+ Months Ago

Well, you will need server side scripting for this.

In PHP:

Code: [ Select ]
include('http://www.foreing.com/file_to_include.html');
  • Johan007
  • Guru
  • Guru
  • User avatar
  • Posts: 1080
  • Loc: Aldershot, UK

Post 3+ Months Ago

inewview wrote:
Web pages that contain SSIs (server side include) often end with an shtml extension, though this is not a requirement. The filename extension enables the Web server to differentiate those pages that need to be processed before they are sent to the browser.

Is that using PHP or any server side thats installed on the server? I always end mine in PHP or ASP!
  • rjstephens
  • Professor
  • Professor
  • User avatar
  • Posts: 774
  • Loc: Brisbane, Australia

Post 3+ Months Ago

NO, that's talking about something completely different. End php with .php, and asp with .asp. SSI (server side include) is a different language entirely.

http://www.w3.org/Jigsaw/Doc/User/SSI.html
  • _Leo_
  • Proficient
  • Proficient
  • User avatar
  • Posts: 279
  • Loc: Buenos Aires, Argentina

Post 3+ Months Ago

That's right, you need PHP support, and name your file .php

If you don't have any idea of PHP, start by reading something about it. http://www.php.net
It's a little more complex than SSI but a lot more powerful.

Post Information

  • Total Posts in this topic: 9 posts
  • Users browsing this forum: spork and 88 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.