Jump to content

Jessica

Staff Alumni
  • Posts

    8,968
  • Joined

  • Last visited

  • Days Won

    41

Everything posted by Jessica

  1. If you'd left them out of all the array elements, you can add them in with a foreach. Also, using range() you could have skipped writing all of the letters individually. <?php foreach($encodeTxtArr AS $k=>$v){ $encodeTxtArr[$k] = '~'.$v.'~'; } ?> It's a bit late now, but it was just a point
  2. Post the code that uses this array and I'll show you.
  3. lol. Edit: Hey genius, I was "lol"ing at your inability to read. No need to PM me and think we're friends now. Thorpe found your problem and you are still clueless.
  4. Yeah I keep all mine in a /lib folder.
  5. $query_forums = "SELECT * FROM forums"; There's your problem. You need to be much more specific with your query...
  6. Ah I see it now, Thanks thorpe
  7. Uhm, as you said, it's not accounting for over one week. You're only checking for the end date falling on a weekend, not any of the weekends inbetween.
  8. Is it set at that point in the code? I'm not sure what that other code is....isn't it javascript? Where is the code which tells the Javascript what value to put there?
  9. Well, you need to first figure out how many days it will take. Then use logic to determine how many weekends will be in there, based on the start day and end day. Then for each weekend, add two days to the total days. If the number of weekends is > 5 (I think) you'll have to check again for new weekends generated. I think you'll need to make a recursive function to do this.
  10. omg, no it's impossible to have more than one line of code. It's even more impossible to append strings or have mysql anywhere near conditional statements.
  11. You know, you could have saved yourself a lot of ~ typing
  12. http://www.phpfreaks.com/forums/index.php/topic,6264.0.html Obviously the $row['id'] is not set. We need to see more code.
  13. I always name my class files ClassName.php. I see a lot of people name them ClassName.class.php Why is this?
  14. <?php if(isset($_POST['password'])){ //change it }else{ //no change } ?>
  15. Hm. When you view the source of the page before submitting it, is the form's action set correctly?
  16. Well sessions last for the length of the browser being open. (IE, session.) However, PHP is server side, not client side. It can't tell when the client closes the browser. Javascript IS the way to go there. PS: The word you want is broken, not breaked.
  17. You need a user registration and login system. There are plenty of tutorials out there.
  18. You're missing a ; at the end of a line. Also, $mysql[access] is poor code, write $mysql['access'];
  19. Uhm, sure. However you get $rowid is up to you...you just need to start somewhere.
  20. I think pretty much any tech community besides MS feels everyone should RTFM. MS will take your money so you don't have to read.
  21. A drop down works like this: <select name="yourNameHere"> <option value="value1">Text1</option> <option value="value2">Text2</option> <option value="value3">Text3</option> </select> The relevant PHP code would be on your processing page: $selected = $_POST['yourNameHere']; //will be either value1, value2 or value3
  22. Think about it for a minute before asking. Then 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.