I agree with J.M. and Jimi.
It's semantically acceptable to use a gerund following a possessive adjective/determiner, but, as with anything, it can be clearer in some sentences (e.g., "his new shoes really helped with his running...") than in others ("Company X experimented with its expanding into a new business area...").
Just my two cents!
It's grammatically incorrect: "You know you're having a rough day when kittens don't even make you smile" is what was meant. It was either a typo, a thinko, or just another ignoramus expressing itself.
That said, however, it is possible to say something like this:
Your having a bad day is not going to ruin my day.
Some native speakers might write and say it this way:
You having a bad day is not going to ruin my day.
Now that you've added a question, I'll add more of an answer.
If you want to make the first sentence grammatical without changing "your" to "you're", it has to be something like this:
You know (that) your having a rough day is true when kittens don't even make you smile.
The syntax of the sentence is different. In the sentence immediately above, your having a rough day is a gerund clause that serves as the subject of a subordinate clause because it is preceded by that, what Linguistics Professor John Lawler calls a complementizer, which means that it requires a predicate: a verb and what some people would call a subject complement. I don't want to dwell on terminology, because it isn't always agreed upon, even by professional linguists (I'm not a professional linguist).
In your original example and your added analysis, the verb and subject complement are missing, but it's not grammatically possible to do that in this case by eliding them from the sentence. If you had given us this instead:
Your having a rough day is clear. You know it when kittens don't even make you smile.
then you can say "it" = "your having a rough day", because it is a pronoun that refers back to the first sentence.
The gerund clause is a noun phrase. If I substitute another noun phrase, e.g.,:
You know giraffes when kittens don't even make you smile.
you should be able to see that something is wrong because the sentence is incomplete, not elided. I can change it to:
You know giraffes are evil when kittens don't even make you smile.
Now it's a grammatical sentence, but it's semantically unacceptable because it's totally illogical.
To make the other new sentence simpler, let's change it to this:
He resents (you/your) being more popular.
or
He resents (you/your) having a good day.
If:
A: I'm having a good day.
B: I know it. (it = you are having a good day) But John resents it. (it = the fact that you are having a good day)
I can say:
1: I resent your being more popular.
just as I can say:
2: I resent giraffes.
but I must say:
3: I resent (it) that you are more popular.
Best Answer
When I first heard about this usage in a grammar lesson in middle school, it sounded weird to me, too. As in the linked page in your answer, my teacher taught us that using possessive pronouns (also known as genitives) is the only grammatical way to mark subjects of gerund clauses. While that way is more traditional and formal, using object pronouns (accusatives) is also quite common.
In chapter 14, section 4.3, of the Cambridge Grammar of the English Language, entitled “Non-finite and verbless clauses”, the main thrust lays waste to the traditional distinction between gerund clauses and present participle clauses, by arguing they all belong to a single inflectional category; namely, gerund-participles. However, there is a paragraph explaining the use of genitives with gerunds:
In other words, gerunds (as in example 39i) can take either the genitive (his) or the accusative (him) as subject, with genitive being more formal and accusative less formal. The nominative (he) is not possible as the subject of a gerund.
In participial clauses with a subject (as in example 39ii), there is a similar situation: both the nominative (he) and accusative (him) are possible, again with accusative being less formal, but the genitive (his) is not possible.
The page of “grammar tips” linked in the question confuses informal style with incorrect grammar, a common problem in grammar advice. The versions of the examples with accusative instead of genitive (e.g. What do you think about him buying such an expensive car?) are perfectly grammatical and simply a less stuffy style.
You will find many examples of gerunds with accusative subject—even in formal academic writing—so you should feel free to use whichever of the two formulations seems natural.