Zen Cart Logo
If this is your first visit, check our documentation. To post, register or login.
Forums / Code Matters / Code Collaboration / Pre-release feedback for v1.5.2

Pre-release feedback for v1.5.2

Locked

Started by drbyte on 26 Nov 2013, 11:24 PM · Views: 19,116

Results 21 to 39 of 39
This thread is locked. New replies are disabled.
8 Dec 2013, 12:25 PM
#21
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,154
Plugin Contributions:
56

Post #21 by lat9

lat9:

FWIW, I was able to work around this restriction by changing /zc_install/includes/application_top.php (line 52) to comment out the lines associated with the restriction:

/**

  • Timezone problem detection
    /
    //if (PHP_VERSION >= '5.3' && ini_get('date.timezone') == '')
    //{
    // die('ERROR: date.timezone not set in php.ini. Please contact your hosting company to set the timezone in the server PHP configuration before continuing.');
    /
    } else*/ if (PHP_VERSION >= '5.1') {
    $baseTZ = date_default_timezone_get();
    date_default_timezone_set($baseTZ);
    unset($baseTZ);
    }
It turns out that, while 1and1 doesn't set a default timezone in the php.ini, they do set a default via date_default_timezone_set().  That said, modifying the fragment in the installation application_top.php to the following allows the install to (properly) proceed on a 1and1 server while preserving the integrity of the PHP environment (i.e. the date/timezone is set as required for PHP v5.4 and later):

/**

  • Timezone problem detection
    */
    if (PHP_VERSION >= '5.3' && /ini_get('date.timezone')/ date_default_timezone_get() == 'UTC')
    {
    die('ERROR: date.timezone not set in php.ini. Please contact your hosting company to set the timezone in the server PHP configuration before continuing.');
    } else if (PHP_VERSION >= '5.1') {
    $baseTZ = date_default_timezone_get();
    date_default_timezone_set($baseTZ);
    unset($baseTZ);
    }
11 Dec 2013, 10:25 PM
#22
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Post #22 by drbyte

dw08gm:

Have the following mods been fully incorporated in 152

search_configuration_keys
Fix_Cache_key utility
Keepalive Timer
time zone offset
The keepalive-timer "stub" is incorporated (ie: the core-file that is altered to make it work is now included), but the rest of that plugin is not.

The timezone offset plugin is now obsolete since the functionality for it has been incorporated.

And yes, as the whats_new file says, the Fix_Cache_Key utility and search-configuration-keys plugins are incorporated. Will add a note to the file to say those plugins are now obsolete.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

11 Dec 2013, 10:31 PM
#23
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Post #23 by drbyte

lat9:

In /includes/templates/template_default/templates/tpl_account_default.php, shouldn't the constant used in this fragment:

