Jump to content


Staff Alumni
  • Posts

  • Joined

  • Last visited

  • Days Won


Everything posted by ManiacDan

  1. Ok, I'm going to explain this once more and then I'm done: You are trying to join race_results.position_fav_1 = alias1.fav. Now, think very hard: Are race_results.position_fav_1 and alias1.fav ever equal to each other? Ok, that's the problem. You have repeatedly insisted that those values are both equal and different. Are you trying to join on the wrong fields? Post the SHOW CREATE TABLE statements for both race_results and favourites. The query you gave as not working joins 7 tables but only selects from one of them.
  2. The political discussion that had started in this thread is now split into its own thread. Please use this thread to discuss domain registrars and web hosts only.
  3. A fox news reader!? GET HIM!
  4. GoDaddy supported SOPA, so a bunch of people transferred away from them (including big names like Wikipedia and Penny-Arcade). GoDaddy was interviewed about the mass exodus and said something to the effect of "we're seeing a lot of noise, but it hasn't hurt us financially at all." The hivemind decided to make an example out of them.
  5. I don't know if you're being serious or not, but it IS international dump godaddy day. I never had domains with them in the first place. "Titties 'n Nascar" is not an advertising campaign that appealed to me.
  6. Seriously, mysql_error(). Print it, or use the code mikosiko provided to get it. something is wrong with your syntax, field names, or table names. NOTHING is wrong with the IN clause you were given. The correct syntax for that is: WHERE fieldName IN (2,3,4); That is correct. That is what you supposedly have. The problem is that MySQL is complaining about other problems somewhere else, like the fact that you keep changing your capitalization or you've misspelled the tablename or something. Show us the error and we'll have a better shot at figuring out which mistake it is.
  7. Reddit has been researching this for you.
  8. That looks right. The code kicken gave you follows the same pattern, though you may have dropped a quote or something somewhere.
  9. One of us isn't understanding here... You have: -> LEFT JOIN favourites AS alias2 ON race_results. position_fav_2 = alias2.fav That implies that favourites.fav is the same as race_results.position_fav_2. But you try to DISPLAY favourites.fav. So just drop your joins entirely and display race_results.position_fav_2. See? Your query doesn't need the joins or this other table AT ALL. Unless you're trying to do something else that you haven't mentioned.
  10. You don't need to join these tables at ALL if you already have all the values of favourites.fav in the race_results table.
  11. Learn to think for yourself and the world will be a lot easier for you. I didn't tell you to execute the query just like nobody tells you to lift the toilet seat before you pee. If I was on a power trip I'd ban you or something, but I don't care. I wanted to help, and in fact gave you the framework you needed to get started. You didn't fully implement the framework that I gave you and you didn't take it to its logical conclusion: executing the query. Any version of "you didn't actually execute the query" would have sounded sarcastic. Also, identifying yourself as "not a programmer" here on this professional programmer forum might change the quality of the answers you get. Like I said earlier, I assumed you had a certain level of skill when I gave you the outline of the changes to your application. All I know is your name. I automatically assign you an average level of skill unless told otherwise. As for your actual problem: If you've made the changes kicken suggested to your query, and you've added the actual query() function, it should be working. If it's still not working: 1) Echo the query itself, copy and paste it here and we'll look at it. 2) echo mysql_error() after the query is run and you can see the actual MySQL error, which you can use to debug on your own if you know enough SQL. Otherwise, we'll look. When you say print_r gave you that output, you mean print_r($_POST['close']), right?
  12. Actually I was just wrong. Kicken noticed that I gave you the solution for array values, when I had given you the form input for the keys. That was unintentional. Forgetting to run a query isn't something we can gently point out, so we default back to sarcasm. Speaking of which, you're still not running $closequery, and it's still not inside the isset() check. Kicken's code was a snippet, designed to be INSIDE of the isset() check that I told you to write, and FOLLOWED by something that actually makes use of the variable. Execute the query. If that doesn't work, echo the query to see if it's malformed. If it is, figure out which variable is causing the problem. Echo that variable, print_r($_POST), do something to debug this on your own. You were given the basic structure because (a) I didn't want to actually write the 25 lines of example code for you, and (b) I assumed all you needed was the basic structure, and any error checking, debugging, and running of queries could be done on your own.
  13. $body = "Date Sent: $myDate\n Parent's Name: $ParentsName Best Phone: $BestPhone Email: $Email Student's Name: $StudentsName Student's School: $StudentsSchool\n\n"; if(trim($SATTest1) != "" ) { $body .= $SATTest; } mail( "me@digital.com", "Sign-up Sheet Request", $body, "From: {$Email}" );
  14. Remember back when I wrote my first post and I put "check if $_POST['close'] is set"? You actually need to do that.
  15. You can alias a single table however many times you like: SELECT * FROM Table1 JOIN Table2 AS alias1 ON table1.id1 = alias1.id JOIN Table2 AS alias2 ON table1.id2 = alias2.id' //etc. -Dan
  16. the slideshow effect leaves lines on the images (chrome 16.0.9 under linux). Otherwise, nice.
  17. $row is an entire row (meaning array), you'd need {$row['id']} or something similar, but I don't know what your query/table looks like.
  18. Basic steps: - Wrap the entire table in a form tag - Name all your checkboxes name="close[123]" where 123 is the ID of the row it's on. - At the top of this page, after you connect to the database but before you select the rows to build the table: > Check to see if $_POST['close'] is set. > $query = "UPDATE thisTable SET closed = 'Y' WHERE theTableID IN ( " . mysql_real_escape_string(implode(',', $_POST['close'])) . ")"; > (handle errors) - Fetch the rows from the table and display as normal.
  19. You need to use javascript/ajax for this if you don't want to load all this data before the page is rendered.
  20. The only reason do split into two servers is to alleviate load problems (or for some very obscure security reasons). If you don't have any load problems (which you shouldn't at 1 query every 6 seconds) then you don't need to split them. Splitting unnecessarily will actually hurt, since you'll be increasing your page load times waiting for DB connections across the network.
  21. Now that your menus no longer float, the auto-scroll should be removed. Visiting a new page should start at the top of that page unless there's a good reason to believe people don't need your headers. Browsing your site is "click. scroll up. click. scroll up. click."
  22. Are you following the advice of that reddit thread? If so, good work. Either way, this looks like a nice site. You need to trim down the size/loading time of that club sandwich image and put something in the footer. Also, there's some kind of debug popup that appeared for me when the page finally finished loading. Clicking "about suzie's" caused the page to perform some local action which made things move around in random directions. I ended up looking at a blank grey rectangle with a left arrow hovering in the top right. Nothing else happened. The left arrow looked like a very bad CSS bug resulting from left/right arrows for a gallery or slideshow or something, but it turns out it's your menu. Don't auto-hide navigation elements. what if I was on a smart phone or tablet? Show the menu all the time, especially if the alternative is a "go to the previous image" arrow in the wrong place. Also, that page never loaded. Clicking on the menu caused the same "things go in random directions" maneuver that I don't really like, then BACK to the same empty grey rectangle, which was eventually filled in (after 8 seconds) by a menu that didn't fit in the current site layout. Contact Us and Specials are broken/no content. Edit: And the logo in the header should return to the main page. there is currently no way to get back to that picture of the sandwich. I like the design, but keep the menu where it belongs, fix the transitions, make the menu fit into the site design (since that's the entire purpose of a restaurant website), and finish adding content to those other 3 pages, even if it's just "the history of the company goes here lorem ipsum dolor sit amit..."
  23. If you open a string with double quotes, you must close it with double quotes: $message = "Dear Administrator,\n\nthe following distributor\n\n" . $row_admin_login_RS['distributor_company_name'] . "\n\nHas modified his Distributor information record.\n"; The code you posted would (probably) throw a fatal PHP parse error. Are you not showing errors?
  • 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.