Jump to content

.josh

Staff Alumni
  • Posts

    14,780
  • Joined

  • Last visited

  • Days Won

    43

Everything posted by .josh

  1. You know, I don't really care all that much for socks. I usually wear sandals wherever I go. But I do usually wear socks around the house because I have hardwood floors and I hate walking on hardwood floors. Not because I think it's cold. Just don't like the hardness. I wish I had nice fuzzy carpet
  2. I suspect it's going to look something along the lines of UPDATE rate_members SET m_'year'='....
  3. hmm okay well how about putting your query string into a variable and echoing it out to see if it's what you expect.
  4. Really? I usually put on 3 socks when I'm cold.
  5. Just throw a ternary assignment into the loop. Something like this: $color = ($color == '#FFFFFF')? '#000000' : '#FFFFFF'; Then just throw the $color into the bgcolor value or however you have the html/css setup. Color will initially be assigned white because it will initially not be anything. Next loop iteration since it's white, it will be assigned black. Just keeps switching back and forth like a uh, switch. You can, of course, change what colors you want to use.
  6. Looks like you are making your foreach loop execute only the first statement. Move your opening { back one line: foreach ($_POST[add] as $col => $value) { $_POST[add][$col] = strip_tags(stripslashes($value)); mysql_query("UPDATE rate_members SET m_'".$col."'='".sql_escape_string(stripslashes($value))."' WHERE m_id='$m_id'"); }
  7. Just look at the script. There's already vars in the script that do the same thing... Look how the links are made in the script. Look how they are received in the script. Just do your copy and paste thing and change the name to what you want and there you have it. Don't really know what else we can tell you beyond that, except to learn to be more than a cut and paste guy....or hire someone to do it for you.
  8. I'm with akitchin on this...I know English isn't your first language and I'm sure you write/speak just fine in your native tongue, but as far as getting gigs is concerned, you should probably focus on beefing up your English skills if you want people to take you seriously.
  9. peanut butter waffles ftw.
  10. LoL how about instead of agreeing and saying your sorry you actually tell us what the problem is? Is it not working because none of the cases are being triggered (nothing being echoed from any of them)? Is it not working because the wrong one is being triggered? Some kind of syntax error? Any error messages being displayed at all? Come on man...
  11. Yeah okay we get it, the switch isn't working. But again:
  12. shouldn't you be doing value="$month_id" ?
  13. .josh

    Page Links

    http://www.phpfreaks.com/tutorial/basic-pagination/page10
  14. Yes problem is that the POSTED value is not persisting. You need to make your values session variables or else add them to your links to be passed as GET vars and check for them if there are not posted values.
  15. foreach($keynb as $key => $val) { $newlist[$val] .= $key . " "; }
  16. Sorry bro I really don't understand what you're trying to accomplish. You say that your first array has words as keys and the values are how many times they appear in some document, right? Easy enough to understand. But then you say something about how the values are also somehow stored in your second array. But then you turn around and say that you just want to echo the actual words? So...I really don't understand what you are trying to accomplish here. -What is the difference between these two arrays? -Are you trying to make some kind of comparison between the two? -If all you are trying to do is echo the actual words, use a loop and simply echo them example: foreach($array as $key => $val) { echo "$key <br/>"; }
  17. yeah that's what I meant. Typo. Was working on some session vars in a piece of code.
  18. So...basically you want to somehow link for instance click: syktt sewsgc lbdxn ttjklz lrvht tmdec ?
  19. Sure, just make a name and wrap some brackets around it. function callme() { // code here } I'm afraid that's about as specific as I can get, though. Were you wanting to wrap that whole thing into a function? Just the connection stuff? Connection and query? Just the output? Plan on abstracting variables out of it? It really depends on how you have designed/plan on designing the rest of your script.
  20. You would use what thorpe said: $_SESSION['PHP_SELF'].
  21. Would you have preferred I moved your thread to the html help section and given you a warning? I think pointing someone in the right direction is very helpful. To each his own, I guess.
  22. Perhaps you should give an example of the two arrays, but perhaps array_intersect might be of use?
  23. www.google.com
  24. you would do it with html or css.
  25. .josh

    Akinator

    Meh. I have a 20 questions ball does the same thing.
×
×
  • 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.