WordPress.org

Ready to get started?Download WordPress

Forums

Basic script addition to my site (3 posts)

  1. chieflorenzo
    Member
    Posted 3 years ago #

    Hi, I did post similar the other day but have had no reply. It really should be very easy to do, and I've managed to make it work on a local installation running on MAMP. I've got the below code that I want to put into a post or a page in my wordpress installation, and it just doesn't seem to display the Flash-enabled map on my live installation.

    Below is the sample code, and it works fully as an html page uploaded (example at http://www.convexum.com/glympse.htm), but not when embedded into my blog.

    I added the Script tags bit to the header.php file of my template between the <head> </head> tags, and I put the div tag and its content into the HTML view of the page or post.

    Here's hoping someone can help, and here's the html example code from the developer's site:

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>Glympse - Twitter Integration Example</title>
    
    <!-- Start of required <script> includes -->
    <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js" type="text/javascript"></script>
    <script type="text/javascript" src="http://a1.glympse.com/javascripts/swfobject.standalone.js"></script>
    <script type="text/javascript" src="http://a1.glympse.com/javascripts/jquery.glympser.js"></script>
    <!-- End of required <script> includes -->
    
    <script type="text/javascript">
    	/*
    	 * This can be placed arbitrarily in your page (after the above <script> includes), or within other
    	 * jQuery.ready() calls, if your page utilizes this type of functionality.
    	 */
    	jQuery("document").ready(function()
    	{
    		// Insert the Glympser in <div id="glympserContent">
    		$("#glympserContent").glympser( {  idTwitter: "Glympse_Fan"     // Twitter id to follow
    										  //,idTicket: "SetMe!"         // Glympse ticket id to follow (unused if idTwitter is set)
    										  ,w: 640                       // Width of Glympser window
    										  ,h: 440                       // Height of Glympser window
    										  ,mapType: "normal"            // Normal street view
    										//,mapType: "satellite"         // Overhead satellite view
    										  ,zoom: 13                     // Default zoom level
    										 });
    	});
    
    </script>
    </head>
    
    <body bgcolor="#ffffff">
    <div id="glympserContent">
    	<h1>Incompatible Adobe Flash player</h1>
    	<p><a href="http://www.adobe.com/go/getflashplayer">Get the latest Adobe Flash player</a></p>
    </div>
    </body>
    </html>
  2. kkarpieszuk
    Member
    Posted 3 years ago #

    you embed html document (with doctype and everything ellse) into another html document? wrong, you destroy DOM of this file.

    second:
    also write 'jquery wordpress' and at first place you will what you need to change

  3. kkarpieszuk
    Member
    Posted 3 years ago #

    also write 'jquery wordpress'

    i mean write in google :)

Topic Closed

This topic has been closed to new replies.

About this Topic