Jump to content

Maq

Administrators
  • Posts

    9,363
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by Maq

  1. Good. The only type you don't have to put single quotes around are integers.
  2. Put single quotes around $username: WHERE username='$username'";
  3. I like putting the query in a string first, that way you can echo it out and see what it actually contains, and it's easier to manipulate.
  4. It's just an associative array. Here, learning by example is probably the best in this case. $example = array('skillswidget:red' => 'red', 'skillswidget:blue' => 'blue', 'skillswidget:black' => 'black'); // This will output the entire array print_r($example); // Print out a single element echo "Color: " . $example['skillswidget:black']; ?>
  5. Missing ';' after $id"
  6. It's basically the same syntax, simple Google search could have solved this. between
  7. I think it's safe to assume he's using Microsoft SQL Server.
  8. Echo $sql_update to see what the actual values are. Please use tags around your code.
  9. Your date field has to be either type 'date' or 'timestamp'. It can't be a varchar.
  10. Maq

    Query ?

    What is the actual order? What type is length?
  11. It's type casting $langauges_id to an integer. Read more here - Type Juggling (scroll down to Type Casting).
  12. First you should use double quotes for your link variables. Second, you have to use the GET method and tack on the variable to the end of the URL. Or you can use a hidden field and pass it along. Or you can use sessions. The first option is the easiest. if ($v==1) $resulturl ="../thanks.htm"; else $resulturl ="../incomplete.htm?v=$v"; $headers = "From: $from ". "\r\n"; header("Location: $resulturl"); Now when you get the incomplete.php you have to use $_GET['v']; to retrieve the value.
  13. I don't even know where the error even was... You should only be using back ticks ` around table and field names, and single quotes ' around values (except INTs).
  14. Relax. Bitching every 10 minutes will not increase the speed of help, in fact, it does quite the opposite. Echo $insql and see what's actually being passed. Seems impossible to update every row when you have LIMIT 1, there's something else going on. Where is $r['id'] coming from? And why is your SQL in your form?
  15. That comma must have fell down off of audit.
  16. Missing a comma after $audit. Please use tags around code.
  17. I understand that. But I have faith in you, and I'm sure you'll be able to find something
  18. Tableless is much better in this case. The overall site looks better. Some quickies: - Your site still doesn't validate. Not sure if it did before or you care, I guess it did since you have the icon. - The, "Power Control Automation" text bleeds through the button. (FF/Ubuntu).
  19. I'm sure there are a few examples out there that do exactly what you want, but I don't feel like searching, that's your job. What you can do is search for each component, like forms, drop downs, submitting your page to itself, the POST method, MySQL & PHP, etc... Good luck, come back if you have a specific question.
  20. I'd wear some undies. i would wear a fanny pack. and ONLY a fanny pack Hahaha, I'm sure the ladies would love the 'old guy at Disneyland look'.
  21. The proper way to handle this is to add them to the sudoers list. That way you don't have to give them the root password and you can adjust settings for each user in the list. Google "Sudoers" and there should be some helpful results.
  22. Don't we all... You have to use fopen and fwrite.
  23. The best way to approach this is to have 3 drop down menus for each date. This approach allows you can control the range, input, and almost eliminate mistakes. You would submit the values either to the same page or a processing page, and use the POST values in the query. You mentioned earlier that you already had a working form, so you should be familiar with this. There are also plenty of examples and tutorials from Google.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.