Jump to content

Balmung-San

Members
  • Posts

    327
  • Joined

  • Last visited

    Never

Everything posted by Balmung-San

  1. Somebody forgot which quotes they were using. echo "<a href='".$myrow1['url']."' target='_blank'><img src='".$myrow1['thumb_url']."'></a>"; That should work now.
  2. I'm not sure what you want to do. As well, your colors are painfully blinding. You've given us absolutely nothing to work with. Perhaps you could write out a full sentence of what you want to do, as well as removing anything that has no relevance ("table name='Books', field name='name'").
  3. Did you put the nl2br before or after that? I would highly suggest placing it after that. As well, this is more a personal irk, but I would suggest using strcmp or stricmp when comparing strings.
  4. I'm not too familiar with how PEAR works, but I believe it's designed so that you can just drop the file into your directory and use it. That is, you should be fine by moving it into the same directory as this file.
  5. I believe you'd be looking for the [url=http://www.php.net/nl2br]nl2br()[/url] function.
  6. It looks to me like you don't have a file called "DB.php" in the same directory as the file you're trying to run.
  7. Who told you that a non-scrolling collage background would be a good idea? Next time you see them, punch them in the face for me. Seriously, the site needs an overhaul design wise.
  8. Loading files into a database is a great idea, it takes less space on the server (especially if you're skilled enough to gzip the file at runtime). Why are you against it? How exactly does it take up less space on the server? It takes up the same amount of space within the database file as it does to save it elsewhere, as well as the minor space that will be taken up by declaring a new field. You can gzip a file no matter which path you take. As well, storing it there makes it harder to manipulate the data externally. That is, if you store an image I can manipulate it easier by saving it elsewhere then saving that data. Also, transferring that data between your database server and your PHP parser will have a serious effect on your site, where as pulling a small string (less then 255 characters) takes much less time, and you can easily echo it out again.
  9. Shouldn't you include_once the file outside that function? I'm not too sure, but I believe it wouldn't generate an error, but scope all of that class info to just within that function. Try using the include_once within the class, but outside a function. And wow, second person I've seen today using # for their comments.
  10. Ugh, the pain of various OO systems. Sorry, I originally learned OO with Java, and it took over my brain during my post. My natural assumption is that you'd use the variable's name (that is, with the $) as opposed to everything except the $.
  11. Does your class have a variable called $connection? $this->connection does not use the $connection variable. In fact, it's quite gibberish to PHP. $this->$connection is what you want.
  12. From my work location it puts me as New York, when I'm really in Maryland. To make things more interesting, my company's main building is in Virginia. It seems to me like 1 + 1 = 4 in my case. I'll check it from home later to see if that's right.
  13. 1. Both sspoke and MrAdam gave solutions similar to uploading the file and saving just the location in your database. 2. In order to store the actual data you'd fopen the uploaded file $_FILES['field_name']['tmp_name'], then fread the contents into a var, and insert it into the BLOB field.
  14. If it's running in the background, why are you echoing? Also, just setup a cron job to run the file, or run the process from the shell (i.e. php -f "logger.php"& would run it in the background).
  15. I honestly think that inserting files themselves into a database is a horrible practice. You should really upload them to a location, and save the location in the database. You would have to upload them into a BLOB if you really want to store them in a database. As for displaying an image, you'd probably have to make a php page to retrieve it, echo a Content-Type of that image, then echo the data.
  16. Don't forget the mysql_error() thing. It's very useful when you have problems with your MySQL statements, however don't forget to take it out before you go live with it.
  17. http://www.php.net/pdf would be a good place to start looking.
  18. 1. update1 should be $update1 2. If you're ever having a SQL query error, change your query from mysql_query(); to mysql_query() or die(mysql_error()); That will give you plenty of error information.
  19. There are services out there (like DreamHost), where each database gets its own "server" (not sure if they really run another one, but it works like it) to connect to.
  20. You place in the server name. If the server was db.mysite.com you'd use: $con = mysql_connect("db.mysite.com","marquis","******");
  21. No, it cannot. MD5 is a hash not an encryption. There are lookup tables that contain the MD5 hashes for millions of MD5 values. But, there is no way to definitively determine what value created any MD5 hash, because an MD5 hash can have many different values that were used to create it. It all depends on your definition of cracked. I could easily run an attack against the password hash. If I come up with a successful password, then I'd say it's cracked. However, some people may seem cracked as having reversed the encryption, which you can't do with a hash. I know of at least 1 tool for attacking md5 hashes that simply does dictionary and brute force attacks.
  22. You're missing the _ It should be $_COOKIE['FFXIGuild'].
  23. Person: "I need a banner for my website." GFX Guy: "Okay, what's the color scheme?" Person: "Color Scheme? I don't know. I haven't built the site yet. We need the banner to build it." GFX Guy: *stabbity death*
  24. Just google it. You have to output it within the <head> of your HTML output.
  25. Well, if you don't output anything you can use: header("Location: http://www.domain.com/index.php"); If you do output, use a meta-refresh.
×
×
  • 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.