Re: selecting specific tag



in article m6adnXzMRsEhX6_ZRVn-pA@xxxxxxxxxxx, Jerry Stuckle at
jstucklex@xxxxxxxxxxxxx wrote on 4/4/06 4:02 PM:

Nope. The page itself contains only information specific to that page, i.e.

<!DOCTYPE ...>
<html>
<head>
<title>...</title>
<meta...>
<?php include('header file location')

The header file contains common header elements, the </HEAD> and <BODY> tags
plus the rest of the header.


Next comes the page-specific content

This is followed by an include for the footer - which finishes the document.

So - formatting for every page can be changed by simply changing the
header/footer page.


I see. Yes, now that I think about it, you could do it that way too. You
basically are creating a template out of the two pieces of the header and
the footer, and chopping them in half, and the content area (which is on the
main page) ends up in the middle, say inside a table cell.

That would be a good way for a site you are writing from scratch.

But for my task at hand, which is "turn a straight HTML site with 100+ pages
into a dynamically served php site with consistent header, navbar, footer
areas, without rewriting, editing and renaming every page", this way works
better/easier.

(Because, in your case, every page needs to end in .php. In my case, they
can just stay as .html pages. So most of them don't even need to be touched.
They just work in the new format.) And most of the existing search engine
links and links on other site's pages that point to the site still work.

I accept that there's some risk of things breaking. Someday I'll rewrite the
whole thing from scratch. But that wasn't the goal at this point.

But thanks for the tips!

--
Stephen Kay
Karma-Lab sk@xxxxxxxxxxxxxxxxxxxx
^^^^^^^


.



Relevant Pages

  • Re: Unable to Control Header in html mail
    ... The dialog is correct - you can't preview HTML. ... If I'm following correctly, the header and footers are behaving as expected, ... Teach Yourself Outlook 2003 in 24 Hours ... > page setup all the header and footer areas are blank. ...
    (microsoft.public.outlook.printing)
  • RE: Custom Page Control
    ... default output html content and them locate the...section ... and insert our header and footer in it. ... as controls in the page's control collection and put all the controls in ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Include headers/footers when saving as HTML
    ... Considering that HTML doesn't have any concept of "pages", ... If you want one copy of the header at the top of the web "page" and one copy ... of the footer at the bottom, you'll have to put them there yourself. ...
    (microsoft.public.word.vba.general)
  • Making my FIRST fully compliant site (And Failing Miserably)
    ... I know PHP ... and HTML pretty well, CSS a bit, but ultimately, I don't know what I am ... I already have the header up there, that was step one, but now, aside ...
    (comp.infosystems.www.authoring.stylesheets)
  • How to replace a form with tesxt after it is processed?
    ... My PHP html file includes a header include, a form, and a footer include. ...
    (comp.lang.php)