Commit Graph

56 Commits

Author SHA1 Message Date
Claudio Sanches c4afd53749 Make wc_get_endpoint_url() compatible with WordPress use_trailing_slashes settings 2019-07-31 20:57:55 -03:00
Khan M Rashedun-Naby f7baef9938 wc_list_pages function refactored 2018-05-15 08:08:18 +06:00
Mike Jolley 3140a0fb62 More customistion options for terms and conditions. 2018-04-06 11:43:30 +01:00
Claudio Sanches 95edc882ea Fixed bug when using asbint() with wc_get_page_id()
When a page does not exists `wc_get_page_id()` returns `-1`, so applying
`absint()` should cause bugs when comparing with "Hello world!" page.
2018-04-04 12:12:05 -03:00
Claudio Sanches 84f3947eb8 Fixed includes/wc-page-functions.php PHPCS violations 2018-03-08 16:15:31 -03:00
Mike Jolley 17c28fc8f9 Prevent double slash 2018-02-19 13:14:07 +00:00
Mike Jolley 129134a30f Use verbose page rules when shop is in the URL, including shop base with category 2018-02-09 15:25:33 +00:00
Claudio Sanches 9681a331e9 Fixed coding standards 2017-11-20 20:19:09 -02:00
Claudio Sanches 5a858eb2b1 Use WC_Query->get_query_vars() instead of WC_Query->query_vars
Closes #17733
2017-11-20 14:40:56 -02:00
Mike Jolley c05e6d02f7 Check valid data when filtering wp_nav_menu_objects
Closes #17565
2017-11-06 16:05:19 +00:00
Mike Jolley 4071a7821f Check `$item->url` is set.
Closes #17014
2017-10-02 11:41:44 +01:00
Mike Jolley d56d11f1aa Use endpoint option in wc_get_endpoint_url
Fixes #13293
2017-02-23 12:37:41 +00:00
Mike Jolley d7dfdd3d10 Wrap all deprecation calls. 2016-11-23 16:15:00 +00:00
Matty ae75f8b8cd Adjusts all references of 'woothemes' to 'woocommerce' in relevant URLs, excluding the Travis CI integration which correctly uses 'woocommerce/woocommerce'. 2016-09-28 12:17:40 +02:00
Aristeides Stathopoulos 734f284fa4 WordPress.PHP.YodaConditions.NotYoda 2016-09-08 01:32:24 +03:00
Aristeides Stathopoulos d4e3faf014 PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket 2016-09-02 04:51:31 +03:00
Aristeides Stathopoulos 0516e96843 PEAR.Functions.FunctionCallSignature.SpaceBeforeCloseBracket 2016-09-02 04:33:57 +03:00
Aristeides Stathopoulos ff852038c9 WordPress.Arrays.ArrayKeySpacingRestrictions.NoSpacesAroundArrayKeys 2016-08-27 06:11:30 +03:00
Claudio Sanches 7d9d091767 Fixed mixed tabs and spaces 2016-07-11 16:56:35 +02:00
Mike Jolley a942cfade8 Make sure page ID is > 0
Closes #11305
2016-06-30 12:23:41 +01:00
Nicola Mustone aed3961ba2 fix logout endpoint handling 2016-05-31 08:46:05 +02:00
Mike Jolley 89af9e9416 wc_get_page_permalink - if the page ID is not set, redirect home instead 2016-03-07 10:29:01 +00:00
Mike Jolley fdddbff229 Fix my account endpoint with plain permalinks
@claudiosmweb Fixes #10390
2016-02-19 17:14:26 +00:00
Claudio Sanches 7ae806d16f Created new account functions file 2016-02-16 13:43:06 -02:00
Fredrik Forsmo 676525c2b7 Improve docblock comments in various functions
* Added missing param tags to functions
* Added comments to `wc_get_attachment_image_attributes` and
`wc_prepare_attachment_for_js`
* Fixed return type value for functions where it says bool but the code
returns array
* Renamed boolean to bool
2016-01-06 17:11:09 +01:00
Mike Jolley 3d7a40e41f spacing 2015-11-27 13:01:58 +00:00
Mauro Mascia 5a95bcf185 Check if the endpoints array key is set and not empty.
For some reasons in a client's website, I've found that "order-pay" is set but is empty (even if in the backoffice the variable is written in the endpoint's form). So, it is better to check with !empty, doesn't it?
2015-11-22 20:00:59 +01:00
Nicola Mustone c9da4f928a check if ABSPATH is defined 2015-11-06 10:22:19 +01:00
Claudio Sanches 5893875b0c Removed period for file headers 2015-11-03 11:53:50 -02:00
Claudio Sanches ee30b5b308 Fixed php docs standards 2015-11-03 11:31:20 -02:00
Mike Jolley f5933bf9d9 Fix active state check
Closes #9467
2015-10-30 13:31:52 +00:00
Mike Jolley 4747e097e2 [2.4] Fix notice in wc_nav_menu_items when endpoint is not set
Fixes #9216
2015-10-02 10:04:18 +02:00
Claudio Sanches 6d79f7f02b Fixed default wc_lostpassword_url() args, closes #8800 2015-08-12 17:43:04 -03:00
Mike Jolley ef89f82014 wc_get_page_permalink should check page_id was found 2015-07-13 10:59:34 +01:00
Mike Hansen 819f22df29 Update wc-page-functions.php 2015-06-10 17:53:34 -06:00
roykho 30111dd988 check to make sure wp_query object is not null before calling function that depends on it fixes #7981 2015-04-19 16:46:04 -07:00
Mike Jolley ec4a61d6e2 Only run wc_page_endpoint_title on frontend
Closes #7881
2015-04-10 16:20:36 +01:00
Mike Jolley 5d61028317 Unhook wc_page_endpoint_title after it is ran once (main page title).
Fixes #7488
2015-02-19 10:37:59 +00:00
Paul Wilde c913316f8b Introduce wc_get_page_permalink. 2015-02-15 19:13:22 +00:00
Mike Jolley 508bfd5c06 Merge branch 'breadcrumbs-class'
Adds endpoint page titles for #5522
Fixes link back to endpoint pages and closes #6638
Avoids need for breadcrumb fix which closes #6834
Removes the need and closes #6834
Fixes #6840
2014-12-05 13:42:19 +00:00
claudiosmweb 8eeb6fc204 Removed more some unused code 2014-11-19 22:43:09 -02:00
Mike Jolley 06aca23919 Enforce slug format of translated edit-address-slugs.
Fixes issues with addresses not loading correctly in edit account.
2014-10-22 11:26:09 +01:00
Mike Jolley 3f0271e46a Additional args for woocommerce_get_endpoint_url
Closes #6439
2014-10-01 16:50:25 +01:00
Mike Jolley c4ef86d44e scrutinizer patches 2014-09-08 00:37:55 +01:00
Mike Jolley a4346d9c90 Fix shop page when using verbose page rules
cc @claudiosmweb
2014-07-03 15:14:00 +01:00
Coen Jacobs 3ad8935b20 Removed ununsed global variables in local scopes 2014-06-08 22:33:11 +02:00
claudiosmweb 79a8986f06 added the possibility to translate the edit-address endpoint slugs, closes #4820 2014-04-24 18:18:41 -03:00
Mike Jolley 74e7829e02 wc_get_endpoint_url - added support for permalinks containing a query string Closes #5016 2014-03-03 11:54:53 +00:00
Coen Jacobs 3e6acf7aab Code changes for #4252 2013-12-02 12:34:27 +01:00
Gregory K 7b38c7300b Inconsistent return types: mostly TODOs, some fixes 2013-11-29 13:50:31 -05:00