Jump to content

Azu

Members
  • Posts

    1,047
  • Joined

  • Last visited

    Never

Everything posted by Azu

  1. Sometimes in PHP I need to run a query, but the query will take a long time, and my PHP doesn't need any feedback from the query. How do I make it so that my PHP just tells MySQL to execute the query and then just goes on executing the rest of the script instead of waiting for the query to complete before moving on?
  2. How can I increase the priority of MySQL in Windows? When I try to in the task manager, it errors..
  3. Thank you it is working perfectly now! I was starting to worry that it might not be possible without javascript lol
  4. Thanks for the reply. I'm going to try the code that you posted. And just to clarify; basically the image is a map and I want to put Xs over it to mark certain spots on it I have it working with absolute positioning except that I need to have it working with relative positioning, so that I can put it at the end of countless pages all varying in length, where absolute positioning won't work. So ya I'm gonna go try that now and see if it works thanks ^^ brb Edit: Didn't work the Xs show up as block level elements x_X and way down below the picture.. Tried changing them to inline but that didn't fix it either. They are still way down near the bottom of the screen and not working at all... =(
  5. Okay. Just have it output text then like I said before. PHP rules!
  6. You mean like this? <table border='0' background='http://website.com/image.jpg' width='784' height='525' cellpadding='0' cellspacing='0'><tr><td> <span style='left:220px;top:492px'>X</span> <span style='left:189px;top:284px'>X</span> </td></tr></table> Didn't work the table shows up but it doesn't have the image in it (the image is downloaded but not displayed) and the Xs just show all show up right smack in the middle of it. Can't position them. Thanks anyways..
  7. I'm sorry but don't browsers ALSO "format" text as "black pixels on a white background"? How else would it be done? (besides using different colors, obviously) o_O In fact, I think that kind of describes ALL visual output from computers..
  8. There doesn't seem to be much on the site except links to vbulletin, and advertisement banners. What exactly do you want critiqued?
  9. It seems to be explained pretty clearly in the explanation that you quoted. Is there some reason that you are refusing to use classes?
  10. This isn't a problem with Firefox. It is a problem with you putting PHP code in your HTML. PHP should be on the server side only, never sent to the client.
  11. That DTD looks like 1.0 transitional to me not 1.1 And 1.0 transitional ignores almost all errors.
  12. Hello Can somebody please tell me how I need to change my position stuff so that it won't be absolute? So that I can put it at the end of my page without it overlapping stuff above it, since there isn't always the same amount of text on the page. Here is and example of my code <img style='position:absolute;top:155px;left:0' src='http://website.com/image.jpg'/> <ins style='position:absolute;left:220px;top:492px;z-index:2'>X</ins> <ins style='position:absolute;left:189px;top:284px;z-index:2'>X</ins> It puts Xs over the image. How do I change it so that it will work right with position set to relative instead of absolute? I don't care how it's done as long as it works and obviously doesn't require some kind of javascript or something.
  13. Okay. Well I'm sure you can generate italic text with the GD library. Not sure exactly how, as I've never used it before, but I'm sure it can be done. PHP should be able to detect what OS it's running on, and then open the picture of the text it made in an image viewer.
  14. Azu

    Subdomains

    Thanks guys. Isn't there some way to do it in PHP though? So that it will work on all webservers that run PHP? I would really really appreciate that ^^
  15. Azu

    Subdomains

    Sorry I meant how can I do this in PHP itself? Not something specific to certain web servers.
  16. Checking the headers the client sends and the extension the client sends is useless; anyone can send false ones, unless they are complete retarded and can't even type a question into Google. You need you find a way to actually validate the data itself and make sure it's what you are looking for. For example usually a PNG file will begin with "‰PNG" at the start. Just open stuff up in a text editor and find things that are always the same for that type of file, E.G. signatures. Then just have PHP check for these signatures and make sure they are in the right places. Be careful though, and make sure that they can never overlap another file type.
  17. Azu

    Subdomains

    Hi, I've been using modrewrites to basically have sections like website.com/Forum website.com/Forum but I don't really like this. How can I change it to use like forum.website.com help.website.com instead?
  18. [noparse]<?='<i>Hello!</i>'?>[/noparse] Edit: BAH! Damn SMF doesn't recognize noparse tags. -.-
  19. What can HTML do that a programming language can't do?
  20. It's pretty simple. Let's say you have a class Manager that can return an instance of your DB object: <?php $db = Manager->getDB(); $db->query($sql); ?> Since you know that the getDB method of Manager will return a DB object, you don't really need the $db variable. <?php Manager->getDB()->query($sql); // Due to operator associativity, the above is executed as if it were: // (Manager->getDB())->query($sql) // The (Manager->getDB()) is representative of the $db var in the // first example ?> You see this syntax more often in Javascript, Java, and C++. For example, if you wanted the body element in Javascript: document.getElementsByTagName("body")[0]->appendChild(someNode); I'm not sure about the implications in Java or Javascript, but if you were going to reuse the returned object multiple times I'd just store it in a variable. Using the first example again: <?php $db = Manager->getDB(); $db->query($sql); echo $db->successMsg(); ?> I consider that a little more efficient (as far as PHP is concerned) than: <?php Manager->getDB()->query($sql); echo Manager->getDB()->successMsg(); ?> The reason is that in the second example here we have to call Manager->getDB twice to get the same value; this is slightly inefficient, but will still run really fast. However, in a language like C++ you don't have this problem. You can return a const reference to the object (yes I'm aware you can return references in PHP) and you can also declare the function as inline. Hope that helps to clarify! Thanks but I don't understand sorry. How exactly is this different from nesting functions in procedural? Like echo(mysql_result(mysql_query("select text from table"),0));
  21. I don't get it.. isn't Skype a voice messenger? How would a PHP script communicate through it? Does it have some kind of voice synthesizer?
  22. I could have sworn that I used $a=echo'Some text'; before and it worked..
  23. I think it's kind of pointless to make 1 page domains with nothing on them except ads. You obviously won't get any traffic (or almost none) thus making the effort a waste of time.
×
×
  • 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.