Description Dotsadd Descriptive Hotspots To Your Images

Plumes & Hotspots Below Continents. The third basalt-forming environment is a continental environment where a mantle plume or hotspot delivers enormous amounts of basaltic lava through the continental crust and up to Earth's surface. These eruptions can be from either vents or fissures. They have produced the largest basalt flows on the continents. Optimize your images. Images are essential to making your content interesting and shareable. People are far more likely to purchase from a company whose website has attractive and relevant photos. You can optimize the photos by adding keywords to the image files and providing the ALT tags. Make sure you also optimize the size of the photo.

  1. Description Dotsadd Descriptive Hotspots To Your Images Transparent
  2. Description Dotsadd Descriptive Hotspots To Your Images Free
  3. Description Dotsadd Descriptive Hotspots To Your Images Online
  4. Description Dotsadd Descriptive Hotspots To Your Images High Resolution
  • HTML Tutorial
  • HTML References
  • HTML Resources
  • Selected Reading

We have seen how to create hypertext link using text and we also learnt how to use images in our webpages. Now, we will learn how to use images to create hyperlinks.

Example

It's simple to use an image as hyperlink. We just need to use an image inside hyperlink at the place of text as shown below −

This will produce the following result, where you can click on the images to reach to the home page of Tutorials Point.

This was the simplest way of creating hyperlinks using images. Next we will see how we can create Mouse-Sensitive Image Links.

Mouse-Sensitive Images

The HTML and XHTML standards provides a feature that lets you embed many different links inside a single image. You can create different links on the single image based on different coordinates available on the image. Once different links are attached to different coordinates, we can click different parts of the image to open target documents. Such mouse-sensitive images are known as image maps.

There are two ways to create image maps −

  • Server-side image maps − This is enabled by the ismap attribute of the <img> tag and requires access to a server and related image-map processing applications.

  • Client-side image maps − This is created with the usemap attribute of the <img> tag, along with corresponding <map> and <area> tags.

Server-Side Image Maps

Here you simply put your image inside a hyper link and use ismap attribute which makes it special image and when the user clicks some place within the image, the browser passes the coordinates of the mouse pointer along with the URL specified in the <a> tag to the web server. The server uses the mouse-pointer coordinates to determine which document to deliver back to the browser.

When ismap is used, the href attribute of the containing <a> tag must contain the URL of a server application like a cgi or PHP script etc. to process the incoming request based on the passed coordinates.

The coordinates of the mouse position are screen pixels counted from the upper-left corner of the image, beginning with (0,0). The coordinates, preceded by a question mark, are added to the end of the URL.

Description dotsadd descriptive hotspots to your images free

For example, if a user clicks 20 pixels over and 30 pixels down from the upper-left corner of the following image −

Which has been generated by the following code snippet −

Then the browser sends the following search parameters to the web server which can be processed by ismap.cgi script or map file and you can link whatever documents you like to these coordinates −

This way you can assign different links to different coordinates of the image and when those coordinates are clicked, you can open corresponding linked document. To learn more about ismap attribute, you can check How to use Image ismap?

Note − You will learn CGI programming when you will study Perl programming. You can write your script to process these passed coordinates using PHP or any other script as well. For now, let's concentrate on learning HTML and later you can revisit this section.

Client-Side Image Maps

Client side image maps are enabled by the usemap attribute of the <img /> tag and defined by special <map> and <area> extension tags.

The image that is going to form the map is inserted into the page using the <img /> tag as a normal image, except it carries an extra attribute called usemap. The value of the usemap attribute is the value which will be used in a <map> tag to link map and image tags. The <map> along with <area> tags define all the image coordinates and corresponding links.

Description Dotsadd Descriptive Hotspots To Your Images Transparent

The <area> tag inside the map tag, specifies the shape and the coordinates to define the boundaries of each clickable hotspot available on the image. Here's an example from the image map −

This will produce the following result −

Coordinate System

The actual value of coords is totally dependent on the shape in question. Here is a summary, to be followed by detailed examples −

  • rect = x1 , y1 , x2 , y2

    x1 and y1 are the coordinates of the upper left corner of the rectangle; x2 and y2 are the coordinates of the lower right corner.

  • circle = xc , yc , radius

    xc and yc are the coordinates of the center of the circle, and radius is the circle's radius. A circle centered at 200,50 with a radius of 25 would have the attribute coords = '200,50,25'

  • poly = x1 , y1 , x2 , y2 , x3 , y3 , .. xn , yn

    The various x-y pairs define vertices (points) of the polygon, with a 'line' being drawn from one point to the next point. A diamond-shaped polygon with its top point at 20,20 and 40 pixels across at its widest points would have the attribute coords = '20,20,40,40,20,60,0,40'.

All coordinates are relative to the upper-left corner of the image (0,0). Each shape has a related URL. You can use any image software to know the coordinates of different positions.

