Jump to content

Secure Website Structure


FishSword

Recommended Posts

Hiya,

 

What's the best and most secure way of structuring a website? I have looked at various forum packages (.e.g phpBB, myBB, and smf), and they each seem to use a switch statement in the index.php file.

 

When you go to a section of the website, a "GET" variable is passed, and the relevant area of the website is loaded through the switch statement. Is this the best and only way?

 

I would appreciate any body's thoughts on this topic.

 

Thanks,

FishSword

Link to comment
Share on other sites

Everyone does it differently and everyone thinks they're doing it the best way.

 

What you have to keep in mind is that those packages have to care a lot about portability. Ideally, you can just download a .zip from their site, unpack it to a directory, (make a couple file changes here and there,) and run. That means they can't use things such as URL rewriting - because it depends on the web server.

 

I'm sure you could get a lot of good advice if you gave a bit more detail about the kind of website you're aiming for.

Link to comment
Share on other sites

The way I set up my website was to generate the pages based on GET variables...so there's only one index page on the root.  I've become more wary of doing it this way and I wish I had set it up in a directory fashion (http://mysite.com/about/ vs http://mysite.com/?pid=about).  Look at the MVC approach and learn it well - it will help you organize the logic and make it much easier to troubleshoot your problems.

Link to comment
Share on other sites

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.