/
Client Actions URL Generator

Client Actions URL Generator

Provide a helper action to generate a URL to the current client including references to the current position and scale. The URL will be copied to clipboard and can easily be pasted into a document or another browser. Accessing the generated URL will open up a new client and set the initial position and scale to instructed by the URL.


The bundle can be downloaded here

ID

se.viamap.client.map.urlGenerator

Sub-Tags

NameTypeCardinalityDefaultDescription
urlstring0..1Browser urlThe url will be set automatically by the browser. This can optionally be overridden by setting a fixed url.
markerboolean0..1falseShould a marker be placed on the x,y position when the client is loaded.
showMessageboolean0..1trueShould a message pop up to confirm that the URL have been generated and copied to clipboard.
trackMouseboolean0..1false

Should the coordinates represent the current mouse position of the map. This is suitable if the action

is placed within the map context menu. By default coordinates represents the center of the map.


Example

<!-- Simple action with default settings  -->
<item action="weave.urlGenerator" />


<!-- Action with additional options  -->
<item action="weave.urlGenerator" >
	<url>https://localhost/weave/main.html</url>
	<marker>true</marker>
	<showMessage>false</showMessage>
	<trackMouse>true</trackMouse>
</item>


i18n resources

iddefault
map.urlGenerator.tooltip.titleCopy hyperlink to clipboard
map.urlGenerator.tooltip.textGenerates a hyperlink to this client with reference to current position and scale. The hyperlink will be copied to clipboard
map.urlGenerator.titleCopy hyperlink
map.urlGenerator.success.titleCopy success
map.urlGenerator.success.msgSuccessfully copied hyperlink to clipboard
map.urlGenerator.error.msgCould not copy hyperlink to clipboard
i18n resources
<?xml version="1.0" encoding="UTF-8"?>
<config xmlns="urn:com.cohga.server.config#1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:client="urn:com.cohga.html.client#1.0">

	<!-- Swedish -->
	<client:resources lang="sv">
		<resource id="map.urlGenerator.tooltip.title"><![CDATA[Kopiera hyperlänk som urklipp]]></resource> 
		<resource id="map.urlGenerator.tooltip.text"><![CDATA[Generera en hyperlänk till klienten med referens till nuvarande position. Hyperlänken kopieras som ett urklipp]]></resource> 
		<resource id="map.urlGenerator.title"><![CDATA[Kopiera hyperlänk]]></resource> 
		<resource id="map.urlGenerator.success.title"><![CDATA[Kopieringen lyckades]]></resource> 
		<resource id="map.urlGenerator.success.msg"><![CDATA[Kopierade hyperlänk till urklipp]]></resource> 
		<resource id="map.urlGenerator.error.msg"><![CDATA[Kunde inte kopiera hyperlänk]]></resource> 
	</client:resources> 


	<!-- Norwegian-->
	<client:resources lang="no">
		<resource id="map.urlGenerator.tooltip.title"><![CDATA[Kopier hyperkobling til utklippstavlen]]></resource> 
		<resource id="map.urlGenerator.tooltip.text"><![CDATA[Generere en hyperkobling til klienten med referanse til den aktuelle posisjonen. Den hyperkobling er kopiert til utklippstavlen]]></resource> 
		<resource id="map.urlGenerator.title"><![CDATA[Kopiere hyperlink]]></resource> 
		<resource id="map.urlGenerator.success.title"><![CDATA[Kopiering lyktes]]></resource> 
		<resource id="map.urlGenerator.success.msg"><![CDATA[Kopiert hyperkobling til utklippstavlen]]></resource> 
		<resource id="map.urlGenerator.error.msg"><![CDATA[Kunne ikke kopiere hyperlink]]></resource> 
	</client:resources> 



</config>