<?php if ((int)ACCOUNT_NEWSLETTER_STATUS > 0 or CUSTOMERS_PRODUCTS_NOTIFICATION_STATUS !='0') { ?> <h2><?php echo EMAIL_NOTIFICATIONS_TITLE; ?></h2> <ul id="myAccountNotify" class="list"> <?php if ((int)ACCOUNT_NEWSLETTER_STATUS > 0) { ?> <li><?php echo ' <a href="' . zen_href_link(FILENAME_ACCOUNT_NEWSLETTERS, '', 'SSL') . '">' . EMAIL_NOTIFICATIONS_NEWSLETTERS . '</a>'; ?></li> <?php } //endif newsletter unsubscribe ?> ``` > be SHOW_NEWSLETTER_UNSUBSCRIBE_LINK instead of ACCOUNT_NEWSLETTER_STATUS? The latter is the default setting for a customer's choice of newsletter sign-up (or not). Are you saying this is incorrect? <https://github.com/zencart/zencart/commit/82bb106af9c46ef514201e7a687ca238fd96fef3#diff-3236f2436ddecc3d4360342af8ca313f> ... it was done as a result of your post here: <http://www.zen-cart.com/showthread.php?198656-Incorrect-database-constant-used-in-tpl_account_default-php>

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

11 Dec 2013, 10:32 PM
#24
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Post #24 by drbyte

lat9:

Was there a (good) reason why the selectable-countries change introduced in v1.5.2 chose to call the enable/disable field *status *instead of countries_active as it is in the Selectable Countries plugin? The only reason I ask is that it's going to make the upgrade to v1.5.2 more difficult for current users of the plugin since they'll need to re-disable those countries that they don't want.
I see you've already written a script to migrate their existing settings: http://www.zen-cart.com/showthread.php?197534-Selectable-Countries-Support-Thread&p=1228583#post1228583

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

12 Dec 2013, 12:09 PM
#25
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,154
Plugin Contributions:
56

Post #25 by lat9

Sorry, "senior" moment ...

12 Dec 2013, 12:13 PM
#26
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,154
Plugin Contributions:
56

Post #26 by lat9

DrByte:

I see you've already written a script to migrate their existing settings: http://www.zen-cart.com/showthread.php?197534-Selectable-Countries-Support-Thread&p=1228583#post1228583
Having received no response for a week, I figured that it was going to be necessary and posted that script as a proposed work-around. If the field name in v1.5.2 is going to "take on" the countries_active name, then I can modify Selectable Countries' upgrade instructions to simply include the list of files to delete.

12 Dec 2013, 6:24 PM
#27
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Post #27 by drbyte

lat9:

Having received no response for a week, I figured that it was going to be necessary and posted that script as a proposed work-around. If the field name in v1.5.2 is going to "take on" the countries_active name, then I can modify Selectable Countries' upgrade instructions to simply include the list of files to delete.
"status" was deemed to be more semantically correct, hence the choice to use it instead of "countries_active"

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

17 Dec 2013, 8:59 PM
#28
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,154
Plugin Contributions:
56

Post #28 by lat9

lat9:

It turns out that, while 1and1 doesn't set a default timezone in the php.ini, they do set a default via date_default_timezone_set(). That said, modifying the fragment in the installation application_top.php to the following allows the install to (properly) proceed on a 1and1 server while preserving the integrity of the PHP environment (i.e. the date/timezone is set as required for PHP v5.4 and later):

/**

  • Timezone problem detection
    */
    if (PHP_VERSION >= '5.3' && /ini_get('date.timezone')/ date_default_timezone_get() == 'UTC')
    {
    die('ERROR: date.timezone not set in php.ini. Please contact your hosting company to set the timezone in the server PHP configuration before continuing.');
    } else if (PHP_VERSION >= '5.1') {
    $baseTZ = date_default_timezone_get();
    date_default_timezone_set($baseTZ);
    unset($baseTZ);
    }
Is there a reason why my proposed "fix" didn't make it into RC2?  I know that 1and1 can be problematic, but I'm not sure how many people have installed the v1.5.2 candidate on other Linux servers and how many of those servers would have implemented the same (workable) timezone solution as 1and1.  Note that using date_default_timezone_get encompasses the date.timezone setting in the php.ini file.
17 Dec 2013, 9:10 PM
#29
lhungil avatar

lhungil

Totally Zenned

Join Date:
Feb 2012
Location:
mostly harmless
Posts:
1,816
Plugin Contributions:
4

Post #29 by lhungil

Minor:

Documentation: "/includes/dist_configure.php". Distribution Zip: "/includes/dist-configure.php"
Documentation: "/admin/includes/dist_configure.php". Distribution Zip: "/admin/includes/dist-configure.php"

The glass is not half full. The glass is not half empty. The glass is simply too big!
Where are the Zen Cart Debug Logs? Where are the HTTP 500 / Server Error Logs?
Zen Cart related projects maintained by lhûngîl : Plugin / Module Tracker

17 Dec 2013, 9:23 PM
#30
swguy avatar

swguy

Administrator

Join Date:
Feb 2006
Location:
Tampa Bay, Florida
Posts:
10,769
Plugin Contributions:
56

Post #30 by swguy

The admin page loading issue I experienced in RC1 has been fixed in RC2. Thanks team!

That Software Guy. My Store: Zen Cart Support
Available for hire - See my ad in Services
Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
Do you benefit from Zen Cart? Then please support the project.

18 Dec 2013, 5:07 AM
#31
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Post #31 by drbyte

lat9:

Is there a reason why my proposed "fix" didn't make it into RC2? I know that 1and1 can be problematic, but I'm not sure how many people have installed the v1.5.2 candidate on other Linux servers and how many of those servers would have implemented the same (workable) timezone solution as 1and1. Note that using date_default_timezone_get encompasses the date.timezone setting in the php.ini file.

I wasn't satisfied that I'd been able to do enough testing to fully agree with your fix, so it's still on the table.

While it may work for 1and1, it needs testing on servers that have zero datetime stuff set, as well as master (serverwide php.ini) and also local (per-account php.ini and .htaccess and even vhost) settings, in addition to testing all those on each of PHP 5.2, 5.3., 5.4, 5.5. And on non-1and1 servers.

I welcome feedback found on as many of those combinations as anyone can offer.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

18 Dec 2013, 12:25 PM
#32
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,154
Plugin Contributions:
56

Post #32 by lat9

DrByte:

I wasn't satisfied that I'd been able to do enough testing to fully agree with your fix, so it's still on the table.

While it may work for 1and1, it needs testing on servers that have zero datetime stuff set, as well as master (serverwide php.ini) and also local (per-account php.ini and .htaccess and even vhost) settings, in addition to testing all those on each of PHP 5.2, 5.3., 5.4, 5.5. And on non-1and1 servers.

I welcome feedback found on as many of those combinations as anyone can offer.
From the php.net definition for date_default_timezone_get:

 In order of preference, this function returns the default timezone by:

    Reading the timezone set using the date_default_timezone_set() function (if any)

    Prior to PHP 5.4.0 only: Reading the TZ environment variable (if non empty)

    Reading the value of the date.timezone ini option (if set)

    Prior to PHP 5.4.0 only: Querying the host operating system (if supported and allowed by the OS). This uses an algorithm that has to guess the timezone. This is by no means going to work correctly for every situation. A warning is shown when this stage is reached. Do not rely on it to be guessed correctly, and set date.timezone to the correct timezone instead.

If none of the above succeed, date_default_timezone_get() will return a default timezone of UTC. 
18 Dec 2013, 4:11 PM
#33
lhungil avatar

lhungil

Totally Zenned

Join Date:
Feb 2012
Location:
mostly harmless
Posts:
1,816
Plugin Contributions:
4

Post #33 by lhungil

Prior to PHP 5.4.0 only: Querying the host operating system (if supported and allowed by the OS). This uses an algorithm that has to guess the timezone. This is by no means going to work correctly for every situation. A warning is shown when this stage is reached. Do not rely on it to be guessed correctly, and set date.timezone to the correct timezone instead.

If none of the above succeed, date_default_timezone_get() will return a default timezone of UTC.

For the first one, I suppose one could attempt to wrap yet another custom error handler around the query to detect when it issues a warning... And then throw the warning back at the user as an error...

But checking against the default of UTC could be problematic as some servers might actually reside in the corresponding timezone... So may require additional checks to see if the timezone is set by another method...

The glass is not half full. The glass is not half empty. The glass is simply too big!
Where are the Zen Cart Debug Logs? Where are the HTTP 500 / Server Error Logs?
Zen Cart related projects maintained by lhûngîl : Plugin / Module Tracker

18 Dec 2013, 5:33 PM
#34
IDEASLady avatar

IDEASLady

Totally Zenned

Join Date:
Aug 2005
Location:
Trujillo Alto, Puerto Rico
Posts:
1,456
Plugin Contributions:
4

Post #34 by IDEASLady

So zen cart 1.5.2 is just for testing for now correct. I would go wrong it I use it on a live store correct. The reason I'm asking is I'm doing a upgrade on a clients site and he wants the latest version witch is this.
I also want to know if there's any risk for live stores besides not being approved? And if there's any idea of time for approval, would this take a month? two, three? or maybe a week?

I just want to know if is worth it to wait for it or not, some customers need the stores right away.

IDEASLady
IDEAS Creative Studio

Your image... our business!

29 Dec 2013, 9:43 PM
#35
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,950
Plugin Contributions:
3

Post #35 by wilt

The main reason why v152 is still considered a release candidate is that it is currently being audited for PA-DSS approval.

Unfortunately as this audit is not controlled by us, we can't give a timeline for when it will be complete, although our best guess is quarter 1 2014.

It should also be noted that due to changes in PA-DSS requirements, regarding the cryptographic storage of passwords, that there will be an RC3. We are currently testing (in the v160 branch) changes to how passwords are cryptographically encrypted. Hoping to have this out (for 152) in the next couple of weeks.

ideasgirl:

I also want to know if there's any risk for live stores besides not being approved? And if there's any idea of time for approval, would this take a month? two, three? or maybe a week?

I just want to know if is worth it to wait for it or not, some customers need the stores right away.

2 Jan 2014, 7:03 PM
#36
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Post #36 by divavocals

countrycharm:

So zen cart 1.5.2 is just for testing for now correct. I would go wrong it I use it on a live store correct. The reason I'm asking is I'm doing a upgrade on a clients site and he wants the latest version witch is this.

Until it is a RELEASED version it is considered a BETA version.. Not a good practice to use BETA software for a LIVE store.. So postpone your update or go forward with 1.5.1 and do the 1.5.2 upgrade at a later date.. I would suggest the latter since you need to make sure your modules are v1.5.2 ready.. (most all will require some sort of update COWOA for sure will for example)

My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

15 Apr 2014, 6:29 PM
#37
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Post #37 by drbyte

lat9:

lat9:

It turns out that, while 1and1 doesn't set a default timezone in the php.ini, they do set a default via date_default_timezone_set(). That said, modifying the fragment in the installation application_top.php to the following allows the install to (properly) proceed on a 1and1 server while preserving the integrity of the PHP environment (i.e. the date/timezone is set as required for PHP v5.4 and later):

/**

  • Timezone problem detection
    */
    if (PHP_VERSION >= '5.3' && /ini_get('date.timezone')/ date_default_timezone_get() == 'UTC')
    {
    die('ERROR: date.timezone not set in php.ini. Please contact your hosting company to set the timezone in the server PHP configuration before continuing.');
    } else if (PHP_VERSION >= '5.1') {
    $baseTZ = date_default_timezone_get();
    date_default_timezone_set($baseTZ);
    unset($baseTZ);
    }
> Is there a reason why my proposed "fix" didn't make it into RC2? I know that 1and1 can be problematic, but I'm not sure how many people have installed the v1.5.2 candidate on other Linux servers and how many of those servers would have implemented the same (workable) timezone solution as 1and1. Note that using date_default_timezone_get encompasses the date.timezone setting in the php.ini file.
Would you mind testing this version of that segment of code, specifically on the kinds of servers you said were giving you trouble previously:```
/**
 * Timezone problem detection
 */
if (PHP_VERSION >= '5.3' && ini_get('date.timezone') == '' && @date_default_timezone_get() == '')
{
  include ('../includes/extra_configures/set_time_zone.php');
} elseif (PHP_VERSION >= '5.1') {
  $baseTZ = date_default_timezone_get();
  date_default_timezone_set($baseTZ);
  unset($baseTZ);
}
// re-test
if (ini_get('date.timezone') == '' && @date_default_timezone_get() == '')
{
  die('ERROR: date.timezone is not set in php.ini. You have two options: 1-Edit /includes/extra_configures/set_time_zone.php to set the $TZ variable manually, or 2-Contact your hosting company to set the timezone correctly in the server PHP configuration before continuing.');
} else
{
  @date_default_timezone_set(date_default_timezone_get());
}

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

15 Apr 2014, 7:06 PM
#38
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,154
Plugin Contributions:
56

Post #38 by lat9

DrByte:

Would you mind testing this version of that segment of code, specifically on the kinds of servers you said were giving you trouble previously:
Works like a charm, DrByte!

20 May 2014, 6:53 AM
#39
daffy avatar

daffy

Zen Follower

Join Date:
Jul 2008
Posts:
114
Plugin Contributions:
0

Post #39 by daffy

I'm running ZC 1.5.2 with PHP 5.3.27 and I'm running it live (which is not a problem since it's not getting much if any traffic.) It's working fine.

If you want help testing something? Let me know.