Discover Habbo's history
Treat yourself with a Secret Santa gift.... of a random Wiki page for you to start exploring Habbo's history!
Happy holidays!
Celebrate with us at Habbox on the hotel, on our Forum and right here!
Join Habbox!
One of us! One of us! Click here to see the roles you could take as part of the Habbox community!


Page 3 of 4 FirstFirst 1234 LastLast
Results 21 to 30 of 38

Thread: PHP help.

  1. #21
    Join Date
    Mar 2008
    Location
    Swindon, UK
    Posts
    1,274
    Tokens
    187
    Habbo
    :Ltd

    Latest Awards:

    Default

    See the . (dot) as a + (plus) for example.

    So you don't go in maths 10+5+
    Hi, names James. I am a web developer.

  2. #22
    Join Date
    Sep 2006
    Location
    Evanston, Illinois.
    Posts
    2,361
    Tokens
    0

    Latest Awards:

    Default

    My version is messier? How so? All I did was take out his ( )'s on the language constructs, as they don't need them. And took out useless concatenations. Calon, I meant what Invent! said, don't get snappy with me.

    Ooh Protege, after reading your second response, it's even funnier.

    PHP Code:
            while( FALSE === ( $mysqlFetch mysql_fetch_array$mysqlQuery ) ) ) 
    Please tell me your not serious. Why on earth would you clarify a boolean value against something that automatically returns a boolean value.

    In your query why would you check if the number of rows is SMALLER THAN or equal to 0, how would it be smaller than zero?

    SELECT * FROM `database`

    I won't be picky about that seeing as it would work, but seeing as you wrote 'database' it should be SELECT * FROM database.`table`

    Why wouldn't you just put in an or die(mysql_error()) after your mysql_query, that way you can have some informative information upon error.

    And your still using parentheses in your language constructs, which is bad practice.

    I'll get flamed for this but whatever.
    Last edited by Hypertext; 05-08-2008 at 12:57 AM.
    How could this hapen to meeeeeeeeeeeeeee?lol.

  3. #23
    Join Date
    May 2005
    Location
    San Francisco, CA
    Posts
    7,160
    Tokens
    2,331

    Latest Awards:

    Default

    My version is messier? How so?
    His coding is a lot more fluent and clean. He has used whitespace properly which makes his coding easy to read and understand. (Which will help immensly if debugging is needed).

    Thats how and why I think your code is messier.

  4. #24
    Join Date
    Jul 2008
    Location
    Hastings, UK.
    Posts
    2,050
    Tokens
    0

    Latest Awards:

    Default

    Quote Originally Posted by Invent View Post
    His coding is a lot more fluent and clean. He has used whitespace properly which makes his coding easy to read and understand. (Which will help immensly if debugging is needed).

    Thats how and why I think your code is messier.
    He fixed it already.

  5. #25
    Join Date
    Apr 2008
    Location
    England.
    Posts
    1,324
    Tokens
    0

    Latest Awards:

    Default

    Quote Originally Posted by Hypertext View Post
    My version is messier? How so? All I did was take out his ( )'s on the language constructs, as they don't need them. And took out useless concatenations. Calon, I meant what Invent! said, don't get snappy with me.

    Ooh Protege, after reading your second response, it's even funnier.

    PHP Code:
            while( FALSE === ( $mysqlFetch mysql_fetch_array$mysqlQuery ) ) ) 
    Please tell me your not serious. Why on earth would you clarify a boolean value against something that automatically returns a boolean value.

    In your query why would you check if the number of rows is SMALLER THAN or equal to 0, how would it be smaller than zero?

    SELECT * FROM `database`

    I won't be picky about that seeing as it would work, but seeing as you wrote 'database' it should be SELECT * FROM database.`table`

    Why wouldn't you just put in an or die(mysql_error()) after your mysql_query, that way you can have some informative information upon error.

    And your still using parentheses in your language constructs, which is bad practice.

    I'll get flamed for this but whatever.
    Well I appreciate your comments but this was a quick script for someone I do part-time work for, there wasn't really any need to make all the coding clean and use or die statements as I knew this couldn't have been a connection error due to the order being processed but not displayed. In the end I just deleted my whole database, created a fresh one and gave it new names. Seems the database got locked up when I originally deleted the whole lot of information - shouldn't have used a while statement on 1 order I guess, just fetch the array. All part of the learning curve I guess!

  6. #26
    Join Date
    Jul 2008
    Location
    Hastings, UK.
    Posts
    2,050
    Tokens
    0

    Latest Awards:

    Default

    I wasn't getting snappy, I was worrying if you would get your imaginary paycheck from IN VALID SOFTWARE, INC.

    Sorry for caring.

  7. #27
    Join Date
    Sep 2006
    Location
    Evanston, Illinois.
    Posts
    2,361
    Tokens
    0

    Latest Awards:

    Default

    Oh stop being a ******* jealous pisshead mother****** as your like is just one big epic fail.

    As soon as I prove your coding to be **** as, you make up some garble of a retort.

    Invent!, my IDE was habbox forum quick-reply, you can't expect much in the way of whitespace. Also removing all whitespace and taking away parenthesis in his language constructs would still be cleaner code than his.
    How could this hapen to meeeeeeeeeeeeeee?lol.

  8. #28
    Join Date
    Mar 2008
    Location
    Swindon, UK
    Posts
    1,274
    Tokens
    187
    Habbo
    :Ltd

    Latest Awards:

    Default

    Not really, I can read my code and code in that form much easier than yours, you put curley brackets on the same line as the statement, what for to make it even harder to read? They're on new lines so you can easily align start/end of each statement/function... so don't think you 'removing whitespaces' will in anyway will make it cleaner, cause really it won't.

    Also for your little thing parenthesis on echos, dude your losing the battle to get your point across cause really = fails.

    PHP Code:
    $hText 'noob' ) ? echo( 'true' ) : echo( 'false ); 
    Result:
    true
    I could be compressing my PHP in my real version to 'save space', dude at this point I'd insult you.
    Last edited by Protege; 05-08-2008 at 05:03 AM.
    Hi, names James. I am a web developer.

  9. #29
    Join Date
    Jul 2008
    Location
    Hastings, UK.
    Posts
    2,050
    Tokens
    0

    Latest Awards:

    Default

    Quote Originally Posted by Hypertext View Post
    Oh stop being a ******* jealous pisshead mother****** as your like is just one big epic fail.

    As soon as I prove your coding to be **** as, you make up some garble of a retort.

    Invent!, my IDE was habbox forum quick-reply, you can't expect much in the way of whitespace. Also removing all whitespace and taking away parenthesis in his language constructs would still be cleaner code than his.
    LOL CALM DOWN!

    I am new to coding.

  10. #30
    Join Date
    Mar 2008
    Location
    Swindon, UK
    Posts
    1,274
    Tokens
    187
    Habbo
    :Ltd

    Latest Awards:

    Default

    epic fail, thats right when used against yourself. He's like Klydo, loolage - must be fegbrothers
    Hi, names James. I am a web developer.

Page 3 of 4 FirstFirst 1234 LastLast

Posting Permissions

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