Table of Contents


EXPANDEDLINK Field Type

This field type is designed to help you link a bunch of existing pictures or documents to their respective features on a layer.  It does this by converting (or "expanding") the values from a certain field of your layer into complete URLs.  

The Problem
The following describes the most common scenario in which this field type is needed.
1. You have some Shapefile or other GIS file containing links to pictures for each record in the file.
2. The pictures are all stored in a folder on a local drive such as "D:\Pictures\FireHydrants"
3. Your GIS file has a column named "Hyperlink" and each record has a Hyperlink value of something like "D:\Pictures\FireHydrants\201711211644.jpg"
4. You import this GIS file into Diamond Maps but you don't see your pictures because Diamond Maps can't link to files stored on your local computer.

The Solution
5. You could add an ATTACH field to your layer and then procede to manually upload each picture one at a time assigning each to its respective feature, but that would be painfully slow and take forever.
6. So instead, you do a batch upload of all of your pictures to a cloud hosting service such as dropbox or a Diamond Maps FTP folder.  But the file names in your Hyperlink field are still referring to documents on the D: drive.
7. So you change your layer's Hyperlink field type from TEXT to EXPANDEDLINK.  And with a small amount of setup work, all of your Hyperlinks get automatically translated into fully qualified paths that link to their respective documents.


How To
Now that you know why, lets go into more detail on HOW you do steps 6 and 7 above.

Step 6 - Upload Files
6.1 In order for your pictures to be accessible by your users on their phones and computers, they have to be stored on the internet somewhere.  If you already have a favorite place to store these like dropbox.com, or your own website then go ahead and put them there.  If you don't, then just ask us and we can provide you with an FTP login that you can use to batch upload your pictures and store them on the Diamond Maps server.  There is no extra charge for hosting your pictures but we do charge extra for hosting video files.
6.2 For the remainder of these steps lets say that we created for you an FTP folder at the web address "http://diamondmaps.com/customerdocs/AbcWaterCo"
6.3 Within this FTP site you create a subfolder called "FireHydrants" and then you upload all of your pictures to this subfolder.
6.4 So an example file that used to be stored at D:\Pictures\FireHydrants\201711211644.jpg is now located on the web at http://diamondmaps.com/customerdocs/AbcWaterCo/FireHydrants/201711211644.jpg

Step 7 - Create Hyperlinks
7.1 In  Diamond Maps click Layers, then click Fire Hydrants, then click More, then click Add/Remove Fields.
7.2 Find your "Hyperlinks" field in the list and click the "chg" link next to it.
7.3 Change the field type from TEXT to EXPANDEDLINK
7.4 In the "Link Template" box type http://diamondmaps.com/customerdocs/AbcWaterCo/FireHydrants/[FILENAME]  
7.5 Note that you literally type "FILENAME" above.  Don't type the name of an actual file in its place.
7.6 Click OK and then click Apply Changes.  Your done!

To test your new hyperlink, click on one of your fire hydrants on your map and then click on the link in your hyperlink field.


Use [VALUE] in place of [FILENAME] to Make Use of Relative Paths (less common)
The use of the [FILENAME] tag in the above scenario assumes that all of the pictures (for your hydrant layer) are in the same folder.  The [FILENAME] tag ignores the "D:\Pictures\FireHydrants\" prefix on each of the file paths spelled out in your layer data, and inserts just the file name (ie. "201711211644.jpg") into the place of the [FILENAME] placeholder to create each link.  In most cases that will work just fine.  But in some cases you may need to preserve the full file path.  For example, lets say that you have two different folders storing your hydrant pictures based on the year they were taken.  One of your hydrant records links to "2012Pics\1234.jpg" and another hydrant on the same layer links to "2017Pics\5678.jpg".  The above steps would then be modified as follows:
Step 6.3 Upload both folders of pics to http://diamondmaps.com/customerdocs/AbcWaterCo/FireHydrants/2012Pics and http://diamondmaps.com/customerdocs/AbcWaterCo/FireHydrants/2017Pics
Step 7.4 Enter your "Link Template" as http://diamondmaps.com/customerdocs/AbcWaterCo/FireHydrants/[VALUE]