Quote:
Originally Posted by theFez
you're having problems with this because php wants to execute included files. it works for including functions or somethign like that, but if you try to include a .jpg file it will either display the jpeg as ascii values or will blow up. if you want to include a file to display a jpeg the file needs to return a jpeg, not a stream of text.
Perhaps if you could explain what you are trying to do a little better it will be easier to help you.
|
Certainly, I have a template at
www.arch13.com/splash.php that currently has a jpg in the center of it. I want to make this area dynamic so that when the page is arrived at, the jpg is loaded, but the user can then click on the navigation links at the top and the jpg wil be replaced with an included text file depending on what link is clicked.
In other words, the dynamic area loads the jpg specified by the
else {
include("arch13tag2.jpg");
}
line in the php. When a link is clicked that take the form splash.php?id=main.php then main.php is loaded into the content area replacing the jpg default.
This way my text files in php form (ie main.php) are loaded into the content area and can present the desired information to the visitor.
I'm trying to understand how I can modify the origional code so that the links load this content
and handle the occasional jpg.
Further down the road, I'd like to make my dynamic included php files have a split table and would be interested if anyoe knows if the php synatx of ?id=xxx can handle two variables so that different content could possibly be loaded into a split table form. That way the visitor arrives and sees the arch13tag2.jpg at arrival, clicks on links and they are loaded into the content area replacing the arch13tag2.jpg. If the included php that is desired has a table (in this case a split pane of thumbnails on the left and a second content area on the right), then they can click on the thumbnails and they appear in the right content area.
My understanding is that that would require that the url have the variable calling the included php file containing the split table with thumbs and child content area
and a second variable calling a larger version of a clicked thumb into the child content area.
I'm afraid that I'm just getting confusing now.