Hi
At the moment I get my data for my WebPages from simple html files that I have to, cut and paste there title, body sections into my template file which has all my custom look and feel for my website. So the files get created automatically based on there title and I don't have to cut and paste the title and body of the simple html page into afree templates, and name it manually. Any scripts out there.
Thank
PHP/HTML Programmers How Do I Create Html Pages Dynamically?
This isn't just solvable by scripts. Learn Javascript, DOM, PHP and MySQL and then you can do anything, though you need to design first.
For instance changing the title will be in DOM document.title = 'new title'; in PHP you would generate the <TITLE>/<TITLE> thingy in the head section. PHP on the other hand works on a webserver and DOM at the client. See, the complication starts... were to put/do what on the server side or on the client side.
This is all fun... ofcourse but takes a lot of time.
For instance changing the title will be in DOM document.title = 'new title'; in PHP you would generate the <TITLE>/<TITLE> thingy in the head section. PHP on the other hand works on a webserver and DOM at the client. See, the complication starts... were to put/do what on the server side or on the client side.
This is all fun... ofcourse but takes a lot of time.
Author of COBOS
- AndrewAPrice
- Member
- Posts: 2299
- Joined: Mon Jun 05, 2006 11:00 pm
- Location: USA (and Australia)
Place your header/footer (along with all styling info) into separate pages.
Then you can either:
- Place your header/footer into a frame (don't do this unless you want a pre-2000-ish look for your site).
- Use Javascript to include the header before your content, and the footer after.
- Find out what server side language your webhost supports (most likely ASP.net (Windows server) or PHP (non-Windows server)). Then use PHP/ASP.net to include your header/footer (the easiest and my recommended way).
- Use a WYSIWYG HTML editor that supports dynamic content and will automatically insert and update your header/footer for you on each page. Expression Web comes to mind.
Then you can either:
- Place your header/footer into a frame (don't do this unless you want a pre-2000-ish look for your site).
- Use Javascript to include the header before your content, and the footer after.
- Find out what server side language your webhost supports (most likely ASP.net (Windows server) or PHP (non-Windows server)). Then use PHP/ASP.net to include your header/footer (the easiest and my recommended way).
- Use a WYSIWYG HTML editor that supports dynamic content and will automatically insert and update your header/footer for you on each page. Expression Web comes to mind.
My OS is Perception.
- AndrewAPrice
- Member
- Posts: 2299
- Joined: Mon Jun 05, 2006 11:00 pm
- Location: USA (and Australia)
For a static page, it's best to put everything server side for several reasons. For dynamic content (real-time counters, etc) then you need to use client side.os64dev wrote:See, the complication starts... were to put/do what on the server side or on the client side.
My OS is Perception.