A rebuilt version of Sites was launched on November 22, 2016. The Sites API cannot access or modify Sites made with this version, but can still access classic Sites.

At Google, gadgets are HTML and JavaScript applications that can be embedded in web pages and other apps, including Sites. These gadgets offer the ability to include external and dynamic content within your site, such as miniature applications and database-driven lists, incorporated with text and images for a seamless user experience.

Every Sites page is a potential gadget container. What's more, Sites offers a Data API that may be used in conjunction with gadgets to create powerful applications. That means as a gadget developer you can leverage the Sites API to build engaging tools for other Web developers and their audiences, as well for your own use.

When you build a gadget for Sites, it becomes available to millions of activeusers. Just submit your gadget to us, and it will appear where users can easily browse, configure, and add your gadget to theirSites. The 10step guide to a successful ecommerce shipping strategy.

So now you know Sites is a great distribution platform for your gadget, what areyou waiting for? Get started building gadgets for Sites now!

Sites gadget overview

Generically, gadgets are small utilities that generate or pull external information into web pages. In its simplest form, a gadget is a small .xml file that retrieves information with the ability to make it available in multiple web pages at once. In Sites, including a gadget results in an iframe that acts as the conduit for this external information. Some gadgets are no more than that, iframes that pass through information from another web site.

More advanced gadgets collect dynamic content and provide for interactive applications within your Sites pages. See Example gadget.

Gadgets consist of the following components:

  • Gadget spec file - A .xml file that wraps HTML and JavaScript functions.
  • Container page - The Web page where the gadget is inserted, in this case a Google Site.
  • External data source - This is optional and may reside in the same location as the .xml file but is often called by the gadget spec over HTTP to provide its results.

Gadgets built for Sites may be used by all viewers of a site. They tend to be interactive, focused on pulling in dynamic content rather than on presentation, and are designed to complement the content of the site.

A calendar gadget is a good example of this distinction. A personalized calendar gadget in would likely show the calendar of the logged in user by default, while a calendar gadget in Sites might allow collaborators to select from a variety of location-specific calendars.

Sites gadgets allow you to present multiple pieces of information from external sources (say live diagrams from distinct but related performance dashboards) in a single page along with explanatory text published directly in Sites. This saves visual real estate while collecting disparate information on the same topic in the same view. Gadgets also allow you to include dynamic content that would otherwise be prevented by Sites security checks.

Warning: Gadgets built with the legacy gadgets API may work in Sites but are not officially supported. Built-in and feed-based gadgets are similarly not supported. Therefore, Google recommends you build all Sites gadgets using the current gadgets.* API. See this post for an explanation:
http://igoogledeveloper.blogspot.com/2009/09/more-things-change-more-they-stay-same.html

Example gadget

Here is a simple but popular Include gadget that does little more than provide an iframe for passing through other web content:

See Getting Started: gadgets.* API for a complete description of gadget tags and expected contents.

Hosting your gadget

Regardless of what your gadget does, its files must reside on the World Wide Web to be found and used. Any online location accessible over HTTP without authentication will do. Just remember, your gadget will have to be published in a public directory to be selected. Otherwise, users must embed it by directly inserting its URL.

Here are your gadget hosting options:

  • App Engine - Capable of storing all files required by your gadgets. Does require some setup, namely the creation of projects and subsequent file uploads. But it will readily scale to a large number of users. You can create an application to store all of your gadgets and another to serve static files, including an app.yaml file resembling:

    If you put all of the gadget files in the static directory, you may then edit the files on your local directory and deploy to App Engine each time you make changes. If you have a file /static/gadget.xml, its URL will be: http://<your-app-name>.appspot.com/static/gadget.xml

  • Any online location of your choosing - Completely under your control but also your complete responsibility. Downtime on your server may result in an outage for users of your gadgets.

Description Dotsadd Descriptive Hotspots To Your Images Free

Building your gadget

Gadgets are just HTML and (optionally) JavaScript, Flash or Silverlight wrapped in XML. The Gadget Developer Guide provides all necessary details for building your own gadgets. In addition, OpenSocial templates may be used to quickly build social applications in gadgets.

Here are the high-level steps for building a gadget for Sites:

  1. Decide where your gadget will be hosted. See the Hosting your gadget section for descriptions of your options.
  2. Create a new .xml file that will act as your spec using the text editor of your choice.
  3. Decide on the content type, either HTML or URL, and specify it within the gadget .xml file, like so:
    <Content type='html'>
    This will almost invariably be HTML, which assumes all content is provided directly in the .xml file. But if you intend to supply the content in a separate file, use the URL content type. See Choosing a Content Type for a full description of their differences.
  4. Create content in the gadget .xml file or in separate files called by the spec. See the Viewing example gadgets section for ways to examine existing gadgets.
  5. Define basic preferences for the gadget that can be altered by users. See Defining User Preferences for instructions. To provide more advanced configuration, see the Allowing advanced user configuration section.
  6. Define module preferences that only the gadget author may change. See Defining Gadget Preferences for additional details.
  7. Test the gadget. See the Testing your gadget section for instructions.

