how to add google maps as a media provider

  • this is the code for the map :

    Code
    https://www.google.com/maps/d/embed?mid=zKdWArp-8jnI.kq2p3pfdLRG0


    this is the code for the iframe


    Code
    <iframe src="https://www.google.com/maps/d/embed?mid=zKdWArp-8jnI.kq2p3pfdLRG0" width="640" height="480"></iframe>
  • i try this
    in regular expression

    Code
    https://www.google.com/maps/d/embed?mid=(?<ID>[0-9a-zA-Z]+)
    Code
    <iframe style="max-width:100%;" width="560" height="315" src="https://www.google.com/maps/d/embed?mid={$ID}" allowfullscreen></iframe>

    but this not work

  • Hi, I'm not a RegEx expert but I got it working. This code will only match the URLs of the type you posted.


    http[s]?://(?:www\.)?google\.com/maps/\w/embed\?mid=(?<ID>[a-zA-Z0-9-.]+)


    And

    Code
    <iframe class="gmap-embed" src="https://www.google.com/maps/d/embed?mid={$ID}" width="640" height="480"></iframe>

    My styles and plugins in the Plugin-Store.

    Display Spoiler

    — ¡Carajo! —gritó

    Amaranta, que empezaba a meter la ropa en el baúl, creyó que la había picado un alacrán.

    — ¿Dónde está? —preguntó alarmada.

    —¿Qué?

    — ¡El animal!

    Úrsula se puso un dedo en el corazón.

    — Aquí —dijo.

    ♪Quiero robarle los minutos a las horas pa' que mis padres nunca se me pongan viejos...♫

  • Hey, how did you got this link https://www.google.com/maps/d/embed?mid=zKdWArp-8jnI.kq2p3pfdLRG0?


    When i search a city in maps i get this link: https://www.google.de/maps/place/New+York+City,+New+York,+USA/@40.7058254,-74.1180863,11z/data=!3m1!4b1!4m2!3m1!1s0x89c24fa5d33f083b:0xc80b8f06e177fe62?hl=de

  • Can you try this.

    Name:
    Google MyMaps

    RegEx:
    http[s]?://(?:www\.)?google.com/maps/d/(viewer|edit|embed)\?mid=(?P<ID>.+)

    HTML:
    <iframe style="max-width:460px;" src="https://www.google.com/maps/d/embed?mid={$ID}" width="100%" height="350"></iframe>

    @all: Please take Google MyMaps as the name for the media provider because i will include it to my Plugin

    woltlab.com/pluginstore/file/2207/


    So maybe later, if you possibly install my plugin, it will be overwrite and not doubled

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!