I have a front-end editing form, where users can update specific post data (ACF custom fields). The problem is, that the users only know the post slug, not the ID. So I need a page before, where I can convert the slug to post ID, then pass it as a url parameter, and redirect to the update page above. I
Tag: wordpress
Need to change product images based on logged in user [closed]
Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 2 days ago. This post was edited and submitted for review 2 days ago and failed to reopen the post: Original close reason(s) were not resolved Improve this question I have
Add wp_enqueue_script() in functions.php
I’m trying to add Maps JavaScript API in wordpress without plugins. I have seen that to do that I need to use the wp_enqueue_script() function. However, I would like to know what is the correct way to add this function in the functions.php file? Thank’s Answer
Deleted all cookies on wordpress.com now I am getting logged out
I wanted to delete all cookies on my wordpress.com website so that one of my popups should continue appearing. This is the code that I wrote in my function.php file: After I saved this I kept on getting logged out of WordPress because I had deleted all my cookies. I tried removing it from functions.php and saving the file but
Hide woocmmerce payment gateways if user comes from given page on wordpress site
Am trying to hide paypal payment gateway for a digital product. For some complex reason I have to hide the payment gateway not entirely for the product, but if the user proceeds to checkout from another page (referrer page). Here is the code I tried to put together, but it doesnot hide the gateway. Any assistance will be appretiated. Answer
Menu option not available under appearance tab in WP dashboard (integrate custom html template
I am new to WordPress I have integrated my HTML template to WordPress. However I am looking for a menu option within WordPress dashboard like other template but couldn’t see the menu option. Dashboard -> Appearance -> Menu Could anyone suggest how I am going to see the menu option or where to add menu file so that I can
Create order details shortcode for WooCommerce
Hey I am trying to build a shortcode for my order details on the order received page. The code below will generate the last result and then on top of it, it will display the word Array. My guess is that something in the foreach loop i am creating is still an array, but I dont know what to do
How to display html tag with css using esc_html?
I am editing the woocommerce orders.php template and ran into a problem. The template shows to user the orders he has placed. There are now several variables that I think need to be coded for security, such as $date_created or $view_order which contains the order link. So I’m trying to add esc_html to these and other variables but when I
Add a custom WooCommerce settings page, including page sections
I’m trying to add a custom settings tab to the WooCommerce settings screen. Basically I want to achieve a similar thing to the Products settings tab, with the subsections/subtabs: I haven’t been able to find any decent documentation on how to do this but I’ve been able to add a custom tab using this snippet: Based on what I’ve dug
How can I not run this command ‘sudo amazon-linux-extras install -y lamp-mariadb10.2-php7.2 php7.2’?
I am following this tutorial: https://aws.amazon.com/getting-started/hands-on/deploy-wordpress-with-amazon-rds/?refid=dd707452-50b0-4e41-9f2b-d84c7ca273d4 in an attempt to create my own wordpress server on ec2 / rds of AWS. However, I DO NOT want to run this line because wordpress does not like php7.2. This is my second time through, and the first thing I found was that I needed to upgrade php, which does not seem possible