Jump to content

requinix

Administrators
  • Posts

    15,229
  • Joined

  • Last visited

  • Days Won

    427

Everything posted by requinix

  1. Compile your own version of PHP. Have you considered trying to, oh I don't know, fix the problem? Assuming there is one in the first place?
  2. Your backslashes aren't paired up properly. $pattern = '/^(C:\\\\)[A-Za-z0-9\040\.\-\\/]$/';
  3. Then try having two of those date comparisons, one in each place. The innermost query will then find duplicate names within your time period while the outermost query will find matching records with those names... within your time period.
  4. Besides the $POST['cancel'] typo, the buttons have to be in a form. $id = 776; print '$id ' . "$id\n"; if(isset($POST['cancel'])){ print "Exiting"; exit(); } if(isset($_POST['submitted'])){ print '$id ' . "$id"; } print " </pre> <form method='\"post\"'> </form> <br>";<br [edit] Oookay, indentation doesn't want to work for me.
  5. If neither of those do what you want (I thought you might have a syntax error) then what do you want? The couple options I can think of should be answered by one of those queries.
  6. What query did you try?
  7. It's probably malicious, trying to send all of your visitors to that other site instead. You wouldn't notice because you're not getting to your site via Google.
  8. Outside of a character set ^ means the beginning of the string (or in multiline mode the beginning of the line). As the first character inside a character set ^ means "none of the following characters". As anything after the first character inside a character set ^ means literally a ^. That's all. If you don't want something to match then use a negative assertion, but you then have to specify something that can match. \[\[start:(?!$keep\])[^\]]+\]\]... The added \] after $keep is so that $keep=123 will not prevent [[start:1234]] from matching.
  9. Had you looked at the manual before blindly trying random things you would have seen a note about piped logs. Related, here is the manual page for rotatelogs which demonstrates how you can have a daily log file; I think it will append to existing files so you could write the filename to be per-month and use a per-hour interval (to handle DST changes).
  10. I'll take that as a "no" then. define( "DOWNLOAD_ROOT", __DIR__ . "/" ); __DIR__ is for PHP 5.3+ only. For define( "DOWNLOAD_ROOT", dirname(__FILE__) . "/" ); You should install PHP 5.2 on your machine at home so there aren't any more of these problems.
  11. Your website is not running PHP 5.3. Can you upgrade it?
  12. date_default_timezone_set
  13. $weekPay = (($hourly * 40) + (1.5 * hourly) * otHours); Find your php.ini, set display_errors = on error_reporting = -1 then restart your web server and find out what error messages PHP has for that line.
  14. You can't header redirect and trigger a download at the same time. You could redirect to the page which then redirects to the download (and thus won't take the user away from that page). Other options depend on the purpose of the pages and the download.
  15. How does that work?
  16. As long as you're not talking about the client's computer and scanner, a command-line program is probably your best bet.
  17. Not working how? Error messages? The site is still showing the __DIR__ version.
  18. You don't. include_once(dirname(__FILE__) . "/../admin/config.php");
  19. Well that's certainly not normal. Okay, DOCUMENT_ROOT won't work. Next best thing is a relative path. Assuming you have PHP 5.3 or later, include_once(__DIR__ . "/admin/config.php"); Looks the same, huh? The DOCUMENT_ROOT version works by starting at the root of your website and going to the admin/config.php file from there. Using __DIR__ is relative to the file you put the code in, which could be the root or could be someplace else. Say you have a file include/config.php and want to include the admin/config.php stuff. The two methods together then look like // start at the website root, go to admin/config.php include_once($_SERVER["DOCUMENT_ROOT"] . "/admin/config.php"); // start in this directory, go up a directory, then go to admin/config.php include_once(__DIR__ . "/../admin/config.php");
  20. That leading slash means to look in the root of the drive. It's akin to saying C:\admin\root.php. Naturally that's not where your file lives. It actually lives in /home/username/public_html/admin/root.php. So that's what you need to say. Easiest method is include_once($_SERVER["DOCUMENT_ROOT"] . "/admin/root.php");
  21. A correction to what you've said in a couple places: You are not using the "W3C geolocation API". It is not provided by the W3C. You aren't getting data from them. They made a standard for how one can write Javascript to try to get geolocation information, but that information is actually coming from the browser. The browser will do whatever it wants to try to get a location: maybe the user set it beforehand, maybe it does an IP address-based lookup, maybe it ties into GPS information available on the device, or maybe it says no and returns nothing.
  22. Nothing you posted tries to call a check_input() function. You're not showing us the right code. [edit] Please use or [code=php:0] tags around your code. Makes things much easier to read.
  23. So to be sure, you're still getting the "URL file-access is disabled" message? With a bit of digging it seems that message only happens when you try to include() a php:// URL. What version of PHP are you using? What's the code?
  24. You sure about that? What does phpinfo() or ini_get() say?
×
×
  • 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.