If this is your first visit, check our documentation. To post, register or login.
Forums / Code Matters / Bug Reports / Code in default_filter.php

Code in default_filter.php

Started by yesaul on 19 Apr 2024, 10:52 AM · Views: 1,092

Results 1 to 4 of 4
19 Apr 2024, 10:52 AM
#1
yesaul avatar

yesaul

New Zenner

Join Date:
Apr 2011
Location:
Espoo, Finland
Posts:
73
Plugin Contributions:
0

Code in default_filter.php

Sorry, if I do understand something wrong, but this code does not seem correct, IMHO:

// Legacy $_GET['sort'] which was used for sort-by-clicking-column-heading
[B]if[/B] (isset($column_list) && [B]!empty[/B]($_GET['sort'])) {
    [B]if[/B] ([B]!isset[/B]($_GET['sort']) && PRODUCT_LISTING_DEFAULT_SORT_ORDER !== '') {
        $_GET['sort'] = PRODUCT_LISTING_DEFAULT_SORT_ORDER;
    }
...
}

(Lines 93>> in new default_filter.php for v2.0.0)

19 Apr 2024, 12:47 PM
#2
yesaul avatar

yesaul

New Zenner

Join Date:
Apr 2011
Location:
Espoo, Finland
Posts:
73
Plugin Contributions:
0

Re: Code in default_filter.php

// Legacy $_GET['sort'] which was used for sort-by-clicking-column-heading
if (!isset($_GET['sort']) && PRODUCT_LISTING_DEFAULT_SORT_ORDER !== '') {
    $_GET['sort'] = PRODUCT_LISTING_DEFAULT_SORT_ORDER;
}
if (isset($column_list) && !empty($_GET['sort'])) {
...
}

:dontgetit

19 Apr 2024, 1:17 PM
#3
lat9 avatar

lat9

Administrator

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

Re: Code in default_filter.php

@yesaul, what issue are you experiencing? With which template?

19 Apr 2024, 2:04 PM
#4
yesaul avatar

yesaul

New Zenner

Join Date:
Apr 2011
Location:
Espoo, Finland
Posts:
73
Plugin Contributions:
0

Re: Code in default_filter.php

lat9:

@yesaul, what issue are you experiencing? With which template?
I use my own template, where "sort-by-clicking-column-heading" is (still) in use

But this does actually no matter, as code quoted in my first message seems meaningless anyway

I suggest I am not only one why needs this legacy code, and as it was added to new version, it should be correct, shouldn't it ? (or removed...)

My site