Jump to content


Staff Alumni
  • Posts

  • Joined

  • Last visited

Everything posted by tomfmason

  1. It appears that the server or vps that mysql was running on ran out of diskspace. Eric solved it for now but few of the current staff have access to that server. I had access at one point but someone either removed my user account or removed my key. Is thorpe or daniel0 still active? If I am not mistaken daniel was the one that setup the irc server and he would probably be the best one to contact regarding that problem.
  2. I still have ownership of the ##phpfreaks channel on freenode. I haven't been on here or there in ages though. If you guys want I can unlock it.
  3. I've never been a fan of CI. Actually passed up on a job two years ago because they were going to force me to work with it.
  4. I would replace that while/each with a simple foreach e.g. foreach($_POST as $key=>$value) { //do some stuff }
  5. Without knowing your partition layout I would assume you can. I would recommend you get a live distro on a usbstick or dvd and use parted/gparted to remove the windows partition and resize the ubuntu partition. I keep a copy of the gparted live on a small 4 gig usb stick for situations like these.
  6. php code within will automatically be highlighted if you start with <?php. Otherwise you can use
  7. if that wont work then you will most likely need to replace the current guide.cgi with a simple redirection script using the redirect method e.g. #!/usr/bin/env perl use CGI; my $q = CGI->new(); print $q->redirect( -location => 'http://domain.tld/guide_final.php?paper=' . $q->url_param('paper'), -status => 301, ); It has been a very long time since I have written anything in perl but from what I remember that is how you would do it.
  8. this should be a fairly simple rewrite rule imo RewriteEngine On RewriteRule ^cgi-bin.guide-cgi?page=(.*)$ guide_final?page=$1 [R=301,L] The rule above should redirect all requests from guide_final?page=* to guide_final?page=* and with a 301 Moved Permanently header.
  9. This topic has been moved to mod_rewrite. http://www.phpfreaks.com/forums/index.php?topic=349328.0
  10. It looks like you most likely need require_once("QueryString.php"); as /QueryString.php is looking for that file in the root of the server.
  11. yes, you will need to setup a cron job in linux or a scheduled task in windows.
  12. This topic has been moved to MySQL Help. http://www.phpfreaks.com/forums/index.php?topic=349293.0
  13. should be as simple as using distinct in your query e.g SELECT DISTINCT `field` FROM `table`
  14. You should have a look at curl and more specifically curl_setopt. It looks like you will need to use the following options: CURLOPT_HEADER(to get the headers),CURLOPT_NOBODY(because you don't need the actual content), and CURLOPT_FOLLOWLOCATION(set to 0 because you don't need to follow the redirect). You can then inspect the response headers for the url you are being redirected to.
  15. You don't really need to test if $test is empty and afaik your else statement should have been throwing an error. The following should work <?php $hairbald = trim($_POST['HairBald']); $eyes = trim($_POST['Eyes']); $test = '<' . $eyes.'.'.$hairbald . '>'; ?>
  16. This topic has been moved to Miscellaneous. http://www.phpfreaks.com/forums/index.php?topic=348673.0
  17. without seeing the code it is really hard to tell you were the problem is. This is were solid unit testing would have been a major help imo
  18. right click and choose "Open with". You can then browse for your preferred text editor
  19. This topic has been moved to Miscellaneous. http://www.phpfreaks.com/forums/index.php?topic=348530.0
  20. Here is an example I found in the forums using mysql and here is another example using a simple php function(2nd and 3rd comments). Both methods require you to have the longitude and latitude associated with the zip codes. If you don't have them you can download them here
  21. You could also just use trim to remove the new line characters. Although I think nl2br is what he is actually looking for.
  22. Personally I don't really like either one because they are both pretty bloated. CodeIgniter is around 3mb when extracted and Zend is even larger than that. CI has fairly decent documentation but it has some real drawbacks that are not documented. Zend has odd documentation and, from my experience, the developer community has a lot of condescending elitists. This is the main reason I wrote my own small framework. In total it is around 300kb, has it's own "active record" of sorts, built in simple cms, authentication and granular permissions systems. I haven't benchmarked it yet but I would bet that it out performs both CI and Zend by a large margin.
  23. After reading the docs I see that I forgot to add "ENCLOSED BY". This should solve the quote problem LOAD DATA LOCAL INFILE '/path/to/your.csv' INTO TABLE `table` OPTIONALLY ENCLOSED BY '"' FIELDS TERMINATED BY ',' LINES TERMINATED BY '\n' (`field1`,`field2`,`field3`);
  • 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.