Page 1 of 1

Offline stuff

Posted: Sun Jun 15, 2008 5:09 pm
by Ppaiem
Hey! I have a an offline html website and would like to make an internal link to an offline php application in my php root directory. I know I can run an application using 127.0.0.1/index.php, but I want to have a <a href=index.php>BLOG</a> or something similar in my html website and have the app run in a frame.

How do I do that?

Re: Offline stuff

Posted: Sun Jun 15, 2008 7:08 pm
by John Cartwright

Code: Select all

<a href=http://localhost/index.php>BLOG</a>
?

Re: Offline stuff

Posted: Mon Jun 16, 2008 8:39 am
by Ambush Commander
Jcart's link should work. Ideally, the HTML pages should also be served by your webserver.

Re: Offline stuff

Posted: Mon Jun 16, 2008 8:59 am
by Greenconure
Ppaiem wrote:Hey! I have a an offline html website and would like to make an internal link to an offline php application in my php root directory. I know I can run an application using 127.0.0.1/index.php, but I want to have a <a href=index.php>BLOG</a> or something similar in my html website and have the app run in a frame.

How do I do that?
If you want to show the page in a frame in a page, you need to first set up a frame.
The following code will create a frameset with two frames. The first sized at 25% of the page and the second at 75% of the page.
This makes two vertical (Side-by-side) frames. To create horizontal (on top of each other) frames, change "cols" to "rows"

Code: Select all

 <frameset cols="25%,75%">   <frame src="FILE NAME HERE" name="NAME OF FRAME">   <frame src="FILE NAME HERE" name="NAME OF FRAME"></frameset> 
To have a link open in a specified frame:

Code: Select all

 <a href="URL" target="NAME OF FRAME">LINK TEXT</a> 
Further Reading & References:
W3 Schools: HTML Frames - http://www.w3schools.com/Html/html_frames.asp
Page Resource: Frames 2: Linking and Attributes - http://www.pageresource.com/html/frame2.htm