woocommerce – Also send new admin order mail to the logged in user

I have to be able to send that Admin Mail for a new order also to the e-mail address linked to the currently logged in user,

This is required as 1 account is for different people (Persons who give a gift), but the account originally created is still linked to the email address of the original user (from the parent).

In this way, parents will be notified by email when a new gift is made.

I do not seem to find the fix here. I've begun to change the code from adding a second email address to a completed order in WooCommerce, but now I'd like to dynamically add the user's email address.

Any ideas, what am I doing wrong here?

/ * REGISTER ADMIN E-MAIL TO A USER * /
/ * --- * /
add_filter (& # 39; woocommerce_email_recipient_new_order & # 39 ;, your_email_recipient_filter_function & # 39 ;, 10, 2);

/ * Add the parent's email address to the new admin email address * /
function your_email_recipient_filter_function ($ receiver, $ object) {
$ user_info = get_userdata ($ order-> user_id);
$ Recipient = $ recipient. & # 39;, & # 39 ;. $ user_info-> user_email;
Return $ recipient;
}

web – Responsive Scheduler – User Experience Stack Exchange

I design a simple scheduler where I do not need any information other than days / hours, no calendar information, no titles, no description, only days / hours.

The scheduler consists of a selection of 20 minute intervals with the option to copy, paste and delete any hour block.

The main problem I'm facing is that the scheduler needs to be accessible.

It was pretty easy for Web because I could play with a "click and drag" gesture to select the hours on any given day (I've badly sketched that for purposes of illustration):

WebSketch

But for mobile phones, the "click and drag" gesture obviously does not work (if you scroll through the scheduler, the next few hours are displayed). I tried to imagine how the user can select the lessons as easily as the web. I do not want to go to "Google's Calendar" because it was so much for me to touch an interval and then choose the hours. That's why I remembered an app (I can not remember the name), the one strange Control the block hour as desired (eg violet block):

Mobile Sketch

Therefore, when an interval is touched (focus), the control appears and you can increase or decrease the hourly interval; if the focus is out of focus, the controller disappears.

But I have my doubts, I do not know if this is a simple and easy way, or if I'm just thinking about it, so I want your general opinion, how do you feel about this approach? Can you imagine something easier?

Many Thanks.

WordPress – Displays only the category desired by the user

When I insert the WordPress loop into the category.php page without an argument, it usually shows the posts of a particular category. However, I have used some arguments in the code. Now, when I click on a specific category, all posts are displayed by all categories.
This is the code I use in the category.php page:

                    "Fiat"
"post_status" => "Publish",
& # 39; Order & # 39; => & # 39; DESC & # 39;
);
$ query = new WP_Query ($ args);

if ($ query -> have_posts ()) {
while ($ query -> have_posts ()) {
$ query -> the_post ();
$ meta = get_post_meta (get_the_ID ());
?>

                
<img src = "http://stackoverflow.com/"alt =" ">

Cod:

Model:

Could you help me to complete the code so that only the category that the user wants is returned?
Thank you

Ecommerce – Ask the user for the checkout

I'm working on the e-commerce checkout and the GA shows that we have a pretty high payout rate.

I assume that the users often do not complete the checkout, but only put the items in the cart and then watch the full order price.

I know the 4 most popular reasons for calls from user support.
Our CEO, of course, wants to reduce the drop rate and suggests using the user feedback pop-up when the user leaves the page.
I see this as a dark pattern that makes our website feel needy and distracting.

The option I normally see shows this popup when the cursor moves up the tabs. NNg says it may not be an attempt to leave, just the intention to switch to another tab and then likely to return.

Another option that I thought about is to add the rather subtle "back" button and ask the user for the reason when he returns to the previous page.

What do you think? Should I use one of the two options mentioned, or something else?

WhatsApp sends out Chrome – Super User

I'm developing an app to send messages in WhatsApp with JS. My app just calls the following URL with the correct get parameters:

https://web.whatsapp.com/send?phone=9999999999&text=Mytext

It works, but every time I have to send to a new number, when I call this URL again, WhatsApp is completely reloaded, and it takes a lot of time. Is there a way to do this without reloading the Whatsapp app?

theming – The website's branding block will not appear on the contact or user registration form

I have a topic and can configure the site branding block to appear on my Content-Type pages and a full-width template that I have. This is because I have {{page.branding}} in the template.

However, it does not appear on the contact page or user logon page. Is it because they are not "pages" or "content types"? What do I miss?

8 – Hide the password field during user registration?

I did not enable this option:

[ ]    Email confirmation required when a visitor creates an account

If I remove the check mark, the user must enter a password when registering. The problem is, I want the user to be able to register without a password and also not receive a new login email. This is because a user who logs on to the site can log in immediately. I can not use the blocked state for the user. I need the user to avoid being blocked. And then I added a new "real confirmation" box after clicking on the link in my own custom email.

An even better solution would be if I could use Drupal's login method, but the user can log in even if it's not verified. Maybe there is something that already does this?

oauth – Invalid API tokens if the LDAP user is invalid

I use oauth2 and LDAP for the authorization and authentication of an API. The authentication process is given below.

  1. The user sends the LDAP user name and password (with the password type)
    the server.
  2. Server validates the password that communicates with the LDAP server. If valid, the server returns an access token and a refresh token.

The user will access APIs with access tokens until they expire. After expiration, the refresh token can be used to retrieve a new access token and a new refresh token. The user can access the APIs at any time to update the tokens.

Another requirement is that tokens become invalid if the user's password is changed or if the user is disabled on the LDAP server. Is there anything to do at all?

So far, I have tried the following approach:

Save the LDAP password hash on the server if the user originally sent it.
When updating the token, get the user's password hash from the LDAP server and compare it with the one stored in the server.
However, it seems that it is not always possible to retrieve the hash. This depends on the LDAP configuration, directory, and permissions