SitePoint Sponsor

User Tag List

Page 3 of 10 FirstFirst 1234567 ... LastLast
Results 51 to 75 of 230
  1. #51
    SitePoint Member
    Join Date
    Mar 2005
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Ren
    holy crap!!!!

  2. #52
    SitePoint Enthusiast
    Join Date
    Apr 2006
    Posts
    49
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I agree with the general mood - that most of the forum software out there is bloatware and badly written. A while back I was looking to integrate a forum into a business site but couldn't find anything - I ended up writing one myself. OK - so it didn't have avatars (who cares?) but it separated content and layout, was accessible and OO.

    Also agree that to the end user / customer, it doesn't really matter how it is written so long as it works. Having said that, if I now have a compact class & data model which I can reuse and drop into any page using $this_forum = new forum($forum_id); saving hours of heartache trying to integrate phpBB, Vanilla etc.

  3. #53
    SitePoint Zealot Digitalman's Avatar
    Join Date
    May 2004
    Location
    Belgium
    Posts
    145
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    If you all are so good in coding why don't you make your own scripts?

  4. #54
    SitePoint Evangelist tetsuo shima's Avatar
    Join Date
    Oct 2005
    Location
    Switzerland
    Posts
    597
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Digitalman
    If you all are so good in coding why don't you make your own scripts?
    It often comes to this in my mind too when I see people criticizing available products. I think neildonald got it right.

    Who said the famous "put up or shut up" words again? It's a bit aggressive but well, if the market is saturated by poorly coded pieces of softwares, maybe it's time to do better instead of endlessly contemplating their failures and complaining about them.

    That said, I own one forum and never had to look at the code or modify it. If I had had that experience, maybe I'd say otherwise.
    The SEO Faq thread
    Dependency injection made easy: Phemto

  5. #55
    simple tester McGruff's Avatar
    Join Date
    Sep 2003
    Location
    Glasgow
    Posts
    1,690
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    It's important to identify what's good and what's bad. How are people going to learn anything otherwise? The first step to writing better code is understanding that there is a problem to begin with. I think you'll find plenty posts in PAD where people "put up" some good programming ideas and theories.

  6. #56
    SitePoint Addict
    Join Date
    May 2003
    Location
    The Netherlands
    Posts
    391
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Digitalman
    If you all are so good in coding why don't you make your own scripts?
    Lack of time, mainly. Only contributing to SP takes already an effort for somebody with a 45/60 hours workweek like me. A while ago I did attempt to start an alternative for OSCommerce, if I recall correctly I discussed the issue with McGruff and some other member of this forum, but at the end, I've just not have enough time for it (and so didn't the rest).

    I'd like to mention also that you probably forget the fact that many times you get involved with clients who made a bad decision in the past (based probably on a lack of knowledge and experience), and that unfortunately that leads to having to deal with this kind of software. The choice is not always up to you.
    There’s more than one way to skin a cat.

  7. #57
    SitePoint Guru dagfinn's Avatar
    Join Date
    Jan 2004
    Location
    Oslo, Norway
    Posts
    894
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Digitalman
    If you all are so good in coding why don't you make your own scripts?
    An alternative, which might be considered a ground-breaking experiment, would be to start with an existing project and refactor it.
    Dagfinn Reiersøl
    PHP in Action / Blog / Twitter
    "Making the impossible possible, the possible easy,
    and the easy elegant"
    -- Moshe Feldenkrais

  8. #58
    SitePoint Addict
    Join Date
    May 2003
    Location
    The Netherlands
    Posts
    391
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by dagfinn
    An alternative, which might be considered a ground-breaking experiment, would be to start with an existing project and refactor it.
    I would consider your proposal rather to be a mind-breaking experiment.
    There’s more than one way to skin a cat.

  9. #59
    SitePoint Guru BerislavLopac's Avatar
    Join Date
    Sep 2004
    Location
    Zagreb, Croatia
    Posts
    830
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Actually, at least in terms of features if not the actual code (which I never saw) the best forum software is definitely Sitepoint's.

  10. #60
    Non-Member bigrollerdave's Avatar
    Join Date
    Mar 2005
    Posts
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Digitalman
    If you all are so good in coding why don't you make your own scripts?
    That's what I do it's really not hard at all. Just fixing the loopholes seems to take a little bit.

  11. #61
    Non-Member bigrollerdave's Avatar
    Join Date
    Mar 2005
    Posts
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BerislavLopac
    Actually, at least in terms of features if not the actual code (which I never saw) the best forum software is definitely Sitepoint's.
    Powered by: vBulletin Version 3.0.3

    I don't think it has more features then a normal vbulletin forum. Correct me if I'm wrong though. I've seen a lot better forums then sitepoints I've also seen a lot worse. I love their color scheme and simplicity of the site.

  12. #62
    SitePoint Guru dagfinn's Avatar
    Join Date
    Jan 2004
    Location
    Oslo, Norway
    Posts
    894
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by nacho
    I would consider your proposal rather to be a mind-breaking experiment.
    Now we even have a name for the project: mindbreaker.
    Dagfinn Reiersøl
    PHP in Action / Blog / Twitter
    "Making the impossible possible, the possible easy,
    and the easy elegant"
    -- Moshe Feldenkrais

  13. #63
    Put your best practices away. The New Guy's Avatar
    Join Date
    Sep 2002
    Location
    Canada
    Posts
    2,087
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    As I am still new at OOP, so I may be out of line. However, I feel that as I am learning OOP techniques, I find that I am consistantly trying to find the perfect approach. Which of course does not exist. Thus, I have probably written more useful code using PP rather than OOP, simply because I dont look for the perfect solution. Obviously things like bad security programming are unacceptable, but more often than not the poor un refactored spagetti code gets the job done, and not at a horrible price. The price is often performance, readability and management. But those costs are never so high that one runs away from the proven solutions.
    "A nerd who gets contacts
    and a trendy hair cut is still a nerd"

    - Stephen Colbert on Apple Users

  14. #64
    SitePoint Guru silver trophy Luke Redpath's Avatar
    Join Date
    Mar 2003
    Location
    London
    Posts
    794
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by dagfinn
    An alternative, which might be considered a ground-breaking experiment, would be to start with an existing project and refactor it.
    Sounds like a nightmare to me! Would you really want to try and refactor a mess like phpBB without a good suite of unit tests to back you up? How would you know your refactoring hasn't broken anything?

    Starting from scratch would be by far the more headache-free way of doing it.

  15. #65
    Put your best practices away. The New Guy's Avatar
    Join Date
    Sep 2002
    Location
    Canada
    Posts
    2,087
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    Quote Originally Posted by Luke Redpath
    Sounds like a nightmare to me! Would you really want to try and refactor a mess like phpBB without a good suite of unit tests to back you up? How would you know your refactoring hasn't broken anything?.
    Nobody should ever use phpBB. I cannot believe that the lure of "FREE" has made people so stupid as to use the most insecure forum ever written.
    "A nerd who gets contacts
    and a trendy hair cut is still a nerd"

    - Stephen Colbert on Apple Users

  16. #66
    SitePoint Guru dagfinn's Avatar
    Join Date
    Jan 2004
    Location
    Oslo, Norway
    Posts
    894
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Luke Redpath
    Sounds like a nightmare to me! Would you really want to try and refactor a mess like phpBB without a good suite of unit tests to back you up? How would you know your refactoring hasn't broken anything?
    You'd have to build acceptance tests first and then add unit tests along the way. I'm not sure it's as crazy as you think. I've seen several re-implementation projects that were undertaken with too much hubris and didn't incorporate the experience from the previous project. The advantage of refactoring is that it's gives you somewhat predictable improvement.
    Dagfinn Reiersøl
    PHP in Action / Blog / Twitter
    "Making the impossible possible, the possible easy,
    and the easy elegant"
    -- Moshe Feldenkrais

  17. #67
    SitePoint Evangelist tetsuo shima's Avatar
    Join Date
    Oct 2005
    Location
    Switzerland
    Posts
    597
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by McGruff
    It's important to identify what's good and what's bad. How are people going to learn anything otherwise? The first step to writing better code is understanding that there is a problem to begin with. I think you'll find plenty posts in PAD where people "put up" some good programming ideas and theories.
    I would be hardly pressed not to agree with you. But take this thread and all its negative posts and tell me what is constructive in it. I love reading about theories, but I highly dislike posts that say stuff like "just thinking about this code makes me feel dizzy".

    Once again, one can point out all the failures and the weaknesses of a given software, and of course complain about them, but I think that one has to say how it should be improved in order to see his post taken seriously by others, especially people who are learning, since you refer to them in your post.

    The SEO Faq thread
    Dependency injection made easy: Phemto

  18. #68
    SitePoint Addict
    Join Date
    May 2003
    Location
    The Netherlands
    Posts
    391
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by tetsuo shima
    I would be hardly pressed not to agree with you. But take this thread and all its negative posts and tell me what is constructive in it. I love reading about theories, but I highly dislike posts that say stuff like "just thinking about this code makes me feel dizzy".

    Once again, one can point out all the failures and the weaknesses of a given software, and of course complain about them, but I think that one has to say how it should be improved in order to see his post taken seriously by others, especially people who are learning, since you refer to them in your post.

    With all due respect, I assume that anybody that hangs around this forum should be able to figure out by him/herself how to improve, to a certain degree, the code in the applications that have been mentioned in this thread. If not, I would suggest visiting the General forum first.
    There’s more than one way to skin a cat.

  19. #69
    Non-Member kuruption's Avatar
    Join Date
    Apr 2006
    Posts
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Serberus
    Ha! You ain't seen nothing yet, just check out this source from I-Rater, this is just a sample from index.php:

    PHP Code:
    if ( isset($_GET['cmd']) ) {
        
    $module_name $_GET['cmd'];
        
    $fname "modules/".$module_name."/".$module_name.".php";
        include(
    "$fname");
        exit;
    }
    else {
        if(
    $r == 1)    {
        
    $faqs="<br><br><center><font class='bold'>You have viewed or rated all the images, please check back again later</font></center><br><br>";
        
    session_unregister("previous_visit_id");
        }

        
    $s "select id from $tb_featureduser where gender ='f' LIMIT 0,$num_feature_image";

        
    $r mysql_query($s);
        
    //echo mysql_error();

        
    $faqs "<TR><td><TABLE align=center width=100%><TR><TD class=s10><strong><center>Featured Female</center></strong><BR>
            <table border=0 width=100% align=center>
                <tr width=19% class=s10>"
    ;
    //sathish

        
    for($i=0;$i<$num_feature_image;$i++) {
        
    $rd=0;
        
    $random_id[0]=$d[0];
        while(
    $d=mysql_fetch_row($r)) {
            
    $random_id[$rd]=$d[0];
            
    $rd+=1;
        }

        
    $sql "select * from $tb_users    where id = '$random_id[$i]'";
        
    $img_src '';

        
    $query mysql_query($sql) or die($sql);
        
    $array mysql_fetch_array($query);

        
    // check for image stored on remote server

        
    $sql "select image, image_url from $tb_users where id='$random_id' and user_type='2' ";
        
    $res mysql_query($sql);
        
    // echo mysql_error();
        
    $image_where="here";
        if (
    $data=mysql_fetch_row($res)) {
            
    $image_where=$data[0];
            
    $image_url=$data[1];
        }

        if (
    $image_where == "here"){   $img_src $base_url "/image.php?id=" $array["id"] . "&p=1";}
        elseif (
    $image_where == "there"){   $img_src $image_url;}

        
    $avg1 round($array[average_rating]);
        
    $count $i+1;
        
    $faqs .= "
                <td class=s10 align=center>
                    <a href='index.php?i=
    $array[id]'><img border=0 src='$img_src' width=100 height=100></a><br>

                    Name :<a href='index.php?i=
    $array[id]'>$array[username]</a><br>
                    Rating : 
    $avg1<br>
                    Age :
    $array[age]<br> </td> ";
        }

        
    $faqs .= "</table> <tr align=center> <td class=s10 width=100% align=center> <BR> <strong> <center> Featured Male</center> <br></strong>
        </td>"
    ;
            
    $faqs .= "<table border=0 width=100% align=center><tr align=center>";



    //sathish

        
    $s "select id from $tb_featureduser where gender ='m' LIMIT 0,$num_feature_image";
        
    $r mysql_query($s);
        
    // echo mysql_error();

        
    for($i=0;$i<$num_feature_image;$i++) {
        
    $rd=0;
        
    $random_id[0]=$d[0];
        while(
    $d=mysql_fetch_row($r)) {
            
    $random_id[$rd]=$d[0];
            
    $rd+=1;
        }

        
    $sql "
                select * from 
    $tb_users
                where
                id = '
    $random_id[$i]'
                "
    ;
        
    $img_src "";

        
    $query mysql_query($sql) or die($sql);
        
    $array mysql_fetch_array($query);

        
    // check for image stored on remote server

        
    $sql "select image, image_url from $tb_users where id='$random_id' and user_type='1' ";
        
    $res mysql_query($sql);
        
    // echo mysql_error();
        
    $image_where "here";
        if (
    $data=mysql_fetch_row($res)) {
            
    $image_where=$data[0];
            
    $image_url=$data[1];
        }

        if (
    $image_where == "here") {   $img_src $base_url "/image.php?id=" $array["id"] . "&p=1";}
        elseif (
    $image_where == "there"){   $img_src $image_url;}

        
    $avg1 round($array[average_rating]);
        
    $count $i+1;
        
    $faqs .= "
                <td  class=s10 align=center>
                <a href='index.php?i=
    $array[id]'><img border=0 src='$img_src' width=100 height=100></a></br>
                Name :<a href='index.php?i=
    $array[id]'>$array[username]</a><br>
                Rating : 
    $avg1<br>
                Age :
    $array[age]<br> </td>
                <td>"
    ;
        }

        
    $faqs .= "</table></TD></TR> ";

        
    $feature $faqs;

    #################################################################
    // extra code for recent user

        
    $recent_user "
                <tr><td><br></td></tr>

                        <tr><td width=100%>
                    <table border=0 width=100% cellspacing=0 cellpadding=0>
                        <tr><td class=s10 width=100% colspan=2><strong><br><center>Recent Users</center><br></strong></td></tr>
                        <tr><td width=50%><table border=0 width=100% cellspacing=0 cellpadding=0>
                 "
    ;

        
    $sql "SELECT * FROM $tb_users where image_status='approved' and user_type ='2'  ORDER BY signup DESC LIMIT 0,$num_recent_image";
        
    $sql1 "SELECT * FROM $tb_users where image_status='approved' and user_type ='1'  ORDER BY signup DESC LIMIT 0,$num_recent_image";

        
    $result mysql_query($sql) or die(mysql_error());
        
    $result1 mysql_query($sql1) or die(mysql_error());

        while(
    $row=mysql_fetch_assoc($result)) {
        
    $u_id[]=$row[id];
        
    $u_name[]=$row[username];
        }

        while(
    $row1=mysql_fetch_assoc($result1)) {
        
    $u1_id[]=$row1[id];
        
    $u1_name[]=$row1[username];
        }

        
    $totalimage=count($u_id);
        if(
    $totalimage 0) {
        
    $remain=$num_recent_image%4;
        for(
    $i=0$i $totalimage$i++) {
                if (
    $i%== 0) {
            
    $tpl->assign(array('I' => $u_id[$i],'J'=>$u_name[$i]));
            
    $tpl->parse('RECENTUSER_PHOTOS''.recentuser_photo');
          }
           else{
             
    $tpl->assign(array('I' => $u_id[$i],'J'=>$u_name[$i]));
             
    $tpl->parse('RECENTUSER_PHOTOS''.recentuser_photo');
            }
            if (
    $i%== 3) {
              
    $tpl->parse('RECENTUSER_ROWS''.recentuser_row_photos');
              
    $tpl->clear_parse('RECENTUSER_PHOTOS');
            }

        }
        } 
    When I was asked to modify this for a customer who installed it I was shocked they actually bought this product (and explained that I wasn't happy running this software on my server).

    Funny how they've decided to re-write it: http://www.i-rater.com/basic-and-pro...production.htm

    This sloppy code really gives PHP a bad name and fuels the constant bashing.
    0_0
    i-rater actually used that in their software?

  20. #70
    Non-Member kuruption's Avatar
    Join Date
    Apr 2006
    Posts
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    In all aspect why code something that's already been done?
    it's just a waste of time
    then again, things like vBulletin are a waste of money if you know how to code well.
    I've never used opensorce software, it's always been custom made by myself. But if you don't have the time it's opensorce FTW.

  21. #71
    SitePoint Zealot Zaskoda's Avatar
    Join Date
    Jun 2005
    Location
    Texas
    Posts
    156
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm jumping a tad off topic here... but I've found PM Wiki's code base to be very friendly to work with.

    As for vBul... I hate dealing with the code base...

  22. #72
    SitePoint Evangelist
    Join Date
    Apr 2005
    Posts
    485
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    i guess this post is for newbs... and i consider myself to be an experienced newb, as opposed to some professional programmer.

    some of the techniques i use are:

    1. DRY - any time you have to repeat yourself - figure out if its possible to organize your code so you DRY. when i started, i did a decent amount of this, but after reading the first few chapters of agile web development with rails, i took it to another level. repeating is EVIL. the include file is your FRIEND.

    2. seperate logic from content from presentation. i read this early on and always tried to do it. i have a page that runs through the application logic and then includes or redirect and includes the required template. when i've implemented tutorials with mixed logic and content, the first thing i did was try and seperate it. i have a logic page that is 2000 lines of code with probably another 500 lines of display... inserting multiple levels of html into that page would cause me to jump instead of just look over the edge... that's why i spent some time learning css... to get the presentation out of the display code. css cross browser support is a pain, but you can find others who have solved the issue and are generous enough to share their code - a shameless plug for sitepoint's own Paul. i tried to set up a phone app for a friend and css wasn't supported. i had to work with tables and style each td individually. i almost jumped and didn't finish the project. i told him to get a css enable phone browser or no dice.

    3. use classes (check the licenses, depending on intended use). i use Manuel Lemos' forms class and the adodb abstraction layer. man, both have been excellent, excellent resources. they both also help you learn how OOP concepts can help you to achieve your goals. for example, i get the benefit of client side validation w/o knowing how to do it in javascript. i can also apply ajax and use regexes to validate user input, not to mention use linked selects and whole lot more. i didn't use smarty because my template php based template system was just intuitive to me.

    4. always search for better ways. when you think you are done learning, you are simply *done*, as in "fork in the *ss" done. my friend's company is having trouble upgrading their code b/c the devs don't want to admit their code can be improved. he wants me to study the situation and render an opinion to help management. i already know the problem - and it is the attitude of the devs. they have static, repeating code everywhere, and don't want to improve the structure and incorporate a db to serve the data. that's a mangement issue that only management can solve. my opinion is that they would waste money on my opinion and still have the same problem, emotional and irrational devs. they want to pretend their code is the schznit and will fight, apparently to the death, any attempt to improve the code their god has ordained as truth.

    i learned to use heredocs to display my sql statements in a very readable format that alows easy copying between my query tester and my code. i'm reading agile web development for rails and applying the principles to my php code - i've already improved my templating system and reduced my repeated code. i learned how to apply bind variables for my queries. i still need to learn unit testing and need to learn when to apply html entities and when not to. you don't learn everything up front b/c you have to get stuff done, but learn bits as you go and then go back and improve your code. my gold page is a simple page where i make sure to implement everything i've learned... so when i update other pages, i know what page to reference for examples.

    i see the value of oop - it is huge. it greatly simplifies coding once implemented. however, i still struggle with planning it out, organizing it. i will just go through tutorials until it finally clicks after i get the requisite experience looking at the horizon instead of at my feet. but i will learn it and apply it. along with a whole bunch more.

    anybody else can feel free to critique this list and add to it.

  23. #73
    Spacebug Beansprout's Avatar
    Join Date
    Oct 2005
    Location
    UK
    Posts
    464
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by kuruption
    things like vBulletin are a waste of money if you know how to code well.
    Don't know about you, but for me the cost of developing a forum is far more than the $160-off they want.

    vBulletin is an incredibly powerul piece of software with a half-decent template system, and runs on a huge variety of server setups.

    Why criticise it for being out-dated? Of course it's outdated - its a huge amount of work to re-code something from scratch with the latest trendy techniques which may not even be compatible across all the current clientbase!

    Just look at Moderbill - v5 is taking *ages* to do - because they're re-coding a helluva lot of it.

    I agree phpBB is awful - and I also hate IPB (they still throw $_REQUEST DIRECTLY into functions!! SQL injection hell! (that was the latest exploit) - but vBulletin, I think, is fantastic - and the code quality isn't tooooo bad.
    Thermal Degree - web design with standards! (View our portfolio)
    Vidahost - shared and reseller linux hosting with real support
    Use my free file uploader!
    £5.99 .com/net/org/biz/us/name domains; £2.99 .info!

  24. #74
    Web developer Carl's Avatar
    Join Date
    Sep 2003
    Location
    sweden
    Posts
    320
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The best code I have seen as far as a GPL board is concerned is at http://www.mercuryboard.com. But the project is not active. I love the coding in this board (relatively speaking).

    There is a activity at http://www.quicksilverforums.com/ which is an effort to continue the project. But I have not looked at the code for this one.

  25. #75
    SitePoint Wizard Dean C's Avatar
    Join Date
    Mar 2003
    Location
    England, UK
    Posts
    2,906
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by z0s0
    You can't have "almost OOP". It is or it isn't. If it uses just one global variable, then they've dropped the ball somewhere. Trying to mix OOP and procedural produces a worse result that sticking to plain old procedural.

    I've got a lot of experience building "addons" (read: hacks) for vB and don't intend to ever again if I can avoid it.

    Re: fudforum, code like this turned me right away
    Code:
    /* this should allow path_info & normal themes to work properly within 1 forum */
    	if ($o2 & 32768 && !($u->theme_opt & 4)) {
    		$o2 ^= 32768;
    	}
    That's absolute nonsense. I worked over at vBulletin.org on the staff for over 3 years and have been modifying vBulletin since I started out as a programmer almost 5 years ago now. Modifying the software is very easy, and whilst I somewhat agree on mixing procedural and OOP concepts, I think it works very well for vBulletin


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •