hosted by liquidweb


Go Back   Web Hosting Talk : Web Hosting Main Forums : Web Hosting Talk Tutorials : Web Design and Content Tutorials : PHP is Awesome, and Smart
Reply

Forum Jump

PHP is Awesome, and Smart

Reply Post New Thread In Web Design and Content Tutorials Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old 09-21-2011, 10:20 AM
ByteMaster ByteMaster is offline
Web Hosting Master
 
Join Date: May 2005
Location: Chicago, IL USA
Posts: 1,428
Lightbulb

PHP is Awesome, and Smart


PHP is awesome. Itís widely used, has its roots in true system programming languages like C and has perhaps the best and biggest development community. While I donít claim to be a PHP expert, I did spend 4 years making my living as a LAMP ( Linux, Apache, MySQL, PHP ) developer.

When I first began coding, it was a horrible mess and yes, the first thing I ever coded was ďHello World!Ē I didnít declare variables, didnít comment code and certainly didnít bother writing functions or classes to make my job easier. I remember the first time I found a function to write the date on the bottom of my web site and I thought it was the coolest thing since sliced bread! Naturally, as time went on I learned to utilized functions to make my job easier, made beautiful descriptive comments and even declared my variables. As I took on bigger and bigger projects, my code had to improve as it became too time consuming to do things the way I had been doing them.

Once I had mastered functions, I moved onto Object Oriented Programming, in other words, PHP Classes. When I first started utilizing classes in my work, I was like Columbus discovering the New World. My coding life became a breeze and I was completing projects in record time with beautifully formatted code that was fast! I utilized classes for database interaction, time formatting, file and image based functions, networking functions and more. I worked with so many amazing PHP classes during my time as a freelance developer, however, I think the best class I ever came across was the Smarty Template Engine. So, now that Iíve exhaustively gone on about myself for what seems like ages, I will get to the meat and potatoes, Smarty.

If you are not familiar with template engines, there purpose is to allow developers to separate front-end code with back-end code. This allows a designer or design team to create and modify the graphical front-end of a web application without affecting the back-end PHP code. There are a lot of different template engines out there such as patTemplate, PHPTAL, FastTemplate, SimpleTemplate, Savant and more. I personally used both patTemplate and FastTemplate, however, none of them seemed to have the flexibility and extensibility of Smarty. Interestingly enough, the developer of FastTemplate also loves Smarty, which you can see from this post. Smarty is really much more than a simple tag replacement class, in fact, itís more of a template framework.

If you are new to PHP templates, you might feel like learning Smarty is like learning an entirely new programming language. If youíve ever worked with Cold Fusion, it will make a lot of sense to you as itís a tag based syntax. Smarty is also very familiar to PHP developers as its variable prefix uses the familiar dollar sign ($) and its if, then, else statements also work similarly to PHP. Smarty has an enormous catalog of functions that allow developers and designers to get very creative with their presentation layouts in addition to providing developers with enormous flexibility. I would argue that the best, albeit most dangerous capabilities of Smarty is that it allows execution of PHP code directly within the template. If you are a developer and possess full control over your codebase, I would never recommend this. If, however, you are working on an encrypted third party application that uses Smarty, you will be limited to editing only the templates and then having PHP coding capabilities can be absolutely wonderful.

Smarty is a very easy system to deploy, does not require additional system resources and integrates with any PHP deployment. Smarty is a system that many of us SolarVPSers know well and its easy to deploy on any VPS or Dedicated Server running cPanel or Plesk. Smarty can even be installed on Windows!

You can obtain more information about Smarty here: http://www.smarty.net

For more information regarding PHP, go here: http://www.php.net

Author: Ross Brouse
COO FortressITX

__________________
||| Mike Bowers - Marketing Director
||| atOmicVPS LTD
||| OnApp Powered Linux & Windows Cloud Hosting ► [Shared] ► [Reseller] ► [VPS]
||| Follow the atOmicVPS Blog



Sponsored Links
  #2  
Old 09-21-2011, 11:21 AM
Cape Dave Cape Dave is offline
Web Hosting Guru Wannabe
 
Join Date: Mar 2004
Posts: 1,315
Two of my favorites software packages use Smarty. Pinnacle cart and the one, the only, the venerable... WHMCS!

__________________
CapeWP.com
CapeWP.com - WordPress for all of us

  #3  
Old 10-03-2011, 12:41 AM
hoangvu hoangvu is offline
Disabled
 
Join Date: Mar 2011
Posts: 23
right, Php is Awesome and Smarty's cool

Sponsored Links
  #4  
Old 10-13-2011, 02:16 PM
fredrikrob fredrikrob is offline
Junior Guru Wannabe
 
Join Date: Sep 2011
Posts: 41
I don't have much idea about Php but as in these day's i am learning Php and have attended introduction classes about PHP and very excited about it.

__________________
PSD to HTML | PSD to Wordpress

  #5  
Old 10-13-2011, 03:47 PM
media-hosts_com media-hosts_com is offline
Web Hosting Evangelist
 
Join Date: Oct 2009
Location: Canada
Posts: 454
Object Oriented Code (AKA PHP Classes) add simplicity to medium to large complex sites.

But, it also adds unnecessary complexity to simple sites.

Sometimes you don't always need to use them ;-)

