I have a web page that is currently using 2 frames. The left frame has buttons to select what appears in the right frame. I need to stop using frames, and was told PHP would do that.
I have done some studying at w3schools.com and I think something like this would work, but I am missing something major.
<?php
if ($_GET["page"] == "home")
include("home.php");
else if ($_GET["page"] == "info")
include("info.php");
?>
I want to use CSS and think it should look somethign like
#select {
float: left;
margin-left: 2px;
width: auto;
}
#display {
float: right;
width: auto;
}
At this point, I am stuck. I need to get my buttons on the left, and make something display on the right.
This newbie will appreciate any pointers.
Bill
17 2952
I need to stop using frames, and was told PHP would do that.
Dunno why you were told that; PHP and frames are like apples and celery.
At this point, I am stuck. I need to get my buttons on the left, and make something display on the right.
This newbie will appreciate any pointers.
This is really a CSS question. You have the right idea using the float property, though.
Here are a couple of resources you might find helpful: http://www.saila.com/usage/layouts/ http://www.glish.com/css/
You probably want to look into using SSI - Server Side Includes. They work like a charm and they are much better than frames. I recently made the switch and I'm not looking back.
The problem lies in setting the width to auto which is setting them to the width of the screen. Give that some actual dimension and that will solve it.
You probably want to look into using SSI - Server Side Includes. They work like a charm and they are much better than frames. I recently made the switch and I'm not looking back.
I am already using SSI to load things that appear on all pages of the site.
What I need is a way to eliminate frames and select a file from a left column and have it appear in the right column.
The problem lies in setting the width to auto which is setting them to the width of the screen. Give that some actual dimension and that will solve it.
I have set the left most division to 170PX, but the right division still drops to below the left division.
I want the right division to have an automatic width so various window sizes will have proper word wrap.
Then there must be more going on here than what we see. After rethinking this, the div should not be dropping below the other even when width is set to auto. You're going to need to post the complete code or a link.
As far as copying stuff form one div to the other, that's only accomplished with a programming language and you would have to ask about that on the appropriate programming board.
Then there must be more going on here than what we see. After rethinking this, the div should not be dropping below the other even when width is set to auto. You're going to need to post the complete code or a link.
As far as copying stuff form one div to the other, that's only accomplished with a programming language and you would have to ask about that on the appropriate programming board.
First, here is the link http://www.roberson-family.com
Second, I posted the original message in the PHP forum, and it was moved here. I will try again in the PHP forum.
Bill
Your doctype is incomplete and puts IE into quirks mode. See the sticky at the top of this board. Use html4.01 strict. Then validate both your html and css for your list of errors that need correcting.
Your doctype is incomplete and puts IE into quirks mode. See the sticky at the top of this board. Use html4.01 strict. Then validate both your html and css for your list of errors that need correcting.
I have validated the page as is, and the only thing that does not validate is a bit of script from Accuweather.com.
I agree that the doctype is not the latest, but it does validate. I just now ran it past the validation, and it passed.
I actually have some code that will not work with html4.01 strict, so the page will have to remain transitional until I find a solution for that code.
I have also validated the CSS file.
Bill
It doesn't matter that the validator uses your doctype. Browsers, particularly IE, go into quirks mode when the doctype is incomplete and yours is incomplete.
You have one CSS error but at least 13 html errors. Some aren't even reported by the validator. For example, you are using <span> on block level elements but span is for inline. Your css at the top is also missing an identifier.
If you wish to use some of that deprecated code, then transitional is necessary but you still must use the appropriate one. See the sticky at the top of this board.
It doesn't matter that the validator uses your doctype. Browsers, particularly IE, go into quirks mode when the doctype is incomplete and yours is incomplete.
You have one CSS error but at least 13 html errors. Some aren't even reported by the validator. For example, you are using <span> on block level elements but span is for inline. Your css at the top is also missing an identifier.
If you wish to use some of that deprecated code, then transitional is necessary but you still must use the appropriate one. See the sticky at the top of this board.
I have redone my home page so that everything works in Firefox, except the layout of the two columns using DIV and CSS. I think what I need to understand is how to get the CSS correct. The code in my CSS reads:
#weather{
float: left;
margin-left: 2px;
width: 170px;
}
#announcement {
float: left;
margin-left: 2px;
width: auto;
}
I then have in my HTML code the DIVs:
<div id="weather">
<?php include($DOCUMENT_ROOT . "/incl/weather.php"); ?>
</div>
<div id="announcement">
<!-- announcements located here -->
</div>
When viewing with Firefox 2.0.0.3, the announcements are below the weather. What do I need to change in the CSS file to make it work properly?
Bill
Several of the errors seem to be caused by the use of an ampersand (&). The line refers to a page named J&JBaby.PHP
Is the ampersand something I should avoid?
Bill
Several of the errors seem to be caused by the use of an ampersand (&). The line refers to a page named J&JBaby.PHP
Is the ampersand something I should avoid?
In general, yes, because ampersands are used to separate variables in a query string (e.g., page.php?mode=view&id=5&orderby=name&orderdir=asc) .
As a way of ensuring that your content will work as intended in all browsers, you should either remove ampersands from your file names, or encode them as '%26'.
In general, yes, because ampersands are used to separate variables in a query string (e.g., page.php?mode=view&id=5&orderby=name&orderdir=asc) .
As a way of ensuring that your content will work as intended in all browsers, you should either remove ampersands from your file names, or encode them as '%26'.
I have removed ampersands from the file names on my site and fixed all the code except for locations where I am describing something like "fast & quick" in text. Do I need to replace those with "%26" or is this an acceptable use?
Bill
In html, & should be replaced with &
In html, & should be replaced with &
Thanks. I will get to work changing my pages.
Bill
Sign in to post your reply or Sign up for a free account.
Similar topics
by: Ray in HK |
last post by:
What are the differences between LOAD DATA INFILE and LOAD DATA LOCAL INFILE
?
I found some web hosting company do not allow using LOAD DATA INFILE but
allow LOAD DATA LOCAL INFILE. The reason...
|
by: jen_designs |
last post by:
Can you load 2 xml files on an html page via javascript? I can get one
xml file to load, using the following code. How about two. I need to
combine 2 xmls files on the client. Any other way to...
|
by: Jim Heavey |
last post by:
Hello, I am walking through the ASP.Net book by Dino Esposito. I created a
new project and used the "add existing" option to add the files to my new
project. He had all of the code on a single...
|
by: John Alesse |
last post by:
Hi, I've created a very simple winforms control using the c# wizard in VS .net 2003 that is nothing but a System.Windows.Forms.UserControl. There are no other controls on the form
It takes IE 12...
|
by: Don Wash |
last post by:
Hi All!
I'm getting the following Error:
No DLLs has been compiled yet and nothing in the \bin directory. So it is
not the versioning problem or anything like that.
And here are the...
|
by: GeekBoy |
last post by:
Okay, I have two identical web servers running Windows 2003 web
server. I have an ASP.NET application which runs great on one of
them. Dedicated IP address, behind our firewall, etc. Everyone's...
|
by: Sascha |
last post by:
Hi there,
I searched carefully through the web before finally deciding to post
this message, because I could not find a solution for my problem.
Hopefully someone will have a hint or explanation...
|
by: sylcheung |
last post by:
Hi,
How can I be notified when the document load is complet in JavaScript?
I am referring to the whold document load is complete, mean all
images/external files/frame/iframes have been loaded.
...
|
by: Jim McGivney |
last post by:
In Web Developer Express I make a very simple aspx page. The page name is
Hoho.aspx. The page has a label, the label text is "Hello World".
To test the page on my computer, I press CTRL-F5 and the...
|
by: joshuaRR |
last post by:
Hello all.
I am trying to load a page using CSS, because the website does not allow script to be used on thier site. I was trying to enter sounds files using onmouseover on certain texts & images...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: ryjfgjl |
last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
| |