adding text to a kml icon - kml

I have a document with many placemarks. Each placemark is a bicycle station, and I have to show how many bikes are in the station. Is there a way to add text to the placemark icon?
(I'm aware I can put this data in the balloon, but I really need to add this to the Icon)
Thanks,
Ami

I think the easiest way would be to change the icon file you are pointing to based on the number of bicycles at that location. You could use icons like these a MapIcons http://mapicons.nicolasmollet.com/numbers-letters/

The general answer is KML supports LabelStyle which allows you to style the displayed.
The other option is to create custom markers with the numbers associated with them.
Other options would depend on how you are displaying the kml.

Related

Previewing icon font WITHOUT css

I need to view an icon.ttf (svg,woff,eot,whatever) font file. I do NOT want to create CSS to do this. There are hundreds of icons and I need to look at them quickly. Is there anything I can use to open the font file?
The only responses are along this vein: If I have a generated icon-font as TTF, can I tell which CSS content-property belongs to which character? and include CSS - that is NOT what I am looking for. I want to preview the file NOT through manual entry using CSS (or SASS, etc).
I am assuming this cannot be done since I havent found a decent answer. If you have the knowledge for how to preview an icon font, please share!!
You could use the Character Map tool in Windows. Just select the icon font and you can preview the entire list as well as the corresponding css codes.

Can Google Earth export kml files usable in the Google Earth Api?

Is it possible for me to go through and edit my virtual copy of the landscape being worked on and export that to kml, usable in the Google Earth API? In other words if I have my models, and color markings laid over the earth, can I share those certain addons through GE API (not allowing users to edit it).
Yes. There are a couple ways to do it.
In the left panel, right-click on the feature or features you want to capture in KML and select Copy. Then open your favorite editor and paste. You'll get the KML. You can save the KML to a file.
Another choice is to right-click on the feature and click "Save Place As...", which will let you save the file as a KML or KMZ.
Google hosts a tutorial.
Sure you can, but you will have to create an GE API instance.
We are coming up with a new product that will handle that.
Send me a note to jdelcid#3delcid.com if you are interested in knowing more about it and perhaps using it for your projects.
Best.
Jorge.

Organizing placemarks in Google Earth Plugin/KML

I am looking for some insight on if / how I can better approach creating my KML in order to make my data more readable when loaded by via a custom app developed around the Google Earth Plugin.
My constraints are:
I have no ability to do anything with the custom app or the plugin,
I can only provide KML files and take advantage of any features
built into the Google Earth Plugin.
The side bar where you select data to display does not list the folders of the selected KML as a sub menu like I have seen in Google Earth.
My data looks like:
Hundreds of Data points sometimes quite close together, which I am
currently displaying as placemarks, with no names set (was too noisy
on the map). I supply additional details on the placemark in the
description bubble / balloon.
Placemarks are frequently related to one another (i.e. there may be
4 placemarks representing a distinct group (e.g. coffee shops)).
What I have found so far:
There is no way for me to group pins as I zoom in and out without access to the JavaScript API / ability to do some amount of front end programming (i.e. there is no way to specify in the KML that pins should be grouped based on zoom level. I have noted the zoom level visibility settings which I do not believe accomplish what I am looking to do).
When clicking on a placemark there is no way to identify the other placemarks which are in the same group (i.e. all coffee shops) such as by changing their style (again note that to work for me this would have to be native functionality whose behaviour can be pre-specified in the KML). I hoped the plugin might provide some default functionality around this with folders, but I haven't been able to find anything.
My questions:
Are my above assumptions correct?
Are there some aspects of the KML spec and how it is displayed by google-earth which might be a good place for me to spend additional time understanding given the nature of my data?
Any suggestions or insight would be very welcome.
Edit: Also considered creating KML Tours to adjust visibility / identify related Placemarks, but could not see how I might start / stop the tour from a given Placemark (e.g. by clicking a link in the description balloon?).
Firstly, a question for you.
Are you wishing to load your 'app' on a mobile device? or are you just trying to do something on a normal computer?
I ask because you mention 'app' - yet in this line
I have no ability to do anything with the custom app or the plugin, I
can only provide KML files and take advantage of any features built
into the Google Earth Plugin.
The Google Earth PLUGIN is not support by mobile devices (yet) so if you can take advantage of it you must be talking about a normal computer scenario. So either a webpage, or a webpage embedded inside another program.
As for
There is no way for me to group pins as I zoom in and out without
access to the JavaScript API / ability to do some amount of front end
programming (i.e. there is no way to specify in the KML that pins
should be grouped based on zoom level. I have noted the zoom level
visibility settings which I do not believe accomplish what I am
looking to do).
Have you looked into using Regions ? With them you can control at what 'zoom' (ie what POV) a placemark becomes visible.
As for
When clicking on a placemark there is no way to identify the other
placemarks which are in the same group (i.e. all coffee shops) such as
by changing their style (again note that to work for me this would
have to be native functionality whose behaviour can be pre-specified
in the KML). I hoped the plugin might provide some default
functionality around this with folders, but I haven't been able to
find anything.
This depends of if you are really using the plug-in (and thus JS) or not. With straight KML I don't think anything is possible. However if you are using the plugin (and some JS) you have number of options depending on how you set up your .kml.
You can 'walk' through your kml file and find all placemarks with the same <style>
You can assign all your placemark id's by - and then using Accessors like this var placemark = ge.getElementById('unique_id');
However it sounds like you are not using JS so I am probably wasting time with this.
Same goes for using tours, IF you are using the plugin and IF you are willing to do some JS coding then YES you can use tours to all kinds of things.
However, if you are talking about a mobile device app, then nothing is possible (except the Regions) and I suggest you edit your question to remove the 'google-earth-plugin' tag.

How to: place link to another kml file within a placemark

I'm drawing the path of a ship sailing around the world, using a series of kml files, each containing multiple placemarks.
When I click on the last visible placemark, I DO NOT want to open a ballon containing text and a URL to the next file. Instead, I'd like GE to load and "flyto" the kml file that contains the next series of placemarks. So far, I haven't found a way to do this, so I'm wondering if it's possible. If so, how to? Thanks, John
I'm assuming you're using KML in Google Earth. KML doesn't have an "onclick" method for Placemarks like this, when you click on a placemark, it opens up a balloon if there is one to be opened. If you want something more guided, you can do a tour or you can open up a balloon that has a link with a ;flyto method added that takes you to a particular Placemark.

How do you alter the 'page_load' for DotNetNuke

For the main menu, I want the first four links to be blue, and specifically the last four links to be yellow. There will only be eight menu items.
I was thinking of hard coding the yellow links into the menu div, and that way when the page loads the first four menu items (default colour blue) they will be blue, and then my hard-coded links of yellow would load up.
My question is, where can I add the "yellow" code? Where can I hard code my yellow menu items? Or is there a different, better, approach to this?
My first question would be which men u are you implementing? A lot of them have a menuitem_x sort of id that is applied to the menu markup so with the CSS you can do what you want
As for where to place the markup there are a few places
You can do it directly in the skin files (not suggested since you may have to edit a few files)
in the skin .css files (much better place to do it and more maintainable and portable)
in the admin go to Site Settings and use the stylesheet editor to add the classes to the portal stylesheet (better than #1 but not as good as #2 since its now specific to the portal and not the skin so it wont be as portable)
Number 3 - works good if you dont have access to the skin or dont want to change it for other reasons
You could use Javascript within the skin.
We have done simular in the past for DNN menus but i keep away from the skinning side so dont have any examples, sorry.
Google does though :)
I would use one of the specific SEO friendly DNN menu modules that generate clean code that can be followed by search engines. I usually use one of them, except for projects where I don't have SEO concerns. When you have a menu with clean markup, like a list, you can change the colors using jQuery and specifying the first four items. You can probably do it like this, one by one. There may be a better selector for grabbing the first four items which is something I have never used.
Solved it, not as dynamic as I'd like, but it works.
The way I've done it is I'm playing with id tags, rather than class tags. Using ID, I can pick out the individual menu items and apply CSS to them.
Essentially, it looks like I've done what 'codemypantsoff' suggested. Thanks!

Resources