joshdick / miniProxy

🚨⚠️ UNMAINTAINED! ⚠️🚨 A simple PHP web proxy.
http://joshdick.github.io/miniProxy
GNU General Public License v3.0
860 stars 544 forks source link

Add content to the body? #88

Closed BelleNottelling closed 7 years ago

BelleNottelling commented 7 years ago

How can content (like an image) be added to an HTML <body> </body>?

joshdick commented 7 years ago

Can you give more context here?

joshdick commented 7 years ago

@BenNottelling bump

BelleNottelling commented 7 years ago

I was thinking about adding the coinhive script, but I don't really want to have the site marked as "malware/viruses" so I'll pass on it

colroyce commented 6 years ago

Hi! Thank you for this great proxy! How can I add any additional content to proxified page? E.g. banner or text (and google analytics code maybe), preferably to header?

joshdick commented 6 years ago

@colroyce The answer is probably too complicated to explain in a GitHub issue, but the most straightforward way would be to use the DOMDocument APIs to append content to $doc right before the $doc->saveHTML(); call at the bottom of the script.

colroyce commented 6 years ago

Oh, thank you so much!

joshdick commented 6 years ago

@colroyce You're welcome!