Jump to content

corbin

Staff Alumni
  • Posts

    8,102
  • Joined

  • Last visited

Everything posted by corbin

  1. Hi... To have a program run as a Windows service, it has to have handling for certain interrupts and signals (has to implement a certain set of code). Basically it's impossible with a PHP script without heavily modifying the PHP core.
  2. Sorry, but no. Not much you can do.
  3. http://en.wikipedia.org/wiki/Regression_analysis How to actually implement the math in PHP though, I have no idea. (I can do it on a graphing calculator, but that's about it.) I would imagine the easiest approach would be to find the equation or algorithm for each type of regression (linear, x^n, exponential, so on), then try all of them and check accuracy.
  4. Is it the VC6 thread safe version? Aside from that, assuming those are valid locations, I don't see why Apache wouldn't start. What errors do you get? Also, if you're using the old mssql_* extension, I'm not sure how easy it's going to be to get that working with a recent version of PHP. Well, it shouldn't be too bad actually, if you're using MSSQL 2000. If I remember correctly, it requires ntwdblib.dll, and MSSQL 2000 was the last version to actively use (and contain) that. You can of course download it from random places.
  5. As Mchl said, UPDATE INTO (or the longer INSERT INTO ON DUPLICATE....) is MySQL specific, and as far as I know, nothing like it exists in MSSQL. You can either use two queries, or you can use a stored procedure.
  6. Hmmm, I hope you don't take this the wrong way, but it seems kind of like you need to just forget everything you know about OOP, get a good book, and read a large part of it. Actually, how long have you been coding? Because if you've been coding like 3 days, it might be easier to avoid OOP for a while and get a good grasp on procedural programming. Just an opinion that procedural is easier though, since I would imagine some people find OOP easier.
  7. Have you checked the existence of the file and the ability of Apache (in terms of permissions) to read it?
  8. Have you made sure the base_opendir directive isn't set? Also, have you checked the file permissions?
  9. You could always use something behind the scenes (perhaps ffmpeg, but I'm not sure about the legal restrictions on it) to convert everything to a certain format. That way, you could use essentially any player.
  10. Most people have JavaScript enabled, so I doubt it would be an issue. However, typically one should avoid using JS unless it actually adds a significant amount of user friendliness to a page. Instead of checking if JS is disabled or not, what you would want to do is code your website to work with or without JS, but sometimes that's not an option. I could talk more on this, but I'm feeling quite lazy, so if you don't know what I mean, I'll try to explain more.
  11. Odd that it was in there, but whatever works ;p.
  12. date() and strtotime() would probably do the trick . Edit: Oh, I should probably note that strtotime can handle stuff like: strtotime('July 1, 2010 +1 week'); Also, mktime() might be useful.
  13. Uhhh.... that's cracked out. I would check your hosts file (C:\Windows\system32\drivers\etc\hosts) to make sure there's not an entry in there for it. Otherwise, your DNS resolution is messed up somewhere, be it at a computer level, router level, or ISP level, I have no idea.
  14. Have you tried anything? I would suggest... removing the html and adding a /. RewriteRule ^[^/]+-([0-9]+)/$ product-information.php?id=$1 [QSA,L]
  15. Is it a crappy server? 10 page loads should not flood a server by any means. There's either a race condition, or something isn't right. The easiest way to go about it if you already have it setup would be to use something like xdebug to see where the hang is (or the slow down). But, you could also just try to figure out what's taking so long. Also, how many requests is Apache setup to handle at a time?
  16. I was fiddling around with nginx the other night, so this thread caught my attention. Anyway, I just duplicated your setup, and I was confused for quite a while. File permissions.... You need to make sure whatever user you're running php-cgi under has read access to c:\wemp.
  17. corbin

    REPLACE NULL

    That appears to be SQL Server style syntax. Try: UPDATE products SET RegionID = 0 WHERE RegionID IS NULL; The quote identifier (because I can't remember what it's really called) is ` in MySQL. It's [] in MSSQL. Also, what error are you getting?
  18. I think you're looking for a JOIN and the SUM() function. Also probably DATE_SUB.
  19. Look into function scope. A variable defined inside of a function does not exist outside of the function. As such, the variables defined in files included in a function, do not exist outside of a function.
  20. I'm sure this has already occurred to you to check, but... Case sensitivity? Aside from that... Hrmmm... File permissions shouldn't be it. Is the path name too long? (I don't know what the path limit is under linux, but it's 256 chars on Windows.) I can't really think of anything else it could be.
  21. 1. It's probably as easy as using yum or apt-get to install the necessary software. (yum install php php-cli mysql mysql-client php-mysql httpd for example) 2. You've configured virtual hosts before, right? If not, it's still not hard to figure out. You could definitely have it done by Wednesday. Although, if you're never configured Apache before, or never run anything under linux, then I would say no lol.
  22. Your ISP might block port 80. Try temporarily completely stopping iptables (service iptables stop or whatever), and then you can see if it's iptables or not.
  23. I'm guessing IE 6 is the problem? I don't know if IE 6 will even run on Win 7 x.x.
  24. 2 would be easiest in my opinion. As for someone doing your homework for you, that's not going to happen. Specific questions people will answer. Blanket "HALP" calls will be ignored.
  25. 2000 HTTP requests per second? Yeah... Errr.... You won't reach that overnight. Or even in a year (unless your site catches on like youtube did or facebook). 172.8 mil hits per day is quite a beastly load. Basically I would say roopurt offered the best advice. Scale as needed: don't waste money. (From what you said though, I gather that you got a dedi server.) As for performance monitoring tools, there are quite a few free ones if you're under linux. http://www.cyberciti.biz/tips/top-linux-monitoring-tools.html goes over a few of the basic ones. As for more indepth ones, I've no idea.
×
×
  • 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.