WEB Database for a webpage. Where to start?

Discussion in 'OT Technology' started by danza, Mar 11, 2008.

  1. danza

    danza New Member

    Joined:
    Jul 9, 2005
    Messages:
    1,319
    Likes Received:
    0
    Location:
    california
    I'm going to have some free time in the next couple of days and wanted to write a simple news section update script for my brother. He basically has a news section that he edits manually (actually edits the html). He pretty much deletes the oldest test at the bottom of the file and adds a new one at the top.

    I wanted to make a database for him and have some code in the news section that says for example, show the 10 most recent entries. Simple right?

    Well i have limited experience and a google search gave me a ton of different ways to accomplish a database.

    What would be the way to go to learn me some knowledge? I've noticed a lot of mysql + php combos. Would this be a good area to invest my free time? Or is there another language I should try learning?
     
  2. 2ofdem

    2ofdem OT Supporter

    Joined:
    Jun 17, 2003
    Messages:
    114,854
    Likes Received:
    8
    Location:
    aus.vic.mel
    PHP + MySQL would be the easiest way to do this.
     
  3. TurkeyChicken

    TurkeyChicken New Member

    Joined:
    Jun 26, 2003
    Messages:
    42,913
    Likes Received:
    0
    Location:
    Albuquerque, NM
    agreed.
     
  4. jdw

    jdw New Member

    Joined:
    Dec 31, 2005
    Messages:
    4,429
    Likes Received:
    0
    Location:
    ND
    SELECT * from `news` ORDER by post_date LIMIT 10


    as simple as that...




    Now I suppose a guy could write a script that builds an XML file and just appends that with each new post...
     
  5. rogueslg71

    rogueslg71 New Member

    Joined:
    Dec 31, 2007
    Messages:
    235
    Likes Received:
    0
    Location:
    Dallas, Tx / Friendswood, Tx
    php & mysql would be easy to use. if theres not much else to the site (if its simple) maybe look into wordpress for the whole thing?
     
  6. danza

    danza New Member

    Joined:
    Jul 9, 2005
    Messages:
    1,319
    Likes Received:
    0
    Location:
    california
    I'm pretty much a noob and am going to learn it from scratch so my only concern is, is it worth learning or should I learn something that might be "newer"?

    Basically I'm wondernig if php+mysql is outdated. That might be a stupid question and it might turn out that its the pirmary method of doing things like this but as i said, i'm not really familiar with all the options.

    So, php+mysql still relevant?
     
  7. danza

    danza New Member

    Joined:
    Jul 9, 2005
    Messages:
    1,319
    Likes Received:
    0
    Location:
    california
    Well, i'm familiar with wordpress, I myself use Mambo. But I kinda want to learn how to do some database stuff during my break since every now and then i get the urge to do custom stuff but stop short for fear breaking everything. I figure it can't hurt to learn a little more.
     
  8. jdw

    jdw New Member

    Joined:
    Dec 31, 2005
    Messages:
    4,429
    Likes Received:
    0
    Location:
    ND

    MySQL will always be relevant...
    PHP.. ehh, depends who you talk to. I'll keep using it for my stuff until I take the time to learn something newer. Some say it's a dead language, but FWIW they seem to keep developing it and for it so have at it.
     
  9. lukin87

    lukin87 New Member

    Joined:
    Jan 11, 2008
    Messages:
    135
    Likes Received:
    0
    PHP is a very relevant and powerful language. Its currently on version 5 and version 6 is being worked on.

    Facebook is mostly written in PHP using a mysql database.
     
  10. php & mysql is like the only way to do this if you want to eliminate the manual html editing/uploading.

    check with your hosting service, they should have some nice mysql management software somewhere in the cpanel, maybe with some tuts too. but you can find plenty of decent tutorials around. i know there are some on pixel2life.com

    but mysql and php will be here to stay for a longgg time. it shouldn't take too long for you to learn. it's one of those languages that can be easily understood when examining the code.
     
  11. danza

    danza New Member

    Joined:
    Jul 9, 2005
    Messages:
    1,319
    Likes Received:
    0
    Location:
    california
    thanks for the help. I think i'll go to the local bookstore and get me some reading material for php and mysql.
     
  12. rogueslg71

    rogueslg71 New Member

    Joined:
    Dec 31, 2007
    Messages:
    235
    Likes Received:
    0
    Location:
    Dallas, Tx / Friendswood, Tx
    i highly recommend php and mysql visual quickpro , the author is Larry Ullman. i dont know the exact name/edition he is on right now but that is the book that i learned from. its very easy to follow. also i would get the 'php phrasebook' and 'mysql phrasebook' for fast look up on things =)
     
  13. jdw

    jdw New Member

    Joined:
    Dec 31, 2005
    Messages:
    4,429
    Likes Received:
    0
    Location:
    ND
    I've been happy with the W3Schools tutorials myself....

    Then PHP.net is the only thing you'll need...
     
  14. biawokauns

    biawokauns New Member

    Joined:
    Sep 18, 2001
    Messages:
    19,893
    Likes Received:
    0
    Location:
    Republic of Kalifornia
    knowing SQL will always help you. even with rails and sqlite, understanding whats going on under the hood makes things much easier. being able to write a custom query every now and then is also very helpful
     
  15. danza

    danza New Member

    Joined:
    Jul 9, 2005
    Messages:
    1,319
    Likes Received:
    0
    Location:
    california
    well thanks everyone. I just read a few online tutorials and was able to make a sql database with a table and use php to display all the entries.

    Now i'll try and get a front end going with basic add, edit, delete buttons.

    It's not as bad as i thought.
     
  16. that was pretty quick. you should catch on fast :cool:
     
  17. 2ofdem

    2ofdem OT Supporter

    Joined:
    Jun 17, 2003
    Messages:
    114,854
    Likes Received:
    8
    Location:
    aus.vic.mel
  18. biawokauns

    biawokauns New Member

    Joined:
    Sep 18, 2001
    Messages:
    19,893
    Likes Received:
    0
    Location:
    Republic of Kalifornia
    I can create a blog in like 5 minutes :maoru:
     
  19. jdw

    jdw New Member

    Joined:
    Dec 31, 2005
    Messages:
    4,429
    Likes Received:
    0
    Location:
    ND
    <indian voice>"Look at what I"m not doing"</indian voice>
     
  20. danza

    danza New Member

    Joined:
    Jul 9, 2005
    Messages:
    1,319
    Likes Received:
    0
    Location:
    california
    What is everyone's opinion on JSP? Would it be suitable instead of PHP?
     
  21. rtfm

    rtfm omgwtfbbq

    Joined:
    Oct 26, 2004
    Messages:
    5,043
    Likes Received:
    0
    Location:
    Canada

    PHP a dead language? :ugh: whoever told you that is a fucking idiot.
     
  22. depends on what you need to do. if you know php, you can do javascript functions in php if you need that kind of thing. but if you need just to do a simple rollover script, all you need is javascript.
     
  23. Vailripper

    Vailripper Daywalkers have feelings too.

    Joined:
    Jan 25, 2006
    Messages:
    6,170
    Likes Received:
    0
    Location:
    Bellingham, WA
    Facebook is built on a custom framework. It uses PHP on the presentation side, but behind that it's mostly written in C++, Python, C, etc.

    PHP is very fast to develop, however it's HORRIBLY structured.
     
  24. Kevin

    Kevin New Member

    Joined:
    Aug 27, 2002
    Messages:
    87,634
    Likes Received:
    0
    Location:
    Michigan
    Don't listen to the php answers.

    The money in the real world is asp.net
    $80-100k/year with minor experience.
     
  25. Vailripper

    Vailripper Daywalkers have feelings too.

    Joined:
    Jan 25, 2006
    Messages:
    6,170
    Likes Received:
    0
    Location:
    Bellingham, WA
    It's true.

    PHP is fantastic for small scale/ personal sites, but you're not going to make much building those.

    Enterprise grade sites are built on asp.net/java, and enterprises are the ones with the money.


    Not to mention it's incredibly difficult to structure PHP effectively.
     

Share This Page