This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Patch for Ubercart hidden checkout error | |
Uc_cart version: 6.x-2.15 | |
Drupal version: 6.38 | |
Ubercart hidden checkout error: | |
No error message appeared when the database connection error occurred. | |
The drupal user wasn't created and the customer received only one email (below) with the account settings but the username was empty. | |
The order remained in the state "in checkout". |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import unicodedata | |
def cData_(x): | |
s = unicodedata.normalize('NFKD', x).encode('ascii', 'ignore').lower().decode('ascii') | |
newS = ''.join(map(lambda x: x if x.isalnum() else '-', s)) | |
oldS = None | |
while oldS != newS: | |
oldS = newS | |
newS = newS.replace('--', '-') | |
if newS: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/www/includes/cache.inc b/www/includes/cache.inc | |
index 1e70960..d08f3f4 100644 | |
--- a/www/includes/cache.inc | |
+++ b/www/includes/cache.inc | |
@@ -17,9 +17,9 @@ function cache_get($cid, $table = 'cache') { | |
// Garbage collection necessary when enforcing a minimum cache lifetime | |
$cache_flush = variable_get('cache_flush_'. $table, 0); | |
- if ($cache_flush && ($cache_flush + variable_get('cache_lifetime', 0) <= time())) { | |
+ if ($cache_flush + variable_get('cache_lifetime', 0) <= time()) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/www/sites/all/modules/uc_gp/uc_gp.pages.inc b/www/sites/all/modules/uc_gp/uc_gp.pages.inc | |
index 62b18da..2a1137f 100644 | |
--- a/www/sites/all/modules/uc_gp/uc_gp.pages.inc | |
+++ b/www/sites/all/modules/uc_gp/uc_gp.pages.inc | |
@@ -41,6 +41,12 @@ function uc_gp_webpay_request($order) { | |
// Create full URL | |
$url = url($action, array('query' => $values)); | |
+ $values_s = ""; | |
+ foreach ($values as $key => $value) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Workaround for https://github.com/PowerShell/PSReadLine/pull/768 | |
# Downgrade PS-Readline | |
# Install-Module -Name PSReadLine -RequiredVersion 1.2 -SkipPublisherCheck | |
# Install less pager | |
# https://www.guysalias.tk/misc/less/ | |
# Unicode code page | |
chcp 65001 |
OlderNewer