Posts Tagged insert map

Live Writer for WordPress Blog Post, Pages and also Sidebar

Microsoft Windows Live Writer is the unsurpassed blogging editor. For WordPress blogs it handles pages as easily as normal posts. Live Writer can also be used to generate the HTML code needed for use in setting up sidebar features.

sidebarThis article explains the technique and procedure for doing so. Here is an image of a sidebar with multiple features, a map, some images and text with hyperlinks. Things that are easily inserted with Live Writer into posts. It works just as easily for use with the WordPress sidebar Text Widget. There are a few peculiarities that have to be carefully observed.

WordPress Text Widgets are used for arbitrary text or HTML. It is the HTML handling that makes them so powerful as most anything can be shown.

Live Writer can be used in its normal graphical interface, wysiwyg (what-you-see-is-what-you-get) to set up the HTML code.

Most sidebars are on the order of 250 pixels wide, it will help if you know the exact size of your sidebar. In Live Writer ignore the margins as they will be for your main area and not the sidebar. Since material in the sidebar will look best when centered, that is what you should use in preparation.

The main caution concerns images. They must be sourced from the web. Since you will not publish this post, Live Writer will not upload the images. So you need to upload all images manually before you set up the sidebar HTML.

Prepare your images

Prepare your images in the exact size that you want them to appear and upload them to the WordPress Media Library. This is a drag-and-drop procedure so it is quite fast and straightforward.

Obtain the file URL for each image. Be sure to get the file URL and not the permalink. See the illustrations below. It might help to just copy the ULRs and paste them into Notepad so they are handy when you are ready to use them.

LW-html-01

LW-html-02

Create the sidebar HTML

Open Live Writer to a blank post – you can name the post anything, but something like “sidebar 1” might be descriptive enough. You will not upload this post, only save it on the local PC.

Sidebar-setup-02Enter the text normally, center the text. When you need an image use Insert > From the web … Enter the image file URL.

Continue and build your sidebar.

Sidebar-setup-01

Note in the illustration above that the social media icons are not centered. If you want images beside each other set the Alignment to Left. Space them with the right or left margin setting so that the sum of the margins and image horizontal dimensions adds up to the width of the sidebar.

Inserting a map

Things get a little tricky when you insert a map. Live Writer lets you size the map image so you can fit it to the sidebar. However, that image is locally generated and stored. It is not uploaded to WordPress, since you will not publish this working post. So you must do a screen capture, clip out the map image, upload it to the WordPress Media Library just like any other image. But, and this is important, you can’t change the generated code to reference that image. Live Writer will overwrite it on every operation. You will need to make the change later.

When you are finished with the setup, click the Source tab (lower left). Select all the source text and copy it. You can store it on Notepad – a good place to make the correction for any map image.

Sidebar-setup-04

In the illustration here the code is selected in the Source view of Live Writer on the right and inserted into the Text Widget in the WordPress dashboard on the left. If you have no corrections to make to the code this is the quick and easy way. If you need to make a correction for a map image here are some additional notes.

Making the image reference correction for a map

Sidebar-setup-05Live Writer will generate an image of the map. The reference in the code needs to be changed to a file URL from the Library.

Find the reference in the code. Look for the section that contains the words “map picture”. Find the text <img src=. Replace everything in the quotes that follow with the file URL. In the illustration the reference generated by Live Writer is partially highlighted. It begins with a dollar sign, $.

Once the correction is made just save the Widget text and take a look at your blog.

Hope all goes well for you!

.:.

© 2012 Ludwig Keck

, , , , , , ,

5 Comments

Inserting maps in blog posts

Maps can make an article more informative and more interesting, and an interactive map provides a gateway to enjoyable resources to your readers. With Windows Live Writer, inserting a map is just about as easy as inserting a photo.

Let me walk through the procedure with an example. Let’s say that my blog article, about a fun vacation experience, contains a photo of the lighthouse on Tybee Island, Georgia. The story can be enhanced by displaying the location with a couple of maps.

imageThe Insert ribbon in the Media group sports a Map icon. This provides for inserting Bing maps. The Insert Map dialog starts with a world map. There is a Find location: text box which is the quickest way to show a map of a specific location. Just enter the name of the location of interest, click the magnifier “search” icon, and up comes your location.image.

The dialog shows a live Bing map. You can drag it around, enlarge or decrease the view, just as you can when you are using Bing Maps. Also available are “Road”, “Aerial”, or “Bird’s Eye” view. The road view, like a normal road map, is available for all parts of the globe. Aerial view, or what some call satellite view, coverage is nearly complete. The “bird’s eye” views are low level, oblique, aerial photos. Many destinations have been mapped this way. So you can select the best map for your post. In this article I have included two maps to illustrate the variety. But first the lighthouse photo, and below that a couple of maps. A road map to give provide location information and a “bird’s eye” view..

LJK_2242 (3872x2592)

Tybee Island near Savannah, Georgia
Tybee Island near Savannah, Georgia
Oblique aerial view of the Tybee Island lighthouse
Oblique aerial view of the Tybee Island lighthouse

Here in this blog post, as in your blog, these maps will lead to full-size Bing Map pages when clicked. In Windows Live Writer a map insert behaves a bit like an inserted photo. When clicked, a border is shown around it and there are option in a side bar on the right.image

You can see the border around the selected road map in the illustration above. The map can be resized with the resize handles the customary manner. The Customize Map… link in the side bar, brings up the customize dialog which is essentially the same as the insert dialog. You can move the displayed portion around and resize the view. You can also add a caption and customize the margins.

To make the location easier to communicate to the reader, I have zoomed out the map enough to show recognizable landmarks in the map, here Savannah, Georgia and Hilton Head Island, South Carolina.

I have also added a “pushpin” showing the location of the lighthouse. That is a mixed blessing. You can see that in the insert and edit dialogs there is a text line under the map saying: “Tip: Right-click the map to add a pin”. A pushpin will be added at the clicked location. You can move it around and specify some additional parameters. Unfortunately, the default operation brings up the “my places editor” on the viewer’s map, which may be more confusing than helpful.

.:.

© 2011 Ludwig Keck

, , , ,

Leave a comment