Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <div id="googleMap" style="width:100%;height:400px;"></div>
              
            
!

CSS

              
                
              
            
!

JS

              
                var element = document.getElementById("googleMap");
var map= new google.maps.Map(element, {
    center:new google.maps.LatLng(31.8790761,54.339135),
    zoom:12,
	mapTypeId: "ParsijooMap",
                mapTypeControl: false,
                streetViewControl: false
});
 //Define Parsijoo map type pointing at the ParsijooMap tile server
            map.mapTypes.set("ParsijooMap", new google.maps.ImageMapType({
                getTileUrl: function(coord, zoom) {
                    // "Wrap" x (logitude) at 180th meridian properly
                    // NB: Don't touch coord.x because coord param is by reference, and changing its x property breakes something in Google's lib 
                    var tilesPerGlobe = 1 << zoom;
                    var x = coord.x % tilesPerGlobe;
                    if (x < 0) {
                        x = tilesPerGlobe+x;
                    }
                    // Wrap y (latitude) in a like manner if you want to enable vertical infinite scroll

                    return "https://developers.parsijoo.ir/web-service/v1/map/?type=tile"+"&" +"x=" + x + "&" +"y=" + coord.y + "&" +"z=" + zoom +"&" + "apikey=b79aa829a62541e1897c1fcc2807a177";
                },
                tileSize: new google.maps.Size(256, 256),
                name: "ParsijooMap",
                maxZoom: 18
            }));
Object.defineProperty(HTMLScriptElement.prototype, "__src__", Object.getOwnPropertyDescriptor(HTMLScriptElement.prototype, "src"));
Object.defineProperty(HTMLScriptElement.prototype, "src", {
configurable: true, 
enumerable: true, 
get() { 
return this.__src__; 
},
set(new_src) { 
if (!new_src || !(new_src.startsWith("https://maps.googleapis.com/maps/api/js/AuthenticationService.Authenticate") ||
new_src.startsWith("https://maps.googleapis.com/maps/api/js/QuotaService.RecordEvent"))) 
this.__src__ = new_src; 
}
});
              
            
!
999px

Console