0

I am trying to get the current week's day and time based on WordPress time settings. So for today, I want to output Friday and 2:56 PM for the time.

The the_time('l') and the_date('d') functions seems to be only working when in the loop, I could use date('l') but what if the php time is different than the time user sets in WordPress settings, could that happen?

0

Use current_time to output the time based on the timezone set on the blog's General Settings page.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.