Jump to content

  • Log in with Facebook Log in with Twitter Log In with Google      Sign In   
  • Create Account

Subscribe to HRA Now!

 



SEO Class in Chicago, IL

Learn How To Optimize Your Website on July 26, 2013


Looking for personalized in-depth SEO training among your peers?



High Rankings is offering a 1-day customized SEO training class in Chicago. Class size is limited so please sign-up now if you want in!



 


Are you a Google Analytics enthusiast?

Share and download Custom Google Analytics Reports, dashboards and advanced segments--for FREE! 

 



 

 www.CustomReportSharing.com 

From the folks who brought you High Rankings!



Photo
- - - - -

Html Vs Php Vs Asp Etc For Ecommerce


  • Please log in to reply
24 replies to this topic

#1 doogie88

doogie88

    HR 4

  • Active Members
  • PipPipPipPip
  • 260 posts

Posted 25 July 2007 - 07:47 AM

Hello
I am a little lost here. I'm new to complete ecommerce sites, but I'm helping someone with one.
I mostly know html, so I don't exactly know how ASP/PHP/PERL work.

But how is using something like PHP better/easier than making the pages in HTML?
What benefits does PHP have?

And if I use something like Oscommerce, do I need to know PHP?

#2 torka

torka

    Vintage Babe

  • Moderator
  • 4,408 posts
  • Location:Triangle area, NC, USA, Earth (usually)

Posted 25 July 2007 - 09:02 AM

At the most basic level, using PHP (and ASP et.al.) allows you to "include" standard recurring portions of page code so that you don't have to type/edit the information on every page. Say, for instance, you have your company name, address and phone number in the footer of every page. (This is a good idea, BTW, especially for brick-and-mortar businesses targeting a local audience. But I digress.)

Then, let's say the post office decides to change your ZIP code. (This actually happened in my town a couple of years ago.) If your pages are in HTML, you'll have to update and upload every page of your site. With an "include" set up, all you'd have to do is edit and upload one file -- the one that contained that footer text -- and the correction would automatically show up on every page of your site.

Beyond that, any scripting language (like PHP, ASP, etc.) will also allow you to add interesting scripts that can -- when employed thoughtfully -- greatly enhance the functionality and user-friendliness of your site. Ultimately, you could even build an entire content management system and run your entire website off of a database, making it very very easy to add/update/delete content using a simple browser-based interface.

That's what most blog software and content management systems do. I use WordPress for managing almost all of my websites, and I believe it's written in PHP.

As to whether you need to know PHP to use osCommerce, I don't think it's an absolute requirement. It does make things a lot easier if you find you need to tweak the functionality to meet your specific needs, and I would say at least a passing knowledge makes it easier to install add-ons and keep everything running smoothly, but you can probably get by without an in-depth knowledge of PHP.

My penny.gif

--Torka mf_prop.gif

#3 doogie88

doogie88

    HR 4

  • Active Members
  • PipPipPipPip
  • 260 posts

Posted 25 July 2007 - 09:04 AM

Thank you, that was quick smile.gif


#4 AlDugan

AlDugan

    HR 5

  • Active Members
  • PipPipPipPipPip
  • 467 posts
  • Location:Keene, NH

Posted 25 July 2007 - 10:46 AM

Also keep in mind, if you want to build your site in just plain html and then learn PHP as you have the time do yourself a favor and save your web pages with the .php extension now. You don't have to actually have any .php code on them yet but if you end up wanting to add PHP functionality later your pages will be ready and you won't have to set up any redirects from your old .html pages to your new .php pages because you gave them the .php extension from the beginning.

#5 Jill

Jill

    High Rankings Advisor

  • Admin
  • 32,379 posts

Posted 25 July 2007 - 12:12 PM

That's a really good tip, Al! Don't think I've ever heard that one anywhere, although it makes good common sense.

#6 Priest

Priest

    HR 2

  • Active Members
  • PipPip
  • 35 posts
  • Location:Milwaukee, WI

Posted 25 July 2007 - 04:05 PM

Php simply makes life more easier. Keeping everything aside, let me put one simple example - you have a website that has 200 pages. You have built it on html and every page has a simple html navigation on it. One fine morning need arises to add a new section to your nav and then you sit down to change it on all 200 pages. Now if this was in php, the nav section would have been an "include" on all 200 pages like - <? include 'nav.php'; ?>, so when you needed to update the nav, just one change on nav.php would have affected all 200 pages saving your time.


#7 Jill

Jill

    High Rankings Advisor

  • Admin
  • 32,379 posts

Posted 25 July 2007 - 04:30 PM

That's not quite true. You can do the same thing with server side includes.

#8 chrishirst

chrishirst

    A not so moderate moderator.

  • Moderator
  • 5,958 posts
  • Location:Blackpool UK

