Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 7 of 7

Thread: My next step?

  1. #1
    Member
    Join Date
    Jul 2007
    Posts
    64
    Member #
    15493
    Hi all, I have a question. I currently have a script running on my website. It's a php register/login function that sends a little information to a database and displays it to the user and whatnot. But I'd like to expand on this. I'd like to make it more interactive with prive messaging. I'd like to also be able to view other accounts. I'm unsure of what to use though. I read all this stuff about Perl and Python and their respective websites don't explain much about what you can ACTUALLY DO with these languages.

    So my question to you all is this, is it possible for me to create interaction(private messaging and all that) with Perl and/or Python?

  2.  

  3. #2
    Senior Member seanmiller's Avatar
    Join Date
    Sep 2003
    Location
    Glastonbury, UK
    Posts
    868
    Member #
    3263
    Liked
    1 times
    This board is, I think, written in php and MySQL so I think that answers your question...

    Perl and Python could do it too, but I'd be inclined to use php as it normally comes already integrated with both the Apache webserver and the MySQL database on webservers, meaning you don't have to worry too much about configuration and can get on with the programming.

    Php is also a wonderfully simple language to learn, at least when writing code procedurally... haven't had the time myself to learn the more modern object-orientated approach to php but it's on my list of things to do sometime soon...

    Sean

  4. #3
    Member
    Join Date
    Jul 2007
    Posts
    64
    Member #
    15493
    Thanks for the reply.

    I guess I will stick with PHP. I have an issue though. I don't know how to display seperate users. Like for instance, any one of our profiles:

    http://www.webdesignforums.net/member.php?u=15645

    How do I do this? How do I get unique characters for each person who signs up and have a way to see their information?

  5. #4
    Senior Member seanmiller's Avatar
    Join Date
    Sep 2003
    Location
    Glastonbury, UK
    Posts
    868
    Member #
    3263
    Liked
    1 times
    The way you are asking the question, I suspect that you have several challenges ahead... here's my thoughts on how you should approach the project...

    a. functional design - you need to sit down with a piece of paper and sketch out how your program is going to flow. Work out exactly what pages you're going to have on your site and how they relate to one another... for instance, what happens when somebody enters the site? What do they see? Where can they navigate to? When they navigate to a page repeat the process... What do they see? Where can they navigate to? And so on for the entire site. Once you think you have a "first cut" go away and do something else, then return to it and look through. Have you left anything out? Have you considered private/public? How many levels of private/public do you want? Do you have moderators, administrators, members? Should you provide some sort of mechanism whereby this can be expanded? This is an iterative process but you should NOT start coding anything until you are 90% sure (at least) that your design is pretty much what is required otherwise you could end up with some very costly re-works further down the line and/or a system that simply does not work.

    At the end of this process you should have a fairly clear idea of what functions you're going to require, and what data you will be required to hold in your database to make this work. Consider clicking a link, or a submit form, as running a function. What data are you going to need to pass on that click. Write it down, as you're going to have to program this later. But you don't program it in this phase... you simply decide what you're going to program.

    Once you have this all documented, feel free to post it here. I am sure that the good folks of WDF would be quite happy to help you out by commenting on things we think you may have still to consider :-)

    b. relational database design - you now need to design the structures that will support the functions. If your database structure isn't right your site won't work, or it will be very difficult to expand in the future. There is a formal process called "normalisation" that is crucial to relational database design. Wikipedia has a pretty good description here... http://en.wikipedia.org/wiki/Database_normalization and it isn't "rocket science" but it can take a little while to "tune your mind" into thinking that way so you may want to run some ideas past the folks here once again to check you're thinking along the right lines. I've been designing relational databases for almost 20 years (got my first job in Oracle in 1988) so have had lots of practice and I was lucky enough to get sent on residential courses by my then employers so never really had to learn it on my own so good luck.

    c. create the database - once you're happy with your database design you need to actually put it into action. Hopefully your hosting will have something like phpMyAdmin so you won't have to actually create the tables manually, though if you do it isn't that hard once you know the syntax. I would recommend that you get a book on MySQL... even if you think you've grasped it, there'll be some syntax that you're not sure of when you come to program and it could save you lots of time. I really like O'Reilly's "Head First" series... they do one on SQL which also covers in really simple terms the normalisation that I mentioned above...

    Sample chapter here... http://www.oreilly.com/catalog/97805...apter/ch01.pdf

    d. write the programs - if you're not already a programmer I can't really teach you programming here, so again best thing to do is to get a book or go to some online tutorials. You're going to have to write the php to generate the web pages, and some SQL to update the database, called from the php. As I said, it's a huge subject but if you've followed steps a-c above you should have a very clear idea of what it is your code has to do, so basically after that all you really need to do is write it and you're there.

    Your requirement is ambitious, it might be worth starting off with something simple before going for "the whole hog", though I would seriously suggest you still follow a structured approach (as above) no matter how simple your requirement appears to be. With small projects it becomes far more informal, the steps being more mental than physical but *trust me* if you don't do all the planning before you put your hands on a keyboard you will live to regret it later.

    Hope that is useful.

    Sean

  6. #5
    Member
    Join Date
    Jul 2007
    Posts
    64
    Member #
    15493
    Wow, thank you for that reply. Essentially, what I would LIKE to do is have a system where someone can create their own profile page with a unique link. Something similar to the system this guy has:

    www.kurbong.net Users can create a profile that comes with a unique link, a control panel to edit their information and stuff.

    Should you provide some sort of mechanism whereby this can be expanded?
    Yep. Eventually, I'd like to just be able to add onto the users pages as a whole. If I wanted to add a private messaging system or say a ranking system, I should be able to do it without causing much of a mess.

    So with all this information, what would I need? Btw, I find it funny you've been programming for a year longer than I've been alive. :P

  7. #6
    Senior Member Steax's Avatar
    Join Date
    Dec 2006
    Location
    Bandung, Indonesia
    Posts
    1,207
    Member #
    14572
    If you want a quick resource to try, check out this script which was my foundation for learning this style of PHP - it taught me a lot. Take a peek!

    Good luck!
    Note on code: If I give code, please note that it is simply sample code to demonstrate an effect. It is not meant to be used as-is; that is the programmer's job. I am not responsible to give you support or be held liable for anything that happens when using my code.

  8. #7
    Member
    Join Date
    Jul 2007
    Posts
    64
    Member #
    15493
    I'll look into it, thanks.


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 03:05 AM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com