Jump to content

Jessica

Staff Alumni
  • Posts

    8,968
  • Joined

  • Last visited

  • Days Won

    41

Everything posted by Jessica

  1. No, we know exactly how your database is structured. And it's wrong.
  2. So, this morning my fridge started to flood. My husband, being a smart man, listened to me when I said it was happening when we tried to use the water dispenser, and together we figured out that the water filter had frozen and cracked. He then used the collective knowledge of the people around him to decide that 36 degrees was too cold for our fridge, and we should replace the filter. If I was married to this guy, we'd simply move the fridge into the tub so the water would drain out there, and eat frozen yogurt. By which I mean the yogurt that had frozen within the fridge, not the delicious dessert. When we'd want to take a bath, we'd probably go outside and use the kiddie pool for that. And so on, and so on. Now I want some fro-yo.
  3. You need to normalize your data. Each of those should be it's own row. Google "normalization".
  4. WHERE category = 'category' ORDER BY name DESC
  5. Look at the last character on the line before your foreach.
  6. Plus the suppression way gives a different result than the ternary, in the event that its not set.
  7. SQL can do a lot of math, faster and easier than PHP. If you share the math you're doing, we may be able to help you do it all in SQL.
  8. I just told you how... What are you asking?
  9. Give both of them a value. Since they have different names, they will have different values. What you're describing doesn't make any sense, and you haven't shown any proof of it. Edit: Do you think 'ccr-01-002' is the value? It's not. It's an array key. What you get when you print_r or var_dump your arrays is a bunch of keys with empty values.
  10. ORDER BY category DESC, name DESC
  11. jQuery. You're not asking a very specific question, so you're not going to get a very specific answer.
  12. That code has absolutely nothing to do with the other code. You also didn't answer my question or say if you changed it to match my suggestion.
  13. A cunning use of if control structures, the isset() function, and some logic will get it done.
  14. How about you just copy and paste the ACTUAL code then, so you don't make more mistakes? Run a print_r($data); - what do you get? Also, do this instead: <?php $directory = get_bloginfo('stylesheet_directory'); echo '<link rel="stylesheet" type="text/css" href="'.$directory.'/admin/layouts/'.$data['alt_stylesheet'].'" />'; ?> Easier to read.
  15. For anyone else who doesn't get it: OP is working with a negative - If he wants to exclude anything that has one column set to 34, OR a different column set to 34, that means EVERY row which has any value but 34 on BOTH columns. Row Col Col A 31 34 B 34 31 C 31 31 D 34 34 He wants row C. Col1 != 34 AND Col2 != 34. Anything else is not a valid match
  16. You never ended your PHP after echo'ing it. You should have a fatal error.
  17. in the second, you probably want to change category.id_parent != '34' OR category.id_cat != '34') to category.id_parent != '34' AND category.id_cat != '34')
  18. "NULL" is a string. Try contact_id IS NULL If that doesn't work, post your table structure, and some screenshots of the actual rows.
  19. I don't even follow you... what local files are you talking about? Are you saying you're just opening the file in the browser? Or are you running a webserver and going to localhost/file.ext? The first will not work, the second will. When you run it and it doesn't work, what happens in Firebug?
  20. Really? No, only one of them does. This, except don't delete anything, just store it. We also don't know if the OP wants to record outgoing links as well which would require more work. How do you think that would do what I'm describing? It doesn't...
  21. There are so many problems there. 1 user plus 2 guests plus 0 anon = 4???? And Barand is a user, so what's Google? ONE of the guests? Or is it 1 user plus 2 guests plus google?
  22. Edit: Screw that, I just saw your nasty butt response to Dan, and I retract my help.
×
×
  • 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.