html & css v's php

preacher33

New Member
What is the current 'standard' in relation to designing web site's? Is it recommended that they include php? Or are there drawbacks to including php?
 

LouTheDesigner

New Member
It would completely depend on the site's intended function. If it is meant to be a static site that just describes a company or service, or to showcase a wedding photo gallery for exampele. then I don't see any reason to utilize PHP. An exception here would be if those sites need a contact form, in which case only the contact form will be using php.

So the question isn't, "What is the current 'standard'?" but rather, "What is the right tool for the job?"

-Lou
 

smoovo

New Member
HTML & CSS is the body and style of your pages, and they are static content. They are the content that your browser show to you and to your visitors. PHP is a language that "speaks" with the server, ask and gets results. PHP can't be visible to you or to your visitors through the browser.

So why use PHP? for things you need to make conversation with the server. Get information from the server, calculate things, handle users input, and more.

To send "contact form" from your website you should use PHP, your page will be built with HTML & CSS, and the function mail() in PHP will tell the server to take your inputs and send them to your predefined email.

More uses of PHP is with dynamic pages. Let's say you have one banner and menu to all of your pages header, we make one HTML page with the header and we include it to all of our pages with PHP code. The power comes when you change things in this HTML page it appears in all of the pages.

- Enjoy. :)
 

dzwestwindsor

New Member
HTML = text
CSS = styles and theming
PHP = dynamic operations, like contact forms (as mentioned by smoovo), login/logout, create/delete content, etc

HTML/CSS are pretty much standard. No matter what kind of web developer you are, you need to use HTML and CSS.

The dynamic language on the other hand, is up to you. I always look at PHP as the long time standing "classic" web programming language. It's been around for a while, and it currently its the most used language. However, I rarely code with PHP (unless I have to), because I prefer to use Ruby on Rails. I'm not saying PHP is bad (I dont want to start a flame war), I just don't prefer it. I think it's messy code and I don't enjoy coding in it. But it's still a great language for overall needs

and it's a great place to start.
 

preacher33

New Member
Hi all,
Thank you for the info. I am about to set up a site and it will have approx 20 pages with a static header, footer and sidebar. I was thinking of attempting it in PHP for the reasons mentioned by smoovo in that one design of sidebar and head and footer will suffice and use includes to display the main info in the main part of the page.
The client has a specific layout required for the site and I have attempted to design it using css, but the result in their browser (IE of course):mad: is not displaying as they require. Thence I have had to resort to tables which I am not happy with but cannot see any other way around. I was hoping php would solve this problem. Am I mistaken?

Preacher
 

dzwestwindsor

New Member
PHP won't help you if you have a layout display problem.

Layouts are done with CSS; PHP is the programming portion that handles the backend programming. CSS is what does the layouts and styles, PHP won't help you with that

Maybe you can start a thread with your problem, post some code, a URL, and see if we can help you?
 
Top