Jump to content

Recommended Posts

Let's say i have a basic web site with snippets of PHP throughout all of it

 

do most of you put all of your site's page files on the root?

 

and then make a PHP folder and a JS folder?

I know I should have a file for my PHP functions

 

what's a good way to structure the site?

 

 

say this is my header and is an include - how do most of you link your css, javascript, php, xml files? do you make a config file?


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="stylesheet" media="all" type="text/css" href="base.css" />
<link type="text/css" href="jquery.ui.all.css" rel="stylesheet" />
<link rel="stylesheet" type="text/css" href="jqtransformplugin/jqtransform.css" />
<link rel="stylesheet" type="text/css" href="formValidator/validationEngine.jquery.css" />
<link type="text/css" href="colorbox.css" rel="stylesheet" />


<title>Site Title</title>

<script type="text/javascript" src="js/jquery-1.4.2.js"></script>
<script type="text/javascript" src="js/jquery.ui.core.js"></script>
<script type="text/javascript" src="js/jquery.ui.widget.js"></script>
<script type="text/javascript" src="js/jquery.ui.accordion.js"></script>
<script type="text/javascript" src="jqtransformplugin/jquery.jqtransform.js"></script>
<script type="text/javascript" src="formValidator/jquery.validationEngine.js"></script>
<script type="text/javascript" src="script.js"></script>
<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript" src="js/jquery.colorbox-min.js"></script>
<script type="text/javascript" src="js/jquer

my index file usually looks something like this...

 

 <?php include('includes/header.php'); ?> 
<?php include('includes/menu.php'); ?> 
<div id="content"></div>
<?php include('includes/leftcolumn.php'); ?> 
<?php include('includes/footer.php'); ?> 

Zend is a company developing PHP, so one could say all PHP programmers use Zend... :P

 

Zend Framework on the other hand, is a set of PHP Classes that implement many common tasks, making working on large projects easier. It's possibly most widely used PHP framework (there are others), but I don't think that most PHP programmers use it.

 

My point when posting this link was, you can keep it simple, or you can create an extensive directory structure. There is no one golden rule.

I think you should first get familiar with PHP itself. Frameworks in general and Zend Framework in particular have pretty steep learning curve, and you do not really need them for small to medium projects.

 

In most cases you don't need to do any changes to php.ini file, but be sure to check this list of requirements:

http://framework.zend.com/manual/en/requirements.introduction.html

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.