Posted 25 July 2007 - 04:37 PM

or ASP

or ColdFusion

or .NET

#9 doogie88

doogie88

    HR 4

  • Active Members
  • PipPipPipPip
  • 260 posts

Posted 26 July 2007 - 12:24 PM

Thanks for the tips.
And thanks AlDugan, that is a smart idea.


#10 1dmf

1dmf

    Keep Asking, Keep Questioning, Keep Learning

  • Active Members
  • PipPipPipPipPipPipPip
  • 2,154 posts
  • Location:Worthing - England

Posted 26 July 2007 - 02:04 PM

QUOTE
That's not quite true. You can do the same thing with server side includes.
good spot Jill, I do this and all my pages have .html extensions wink1.gif

#11 aaron653

aaron653

    HR 2

  • Active Members
  • PipPip
  • 46 posts

Posted 24 August 2007 - 02:53 AM

QUOTE(AlDugan @ Jul 25 2007, 09:16 PM) View Post
Also keep in mind, if you want to build your site in just plain html and then learn PHP as you have the time do yourself a favor and save your web pages with the .php extension now. You don't have to actually have any .php code on them yet but if you end up wanting to add PHP functionality later your pages will be ready and you won't have to set up any redirects from your old .html pages to your new .php pages because you gave them the .php extension from the beginning.


But do I save the simplest of all pages as .php even if there is not any chance of adding php code to that page in the future?

#12 MaKa

MaKa

    HR 6

  • Active Members
  • PipPipPipPipPipPip
  • 856 posts
  • Location:Llantwit Major, Wales, UK

Posted 24 August 2007 - 03:26 AM

QUOTE(aaron653 @ Aug 24 2007, 08:53 AM) View Post
But do I save the simplest of all pages as .php even if there is not any chance of adding php code to that page in the future?


I would name all to .php, even if it was just for the sake of consistency. Nothing more annoying than thinking you linked to the correct page, but finding out (after days/weeks) that you linked to the .php instead of the .html.

Just keep it simple.

#13 aaron653

aaron653

    HR 2

  • Active Members
  • PipPip
  • 46 posts

Posted 24 August 2007 - 03:57 AM

QUOTE(MaKa @ Aug 24 2007, 01:56 PM) View Post
I would name all to .php, even if it was just for the sake of consistency. Nothing more annoying than thinking you linked to the correct page, but finding out (after days/weeks) that you linked to the .php instead of the .html.

Just keep it simple.


Thanks Maka.......... smile.gif

#14 rolf

rolf

    HR 6

  • Active Members
  • PipPipPipPipPipPip
  • 675 posts
  • Location:Suffolk UK

Posted 24 August 2007 - 05:14 AM

for me, the most appealing thing about PHP is that you can apply conditional logic to the creation of the page, so you can tell the server that if conditionX is met do actionY to the page before sending it to the browser, else do actionZ to the page before sending it to the browser, or just serve the page as it is.

Action Y/Z can be almost anything you can imagine, from showing a particular set or subset of information from a database, to including a picture, or styling something differently, or writing a link in a certain way or a hundred other things - plus you can include as many of these types of decisions in one page as you want.

Have a look at the site in my sig, virtually every page has some of these types of logic applied. Have a look at the shopping pages especially and look at the page names/URLs - notice that there are actually very few pages and the thing that differs in each address is the information after the '?', which tells the server what to do with the page (as described above)

I highly recommend reading 'programming for dummies' (if you've never done any programming this will give you a good foundation knowledge of how this type of thing works), then I recommend 'PHP & MySQL for dummies' to learn PHP and the MySQL database. I'm sure others can recommend equally good resources too.

#15 detzx

detzx

    HR 2

  • Active Members
  • PipPip
  • 23 posts

Posted 24 August 2007 - 07:54 AM

Just a note to what people are saying. Yes it's a good idea to look into the future and prepare for what you may want to use later but you don't have to name your pages .php. Most servers allow you to change the extension that executes php code so in reality the .php means nothing more than telling the web server how to handle the page. You can have all of you .html, .htm pages execute php code as well. Hell, if you wanted you could have index.asp, index.cfp, index.jsp execute php code too. biggrin.gif

Oscommerce is built using PHP and it would help to understand it but from what I've used of it you don't really need to know php to use it as long as it's been setup by someone who does.

PHP and other scripting languages for the web are great because as everyone stated above you have more control over your pages and you're not repeating things over and over. At the most basic level all of you pages could look like.
CODE
<?php
    require_once('header.php');
    <div> This would be the body of the page, all of the content </div>
    require_once('footer.php');
?>

Then you have a header.php and footer.php that are shared by all pages so if you need to change anything you just change it in once place.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users