__________________
Owner Media-Hosts.com AS14442 Canadian Web Hosts Since 2002
█ 24/7 365 Support, 100% Network Up-time Guarantee
█ Web Development Specialists (E-Commerce, Inventory, Design)
OpenVZ.ca Reliable, Affordable VPS Servers and Web Hosting. IPv6 Available

  #6  
Old 10-13-2011, 03:57 PM
lynxus lynxus is offline
Lord of live chats
 
Join Date: Jul 2009
Location: UK
Posts: 1,263
Agreed, PHP pwns!

__________________
Live chat software -> IMsupporting.com
Increase Sales Today - 100% No Strings Free Trial

  #7  
Old 10-27-2011, 05:44 PM
jclutter jclutter is offline
Junior Guru
 
Join Date: Jul 2009
Location: Dallas, Texas
Posts: 233
PHP is wonderful. I grew up on plain HTML but PHP is amazing. Only way to code now!

__________________
Justin

  #8  
Old 11-07-2011, 12:49 PM
PowerHost4u PowerHost4u is offline
Newbie
 
Join Date: Aug 2011
Posts: 11
This was a good read thanks very much. I have been learning PHP for some time now. I really like smarty.

  #9  
Old 11-22-2011, 07:52 AM
BitDash BitDash is offline
Aspiring Evangelist
 
Join Date: Mar 2010
Location: England
Posts: 368
Why would you suggest using something like Smarty over PHP itself, seeing as PHP is essentially a template language already?

(Not having a go, I've just always wondered why people who are fans of separate template languages bother.)

__________________
bit//signal :: server management with the personal touch
www: bitsignal.net skype: bitsignal.net email: sam@bitsignal.net

  #10  
Old 12-01-2011, 03:42 AM
infihosting infihosting is offline
Junior Guru Wannabe
 
Join Date: Nov 2011
Location: Bangalore, India
Posts: 35
Yes, that's right.

__________________
http://www.infihosting.com: Perfect Hosting Solution


  #11  
Old 12-17-2011, 09:16 AM
johnston981 johnston981 is offline
Web Hosting Master
 
Join Date: Jan 2011
Location: London
Posts: 603
I am using php for more than 2 years and i am very glad working with it. But now when HTML5 will come up i am thinking to work on it.

  #12  
Old 12-21-2011, 04:16 AM
josephgarbett josephgarbett is offline
Web Hosting Master
 
Join Date: Jun 2009
Location: UK: Oxford
Posts: 1,238
When I started my new job in London, just knew a little info about functions and how to use them properly.

7 months later and I'm now writing self-correcting OO that requires very little maintenance. This smarty system looks interesting, could come in handy when I'm asked to work on a small website project again.

__________________
Pub, Gym and Programming is now my life.

  #13  
Old 01-01-2012, 08:25 PM
twhiting9275 twhiting9275 is offline
Just me
 
Join Date: Sep 2002
Location: Among the corn
Posts: 10,415
Who DIDN'T get their start by using 'hello world' examples? I still use that to test cgi-bin directories which have nasty permissions and problems.

I have to agree that php is pretty awesome and smart. Couple it with MySQL and you can do pretty much anything. At one point (12 years ago or so), I started working on a MUD (look it up ), trying to get the backend to tie into MySQL so staff could edit things through a CMS , and just haven't stopped playing with php/MySQL ever since. If you know what you're doing, it can do everything from monitor your server to chat (AIM, etc) to tweet to text message.. There are a number of things that make it just great at what it is.

  #14  
Old 01-18-2012, 01:14 PM
Angelys Angelys is offline
Disabled
 
Join Date: May 2009
Location: Kiev
Posts: 10
i use only PhP =) !

  #15  
Old 04-04-2012, 07:25 AM
sam23 sam23 is offline
Junior Guru Wannabe
 
Join Date: Sep 2011
Posts: 52
Php is really awesome.and I like to use it.

__________________
Paintless Dent Repair

Reply

Similar Threads
Thread Thread Starter Forum Replies Last Post
iWeb's Smart Layer Vs. Liquidweb's Smart Servers Chaw Dedicated Server 2 06-05-2011 04:45 PM
how smart is it to store sessions in APC [php]? grabmail Programming Discussion 7 08-07-2006 03:56 PM
Some MAJOR PHP Problems, anyone smart in PHP Please LOOK! Mambug Programming Discussion 9 06-26-2005 06:33 PM
PHP Smart Quotes SynHost Programming Discussion 4 03-23-2005 04:20 PM
need savvy and smart php/perl coder! roygbiv Employment / Job Offers 0 12-27-2003 05:52 PM

Related posts from TheWhir.com
Title Type Date Posted
SanDisk to Acquire SSD Developer SMART Storage Systems for $307 Million Web Hosting News 2013-07-08 11:47:52
PEER 1 Hosting Launches Referral Program to Create Mutually Beneficial Revenue Streams Web Hosting News 2012-11-13 15:25:58
Zetta Launches Appliance-Free Hybrid Smart Cloud Backup Solution Web Hosting News 2012-10-23 16:29:27
Web Host Codero Launches Smart Servers Hosting Solutions Web Hosting News 2012-07-19 10:17:36
Web Host Liquid Web Launches Virtual Private Network Solution Web Hosting News 2012-06-14 15:42:18


Tags
developer, php, php framework, php on a vps, smarty, smarty on a vps

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
Advertisement:
Web Hosting News:



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?