Question
I have a link http://www.example.com/my-account/view-pet/?pet-page=2 I want to change it to either http://www.example.com/my-account/view-pet/pet-page/2 or http://www.example.com/my-account/view-pet/2 Here's what I have tried to so far function wpse12065_init() { add_rewrite_rule('view-pet(/([^/]+))?(/([^/]+))?/?', 'index.php?pagename=my-account/view-pet&pet-page=$matches[2]', ...
0
1 hour 0 Answers 1 views

Question
On post/page editing screen, I want to call my functions as soon Gutenberg editor/whole page is fully rendered and visible. On WP 5.2.2, I have tried jQuery(document).ready(function () {}); and wp.domReady(function() {}); but both of these functions are called before ...
0
1 hour 0 Answers 1 views

Question
I used to use the following code from within Wordpress to let users look up which colleage company they have to contact based on their zipcode: <form action="https://www.energiewacht.com/action/zipcodes/contactinfo/" method="get" target="_blank"> Zoek een ...
0
1 hour 0 Answers 1 views

Question
I'm trying to add some condition in the product cart quantities based on the URL in woocommerce Like if the URL has a certain string than restrict cart value // Checking and validating when products are added to cart global $wp; $url = home_url(add_query_arg(array(), ...
0
3 hours 0 Answers 2 views

Question
Wordpress has a feature whereby it will automatically redirect your URLs if it percieves them to be written wrongly. Here is an example: I have a page called my-page If I go to: www.mysite.com/something/my-page/ it will immediately redirect me to www.mysite.com/my-page/ as nothing exists ...
0
4 hours 0 Answers 2 views