The bottom line is the options that GMaps offers in regards to embeds kind of sucks.
- Try and wrap a link with your own iframe and it doesn't work.
- If you're not careful with their embed code, you can break it.
- If you want to just allow any code and let VBulletin wrap an iframe around it, you run the risk of some joker iframing a scat porn or malware site on a popular page in the 'sink. This site gets the traffic, so its a totally reasonable risk/fear.
So what I built was a little js that takes the full iframe from GMaps to make it super easy for the user(I hope). It then strips the front end and rear end of the code to temporarily neuter the code, then reapplies that same code itself so that VBulletin is the one building the iframe and not the user. Fairly secure, and works "ok"...
If I have a minute, I'll see if I can use js to dump the GMaps iframe tags into a regex for that trim operation. Perhaps that will make it robust in only accepting GMaps code...(?)
Now if G could change it up to offer up maps like they do with YouTube videos, then it could be nice and easy and secure. :nchantr
IDK, they're playing games with Google maps and licensing and what not for devs and using maps now a days anyway so who knows what might change or not change. G knows that GMaps in all its forms is a super useful content piece that they have. Monetizing its use is just part of the business model.