Ethical Hacking - Python

Hello - I am working on this program “Dns Spoofing”, python program. When I execute it locally its working perfectly fine. But when it against a remote computer, its not working. But I found a pattern.
When I use this against a machine, and when I ping the spoofed hostname, I get this text suffixed at the end of each ping response (DUP!). But still I get the same IP and not the spoofed IP.

This is not working with the http websites as well.

Is this remote computer within your network? Or are you trying to do it outside your network. Can you also tell me which course and video this DNS Spoofing is in?

Hello Apurv, it is the remove computer in my machine. The course is Learn Python & Ethical Hacking From Scratch - by Zaid. The DNS Spoofing is in Section 7.