Jump to content

ober

Staff Alumni
  • Posts

    5,327
  • Joined

  • Last visited

Everything posted by ober

  1. No issues here.  How often are you seeing it?
  2. Sorry, PHP cannot specify a local directory.  It is a server side scripting language only.  The status/size/speed will all have to be done with something like AJAX.
  3. OOPS!  yeah... I'm running Opera, version 9.01.  Opacity is supported in version 9+. And I'm pretty sure you can override the context menu... I couldn't tell you how, though.
  4. I would submit that it only takes one person to find the hole in your system.  Why give someone that chance?
  5. I'm not sure what might be causing that.  Does it still run the program? By the way, it's "error"... no "e" at the end. Welcome to the forums.
  6. [code] <?php include "connect.php"; echo "<DIV ALIGN='center'>"; $result = mysql_query("SELECT content FROM content") or die(mysql_error()); while($row = mysql_fetch_array($result)) {   ?>   <div id="header"></div>   <div id="content">   <p>   <?php   echo $row['content'];     ?>     </p>   </div>   <div id="footer"></div> <?php echo "<BR />"; } echo "</DIV>"; ?> [/code] Try that.  You really shouldn't combine all your functions like that.  It makes it a nightmare to troubleshoot.  Also, this is not where you want to use a foreach.
  7. *lights torch* Alright... this has been debated in the past pretty heavily.  We've had some new versions come out over the past few months, so I think it's worth revisiting. SO!  Post your browser and version and provide at least 5 reasons why (detailed if unclear) you think you're running the best browser out there. [list] [*]Wand - username/password manager.. better than FF's and it even clicks the enter button! [*]Paste and Go - copy link, right click in address bar and hit paste and go... saves time [*]Most builit-in functionality out of the box [*]Most standards compliant browser in existence [*]Super fast [/list]
  8. I don't know what else to say then.  Also keep in mind that hotmail and msn have delays.  You may not get mail right away with them. Also, I've told you this before... please use more descriptive titles for your threads.  If you do it again I will suspend your account for a few days.
  9. So you do a simple COUNT() query on the database and plug the result of that query into the random function. Does that make sense or do you need help writing the query?
  10. Ok... well I'm going to assume that you only have one county at this point and you want to be putting the City recordset in the while loop instead.  Also, to save some processor time, put the extraction of the county recordset outside of the while loop and set it's value equal to a variable that you use in the while loop.  (I'm not sure why you want to list the county each time... but whatever.)
  11. Can you post your latest code?
  12. If rsCity is available and you have used mysql_fetch_assoc on it, you need to extract that as well. I was trying to give you an example of how to do it.  You need to manipulate it to match your own coding.
  13. Ok... so... does the code I gave you help?
  14. Well, it all depends on how you trap your errors and what kind of error reporting  you have enabled in the php.ini file.  You really shouldn't be designing a code that "could have errors" that you just ignore.  You should ALWAYS trap errors and if they don't matter, you move on appropriately, but if they do, you should have an error log or a system that emails you the errors.
  15. Alright.  So you have your selection on the first page.  On the next page you want something like this: [code]<?php $query = "SELECT schools FROM school_table WHERE city_id = '" . $_POST['city_id'] . "'"; $result = mysql_query($query) or die(mysql_error()); if($result && mysql_num_rows($result) > 0) {   while($row = mysql_fetch_assoc($result))   {         extract($row);         echo "$school_name<br/>";     } } ?>[/code] Does that help?  Also, you have to make your city names into links that link to this page with the ID value of the city... or you create a form with a drop-down that submits to this page.
  16. ORDER BY date DESC, ID DESC LIMIT 1 ahh... beaten.  Good one, Jenk... but at least my example shows that you can sort both ASC/DESC.
  17. Welcome to the forums, please use a more descriptive title when creating threads!  Thanks! As far as your code... you're jumping in and out of PHP WAAAAAAY too much.  You should also never use a do... While loop.  You're forcing the code to run no matter what the first time.  If the code doesn't need to run the first time, you're going to get errors. New code:[code] <?php  if($row_rsPages['Id']== "15") {    while ($row_rsCounty = mysql_fetch_assoc($rsCounty))   {       extract($row_rsCounty);       echo "<h2>$countyName</h2>$cityName";   } } ?>[/code] As far as the logic, you may need to describe the problem a little better.  What are you expecting for output and what is your input?
  18. Ok, a few things: 1) I don't trust the empty() function.  Some people do, it's a personal preference.  There are other, better ways to compare strings to null or nothing that will ALWAYS give you a valid response.  empty() will not. 2) I try to avoid using die() and exit() as much as possible.  You should be able to trap errors and provide a much cleaner way of handling errors than simply dumping out of your script.  It takes some extra work, but it can be done. 3) if ($count == 0) { if ( $pass1 == $pass2 ) { This is unnecessary.  These can be combined into one if statement: if ($count == 0 && $pass1 == $pass2 ) {
  19. No, it doesn't have to be flawless (although all code should be ;) )  If you're working from a different server and getting "invalid argument" or "invalid resource", I'd question whether you're talking to your database correctly or not.  Can you verify that?
  20. You need to use the COUNT SQL function to grab the number of these items.  You'll have to run an extra query, but that'll get the information you're looking for.
  21. ober

    2 cents

    I will just say that I agree with a lot of Steve's comments.  However, I don't think the logo is all that bad and I don't think links throughout the site is all that bad.  I'd rather have more links than not enough, know what I'm sayin? The site does feel somewhat "template-ish", but if it is a template, it's a good one.  It's clean, gets the point across and displays the information cleanly. My only complaint is that it feels as if you have too much "disclaimer" text. I know the bulk of it is in the footer, but just glancing at the page, your content is kind of crowded by this overwhelming feeling of being crushed by the disclaimer.  You could probably hide the disclaimer a little more and re-work the other elements to make the content POP more.
  22. I've added a few more things to the description as well.
  23. I did list some of the categories in the description.  Also, if you wouldn't mind, I'd appreciate if you created a thread of valid categories and I will sticky it.
×
×
  • 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.