in our production environment (running redhat enterprise linux 5.7):
php -v
PHP 5.2.17 (cli) (built: Jan 11 2011 11:12:46)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
in our proposed production environment (running redhat enterprise linux 6.1):
php -v
PHP 5.3.3 (cli) (built: Jan 21 2011 09:39:13)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
the issue is that in php-5.3 something was revised in date(); function and that produces some issue for apachesolr project, such as: date shows incorrectly
did anyone had similar issues? i'm kind of stumble here and dont know what to do at this point...
Comments
what is wrong with date?
what is wrong with date? where does it show incorrectly? what version of apachesolr?
here's one issue about date facets: http://drupal.org/node/558160
and here's some issue about strange behavior of apachesolr on jetty on debian 64bit after java update: http://drupal.org/node/1287860
Mihajlo
php 5.1x = date.timezone
There is a new (as of PHP 5.1) $_SERVER variable argument called "REQUEST_TIME". It holds the UNIX timestamp of the initiation of the call.
You can use both the (new) $_SERVER['REQUEST_TIME'] variable or the (older) time()function. Both of these return a Unix timestamp.
Most of the time these two solutions will yield the exact same Unix Timestamp. The difference between these is that $_SERVER['REQUEST_TIME'] returns the time stamp of the most recent server request and time() returns the current time. This may create minor differences in accuracy depending on your application, but for most cases both of these solutions should suffice.
--
Linux: Web Developer
Peter Bowey Computer Solutions
Australia: GMT+9:30
(¯`·..·[ Peter ]·..·´¯)
What's new in PHP
What's new in PHP 5.3.6:
What's new in PHP 5.3.2:
--
Linux: Web Developer
Peter Bowey Computer Solutions
Australia: GMT+9:30
(¯`·..·[ Peter ]·..·´¯)
A note on
A note on $_SERVER['REQUEST_TIME'] - while it's very handy in certain occasions to be able to take note of when the current web hit started, please don't assume that this variable will always be available. In particular, when Drush is used, there is no "server" in play and that variable won't be set. You should check for existence of the variable and fall back to time() if it's not there.
<?php
$time = (isset($_SERVER) && isset($_SERVER['REQUEST_TIME'])) ? $_SERVER['REQUEST_TIME'] : time();
?>
If the variable isn't set but your code doesn't check for that, it'll get picked up as NULL, which might get interpreted as zero, and who knows what chaos that might cause.
The Boise Drupal Guy!
<?phpdrush ev
<?php
drush ev "drush_print_r(\$_SERVER['REQUEST_TIME'])"
?>
Works for me?
What platform did you see where it doesn't work?
knaddison blog | Morris Animal Foundation
Huh. Works for me too. php -r
Huh. Works for me too.
php -r 'print($_SERVER["REQUEST_TIME"]);'
even.Well.
Ahem.
iwaswrong THERE, I SAID IT, OKAY?!
The Boise Drupal Guy!
I'm using apache-solr-1.4.1
I'm using apache-solr-1.4.1 w/ apachesolr 6.x-2.0-beta2. I also tried apache-solr-3.3.0 w/ same apachesolr.
i will include screenshot of what i'm talking tomorrow
alexus.org && alexus.biz
Ok, I'd like to update this
Ok, I'd like to update this discussion...
I've tried out apachesolr following versions: 6.x-1.5, 6.x-1.x-dev and 6-x-2.0-beta5 on apache-solr-3.4.0 (RHEL6.1).
All of them delivered same results: now I'm missing "Refine your search by" on the left side when I'm doing search inside of Drupal...
any ideas?
alexus.org && alexus.biz