Jump to content

Search the Community

Showing results for tags 'if statement'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • W3Schools
    • General
    • Suggestions
    • Critiques
  • HTML Forums
    • CSS
  • Browser Scripting
    • JavaScript
    • VBScript
  • Server Scripting
    • Web Servers
    • Version Control
    • SQL
    • ASP
    • PHP
    • .NET
    • ColdFusion
    • Java/JSP/J2EE
    • CGI
  • XML Forums
    • XML
    • Schema
    • Web Services
  • Multimedia
    • Multimedia
    • FLASH

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start





Website URL








Found 4 results

  1. Hi everyone, I need a little help with trying to figure out what I need to do. I am writing an IF statement that allowed only certain users can see. So what I am trying to do, in my DB i have it created that if you are going to have certain access, the value in the DB is set to '1' for true. What I need help with is seeing how I can write and IF statement that reads that value and allows the user to see it. This is the current code I have: <?php if (isset($_SESSION['id'])) { echo "Welcome"; } else { echo "You not logged in or don't have access."; } ?> With t
  2. I would like to create a stored routine for MySQL that figures out the number of business or working days for a month (Working Days are Monday thru Friday). I have not created the procedure portion of it yet as I want to ensure that the code works first. Please note that there is a function called first_day. This is a function provided by my hosting provider. I also have another function for this that will figure out the first day of the month if I didn't have it from the hosting company. It is not currently used and can be removed for testing purposes. I am testing this through phpmyadmi
  3. I've created some if / else statements to get a download when a user hit click jf he fields name and email but doesn"t work for my site http://my-easy-woodw...ng-projects.com because it is do download without field name and email contact.php is <?php$field_name = $_POST['cf_name'];$field_email = $_POST['cf_email'];$field_message = $_POST['cf_message'];$mail_to = 'dedalusonline@yahoo.com';$subject = 'Message from a site visitor '.$field_name;$body_message = 'From: '.$field_name."\n";$body_message .= 'E-mail: '.$field_email."\n";$body_message .= 'Message: '.$field_message;$headers = 'From:
  4. jnymris

    MySQL If statement

    Morning/Afternoon All, I'm trying to create a simple if statement in SQLThis has been casuing me so much trouble since yesterdayHere's what i'm trying to achieve. IF((SELECT COUNT(*) FROM computers WHERE name='PC-01' AND domain='mydomain.local')==1)SELECT ComputerID FROM computers WHERE name='PC-01' AND domain='mydomain.local'ELSE IF((SELECT COUNT(*) FROM computers WHERE name='PC-01' AND domain='mydomain')==1)SELECT ComputerID FROM computers WHERE name='PC-01' AND domain='mydomain'ELSE IF(SELECT COUNT(*) FROM computers WHERE name='PC-01')==1)SELECT ComputerID FROM computers WHERE name='PC-01
  • Create New...