Technology for generating webpages? (...but not dynamically)

10 replies
Can someone please refresh my memory?

Back in the stone ages (2000-2001), I remember learning that there were two ways to get a computer to generate your webpages. The first was dynamically, where the machine uses ASP or PHP to generate a page "on the fly".

The second way involved feeding the content for any required webpages into a script/program, which would then generate the static pages offline. The computer-generated HTML pages could then be uploaded to the server.

Can someone remind me which technology is used to do this? Would such a task normally be done with Perl scripts?
#dynamically #generating #technology #webpages
  • Profile picture of the author tonymanso
    This can be done with just about any scripting language that has access to the file system of the web server. You can use have all of your content in XML for example, and use XSLT scripts to transform the XML into HTML or any other ascii format for that matter. Can you describe your particular problem and maybe I can propose a solution?
    {{ DiscussionBoard.errors[866608].message }}
  • Profile picture of the author John Henderson
    Thanks for your answer, Tony. I'm currently refreshing my website building skills with a book on CSS; I'm hoping to build my own site, but the last site I created was in 2001 (complete with HTML tables and spacer GIFs to keep all the elements where I wanted them :rolleyes: ).

    After CSS, I expected that the next skill I would need to learn was some basic PHP, but I've been alarmed at the number of posts that I have seen from Warriors who have had their PHP sites cracked. A few have commented that static HTML pages present a much smaller opportunity for malicious exploitation, and this triggered the memory I mentioned in the opening post of there being two ways to generate pages; one server-side and one client-side.

    Perhaps a more time-efficient way to generate pages (without having to learn Perl) would be simply to save as much of the common HTML code as possible in a template in Dreamweaver (or similar program).
    {{ DiscussionBoard.errors[867568].message }}
  • Profile picture of the author tonymanso
    It might be good to use a program such as NVU, FrontPage or DreamWeaver that lets you build and publish HTML sites. Like you said you can use templates to define the look and feel of the overall site, and simply create pages that use the templates. Once the work is done you can publish the whole site in one shot using any of the above mentioned programs.
    {{ DiscussionBoard.errors[869659].message }}
    • Profile picture of the author John Henderson
      Originally Posted by tonymanso View Post

      It might be good to use a program such as NVU, FrontPage or DreamWeaver that lets you build and publish HTML sites. Like you said you can use templates to define the look and feel of the overall site, and simply create pages that use the templates. Once the work is done you can publish the whole site in one shot using any of the above mentioned programs.
      That sounds like a great plan, Tony!
      {{ DiscussionBoard.errors[871117].message }}
  • Profile picture of the author yaji
    Dynamic page is still the way to go, as your web site expands. because now is different from years ago, people wanted personalized info and they wanted to add their info, all dynamically.

    To prevent attacks: add security check into your code; back up your site more frequently.
    Signature

    Thanks, Yaji

    Hypnosis Weight Loss Fun Info about Hypnosis Weight Loss | Cheap Car Insurance
    Cat Dandruff All about Cat Dandruff. A Must-Read for Cat Lovers

    {{ DiscussionBoard.errors[870729].message }}
    • Profile picture of the author John Henderson
      Originally Posted by yaji View Post

      Dynamic page is still the way to go, as your web site expands. because now is different from years ago, people wanted personalized info and they wanted to add their info, all dynamically.

      To prevent attacks: add security check into your code; back up your site more frequently.
      You're right Yaji, when the time comes to allow users to alter pages, I'll have to employ PHP or something similar. In the meantime, I'll stick to static pages -- that will be one less thing for me to worry about while I'm "learning the ropes" of IM.
      {{ DiscussionBoard.errors[871126].message }}
  • Profile picture of the author GB2008
    For my money - I would start learning PHP now. You're on a learning curve anyway, so why learn HTML and then learn PHP? You can still create static pages, but generated through PHP, and on the way you'll get a handle on creating functions and include files (to save a lot of repetitive typing). Then, when it's time to start being a little more creative with dynamic content, modifying your website won't require a complete re-write...

    As far as having PHP websites "cracked" - just be smart about any information you gather in forms and any scripts receiving POST or GET variables (you'll learn about those as you go ) - if your script is not open to receiving any information from the viewer, then how can they hack your code? And as you start requesting information from your viewers, there are plenty of PHP samples out there to filter out bad inputs and protect you.
    Signature
    {{ DiscussionBoard.errors[884943].message }}
  • Profile picture of the author HomeComputerGames
    A lot depends on how large your site is going to be and what you do with it.
    Implementing a shopping cart with static pages just won't happen.
    If you have 100,000 pages, upkeep will overwhelm you plus it would take years to create all of the pages.

    To battle both the hacking issues and to give an SEO friendlier site I am working on a system to make html pages from most of my dynamic pages.
    If a page ever needs to be changed you update via the administrator that updates the pages content in the database and also rewrites that specific .html page with the new content.
    This way the site is static in sorts but also has dynamic capabilities.
    Signature

    yes, I am....

    {{ DiscussionBoard.errors[889726].message }}
  • Profile picture of the author robdraw
    I agree with GB
    I use all the time a half / half solution First I create the pages statically then cut and paste the divs into their own files and call them from the main file. This way when you change one div it changes site wide, also for example I may want to put certain elements on one page and not another, like a banner add in the left column. Using this method I just call that file. You dont have to know much PHP for that either. Just how to call an external file into the script which is done like so
    Example
    <!-- Start of Header -->
    <?php include "includes/html/header/index_header.html";?>
    <!-- End of Header -->
    <!-- Start of Left box and nav menus -->
    <?php include "includes/html/column/left_column.html";?>
    <!-- End of Left box and nav menus -->
    <!-- Start of Right box and affiliation menus -->
    <?php include "includes/html/column/right_column.html";?>
    <!-- End of Right box and affiliation menus -->
    <!-- Start of main Contents -->
    <?php include "includes/html/contents/main_contents.html";?>
    <!-- End of main Contents -->
    <!-- Start of Footer -->
    <?php include "includes/html/footer/footer.html";?>
    <!-- end of Footer -->

    This is a bit time consuming to start but saves loads of time in the long run as you make a new page all you need to do is copy into it the files you want to use.
    Also as you advance with PHP you can update easier with more dynamic functions.
    {{ DiscussionBoard.errors[890406].message }}
  • Profile picture of the author locpicker
    Beware of sql injection when using php with mysql as well. You can lose control of your databases. I am just studying this myself so i do not have all information on this yet but from what I have been reading someone can do a lot of damage to your website and even hijack it.
    {{ DiscussionBoard.errors[1033100].message }}

Trending Topics