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 8 of 8
Like Tree2Likes
  • 1 Post By Vapr_Arts
  • 1 Post By tiabutcher

Thread: What are Conditions in Javascript?

  1. #1
    Member
    Join Date
    Aug 2014
    Posts
    88
    Member #
    40011
    Liked
    2 times

    What are Conditions in Javascript?

    What are Conditions in Javascript? Need a few examples

  2.  

  3. #2
    Senior Member Vapr_Arts's Avatar
    Join Date
    Oct 2013
    Location
    California
    Posts
    1,923
    Member #
    37412
    Liked
    544 times
    Google is a great tool.. You can literally type
    In your title and get tons of answers.. Try it sometime..

    Javascript conditions are If, Else, Else If, and Switch statements that are used to check a "condition" and do something based on that condition.. If you want to know more you can google it and LOTS of examples show up


    Regretfully sent from my iPhone using Tapatalk during lunch and other breaks
    Ronald Roe likes this.

  4. #3
    Banned
    Join Date
    Sep 2014
    Posts
    38
    Member #
    40158
    Liked
    2 times
    In JavaScript we have the following conditional statements:

    Use if to specify a block of code to be executed, if a specified condition is true
    Use else to specify a block of code to be executed, if the same condition is false
    Use else if to specify a new condition to test, if the first condition is false
    Use switch to specify many alternative blocks of code to be executed
    James92 likes this.

  5. #4
    Senior Member Ronald Roe's Avatar
    Join Date
    Mar 2011
    Location
    Oklahoma City
    Posts
    3,139
    Member #
    27197
    Liked
    959 times
    Quote Originally Posted by Vapr_Arts View Post
    .. You can literally type In your title and get tons of answers.. Try it sometime..
    No, no. Allow me.
    Ron Roe
    Web Developer
    "If every app were designed using the same design template, oh wait...Bootstrap."

  6. #5
    Member
    Join Date
    Aug 2014
    Posts
    88
    Member #
    40011
    Liked
    2 times
    Ronald Roe how did you film your screen like that? Gotta say that was a pretty awesome link to click

  7. #6
    Senior Member Vapr_Arts's Avatar
    Join Date
    Oct 2013
    Location
    California
    Posts
    1,923
    Member #
    37412
    Liked
    544 times
    Quote Originally Posted by James92 View Post
    Ronald Roe how did you film your screen like that? Gotta say that was a pretty awesome link to click
    Its a website.. "Let Me Google That For You" or LMGTFY.com

    Besides being wowed by the link did you happen to find the answers you were looking for?

    Did you see that he used your title and google answered it for you? I really dont mean to be an ******* but it just seems like you didnt even attempt to do any research on your own before posting the question.


    Regretfully sent from my iPhone using Tapatalk during lunch and other breaks

  8. #7
    Member
    Join Date
    Aug 2014
    Posts
    88
    Member #
    40011
    Liked
    2 times
    Ya I got all my answers in tiabutcher comment and your first comment Vapr_Arts that was exactly what I was looking for.

  9. #8
    Banned
    Join Date
    Sep 2014
    Posts
    21
    Member #
    40215
    Liked
    1 times
    Hi the java script conditions are,
    1.if
    2.else,
    3.ifelse
    4.switch.
    ex

    if (time < 10) {
    script = "Good ";
    } else if (time < 20) {
    script = "Good day";
    }
    else {
    script ="gd";
    }
    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 09:18 AM.
Powered by vBulletin® Version 4.2.3
Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com