views:

303

answers:

5

Hi friends,

I have created a site, which parses XML files and display its content on the appropriate page. Is my site a dynamic web page or static web page?

How do dynamic and static web pages differ?

I feel it's dynamic, because I parse the content from xml files; initially i don't have any content in my main page..

What do you think about this, please explain it..

+1  A: 

Static web pages would be plain HTML content that are delivered. If you are processing any type of XML files at the server side and generating content accordingly, this is a dynamic page. Static pages change content when the page is actually edited & modified.

First result on Google if you had searched for it explains it. http://websiteowner.info/articles/pages/pagetypes.asp

Also, stating that static websites are not updated regularly is not correct. The web and HTML was around even before we started writing stuff in Perl & PHP. There are/were sites that had heavy traffic and were being modified manually.

Arvind
+3  A: 

I would describe your pages as dynamic. "Static" usually means that the file sitting on the web server is delivered as-is to the user; since you're assembling the pages from data files, I'd call them dynamic even if you're not building in any dynamically-changing data.

I don't think this is a hard and fast definition though. If someone feels the page is static because it's assembled from static pages, that's another way to look at it.

fenomas
+1  A: 

a simple way to distinguish between static and dynamic:

Static: straight HTML files

Dynamic: HTML is generated through server-side code and a data store(XML, database, etc.)

Andrew Van Slaars
What if those straight HTML files are stored in a database? Does the data coming from a database mean it's a dynamic website, even if the content is only ever manually edited?
dbr
That's an interesting question. It seemed like a simple question so I provided a simple answer. I guess what you are suggesting could be up for debate. If there is code deciding what to display from the database, I would call it dynamic since they still aren't using plain HTML alone.
Andrew Van Slaars
+2  A: 

This is actually an interesting question..

I would have said it's a dynamic website, as the content is generated programmatically.. but if the XML files do not change, it's no less "static" than straight HTML files served though Apache.

Say you have a site that is regular HTML files - it would be considered a static web-page; but if you take those HTML files, store them in a database, and have a simple page that allows /view.php?page=index - does that make it a dynamic site?

I would say no, it's just a static site served through a database, or XML files (instead of a file-system).

Basically: if the content changes without you manually editing those XML files, I would say it's a dynamic site. If it does change, then I would say it's a static site.

dbr
+1  A: 

KISS - Dynamic pages change without changing the page itself.

Your pages are dynamic, because once deployed the content can be changed without changing the page's HTML.

Any content that is fixed and always renders the same is considered Static.

Rob Cooper