Embedding your gadget

Gadgets can be embedded in Sites pages either by selecting it from the Sites gadget directory (which is synchronized with the iGoogle gadget directory) or by including its URL directly.

Description Dotsadd Descriptive Hotspots To Your Images Online

To embed a gadget in Sites:

  1. Go to the Sites page that will contain the new gadget.
  2. Open the page for editing.
  3. Select Insert > More gadgets.
  4. Search for the gadget, select it from the categories on the left, or click Add gadget by URL and paste in the URL to your .xml file. Then click Add.
    Tip: This same Add gadget by URL method may be used to embed gadgets from iGoogle and anywhere else online.
  5. Specify the gadget's dimensions, select from available settings and click OK. The gadget is added to your page.
  6. Save the page to view and test your gadget in the site.

Testing your gadget

After building your gadget, you should test it thoroughly before using it and allowing others to do the same. Test your gadget manually by creating one or more test Google Sites and embedding your gadget. See the Embedding your gadget section for precise steps. The functionality and appearance of your gadget depends on the site that contains it. Therefore, the best way to debug your gadget is to test it in the context of an actual Google Site. Try switching between various Sites themes to ensure your gadget appears correctly in each.

Description Dotsadd Descriptive Hotspots To Your Images High Resolution

As you test your gadget, you'll inevitably discover bugs and need to make corrections to your gadget .xml file. You should disable gadget caching while you're tweaking the XML. Otherwise, your changes won't show up on the page. Gadget specs are cached unless you tell Sites not to. To bypass the cache during development, add this to the end of the Sites page URL containing the gadget (and not the URL of the gadget spec .xml file):

Sites provides a standard UI for adding and configuring gadgets. When you add a gadget, it will display a preview and show any UserPref parameters that can be configured. Test updating various configuration values and adding your gadget to your test site. Confirm your gadget works as expected on the site itself. You should test that any UserPref you've defined can correctly be configured by the site administrator.

Then refer to the Preparing for Publication section of Publishing Your Gadget for other tests to carry out.

Allowing advanced user configuration

All gadgets may offer the ability to set basic user preferences, done through the UserPref section of the gadget spec file. These typically affect dimensions, scrollbars, borders, titles and gadget-specific settings, as depicted in the screenshot here:

But there are many cases where gadgets benefit from more advanced preferences than the standard UserPref components offer. Preferences often need to include features like custom business logic, validations, or pickers. The interface generated from the gadget UserPref sections supports a limited number of datatypes (string, enum, etc.), so validation of inputs like URLs or dates cannot be conducted.

Further, in containers like iGoogle where the viewer and editor are the same, gadget authors can extended configuration as part of the standard view. In Sites, the viewer is not always the editor, so the gadget author can't guarantee the viewing user has access to update preferences. Social containers such as Sites cannot allow any user to modify the preferences, only the author.

In Sites, the basic gadget preferences interface generated by UserPref can be replaced by a configuration view where many additional preferences and data types may be supplied, as in the screenshot shown here:

The configuration view is shown in place of UserPref settings at insertion time or edit time and allows you to set user preferences with a custom interface. And you can have custom input elements, such as for picking a position on a map rather than entering map coordinates.

Developers can use the standard setprefs APIs to save preferences in this view. See Gadgets XML Reference and the Saving State section of Developer Fundamentals for additional details. These views allow the container application to provide supplementary configuration information and are established in the gadget .xml spec files following the UserPref sections with an opening tag resembling:

For instance, the news.xml gadget that provides the configuration view above contains this section:

You can find this example and other Sites-specific gadgets with configuration views here:
https://www.gstatic.com/sites-gadgets/news/news.xml
http://gadgets.pardonmyzinger.org/static/qrcode.xml
https://www.gstatic.com/sites-gadgets/news/youtube_news.xml

Following best practices for Sites gadgets

Sites users want to look good on the web. Follow these best practices so your gadget blends seamlessly with the many themes used in Sites. See Gadgets Overview for details on creating gadgets. The rest of this section presents guidelines particular to Sites gadgets.

  • Do not put sensitive information in gadget specs or titles because your gadget is viewable by the public. For example, don't include internal project names.
  • To minimize visibility to your gadget, do not submit it to the iGoogle gadget directory or any other public listing service. Instead, have all users include it by URL only. In addition, you may create a URL-type gadget (rather than the typical HTML type containing all contents) that merely calls another file for its contents. With this pass-through option, only the URL of the second file is exposed. See the Choosing a Content Type section of Developer Fundamentals for differences between HTML and URL gadgets and the Gadgets are Public section of Writing Your Own Gadgets for other ways to mask your gadget.
  • Most importantly, test your gadget on a number of different sites. Modify the site's background color, text color, and font face to ensure your gadget blends with a wide range of templates.