# Pass parameters to a Perspective session in Vision, either by opening the view in a browser - or passing them on in the Web browser module

**URL:** <https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004>\
**Category:** Ignition\
**Created:** [March 9, 2022, 8:46am UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004 "2022-03-09T08:46:17Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![SBL\_MC](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sbl_mc/32/56813_2.png) [@SBL\_MC](https://forum.inductiveautomation.com/u/SBL_MC)\
**Post date:** [March 9, 2022, 8:46am UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/1 "2022-03-09T08:46:17Z")

</div>

I have a project that is mainly based on Vision, and need to build a solution where the operator can upload images or files for their daily reports. Perspective supports this, but then I will need to pass on parameters as username, object name and description to the Perspective session.

I guess browser or web browser module both depend on the URL, and the URL only. Is it possible to somehow pass on parameters in the URL?

Like [http://url:8088/data/perspective/client/project/view?parameterA=1234](http://url:8088/data/perspective/client/project/view?parameterA=1234)

---

<div class="post-metadata">

**Author:** ![SBL\_MC](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sbl_mc/32/56813_2.png) [@SBL\_MC](https://forum.inductiveautomation.com/u/SBL_MC)\
**Post date:** [March 9, 2022, 9:55am UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/2 "2022-03-09T09:55:02Z")

</div>

Solution:

> [@Pass data from Vision to Perspective via Web Browser](https://forum.inductiveautomation.com/t/pass-data-from-vision-to-perspective-via-web-browser/35692/5):
>
> yes please!!

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [March 9, 2022, 1:18pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/3 "2022-03-09T13:18:14Z")

</div>

Or just use Vision’s `system.util.sendRequest()` function to send whatever you want to the gateway, perhaps?

(You are making this unnecessarily complicated.)

---

<div class="post-metadata">

**Author:** ![victordcq](https://avatars.discourse-cdn.com/v4/letter/v/f6c823/32.png) [@victordcq](https://forum.inductiveautomation.com/u/victordcq)\
**Post date:** [March 9, 2022, 1:28pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/4 "2022-03-09T13:28:12Z")

</div>

> [@SBL\_MC](#):
>
> operator can upload images or files

If the operator already has to leave the app to fetch the file/image it wants. It seems easier to let him just instantly drop it in a shared folder than going through the vision app. This will also make it way easier to edit those files again.

If the image or file does not directly come from the users filesystem, it should be handled by your code without having to go to perspective. Like pturmel suggested

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [March 9, 2022, 1:36pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/5 "2022-03-09T13:36:14Z")

</div>

> [@victordcq](#):
>
> It seems easier to let him just instantly drop it in a shared folder than going through the vision app.

You can run Vision apps on networks that don't have any file sharing, and using authentication totally separate from any file sharing. I would absolutely _ **not** _ use network shares.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [March 9, 2022, 1:40pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/6 "2022-03-09T13:40:42Z")

</div>

> [@victordcq](#):
>
> If the operator already has to leave the app to fetch the file/image it wants.

Oh, and Vision clients have full access to the local file system--no need to leave the client to access any file. Vision can also use multiple calls to `system.util.sendRequest()` to pass chunks of a file--enabling both progress bar displays and uploads of very large files.

---

<div class="post-metadata">

**Author:** ![SBL\_MC](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sbl_mc/32/56813_2.png) [@SBL\_MC](https://forum.inductiveautomation.com/u/SBL_MC)\
**Post date:** [March 9, 2022, 1:42pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/7 "2022-03-09T13:42:24Z")

</div>

The image is not passed with the url. Only user, object and description.

Was looking into doing it with message handlers, but I would need to check who sent the message and only update that computers session?

Changed the Page URL to /reports/:input and this binding to the Starting URL on the web browser component: “[http://10.13.37.6:8088/data/perspective/client/project/reports/](http://10.13.37.6:8088/data/perspective/client/project/reports/)”+{Root Container.db\_operator}+";"+{Root Container.object}+";"+{Root Container.description}  
In the Perspective view I split input into 3 parts and use it in different components.

The aim is that they can write reports and upload pictures both from the control room stations (Vision) by clicking on an report icon in each object template (and inherit the object name and description)

Also they should be able to use their smartphones (Perspective) when walking around in the plant.

All good so far, now I just have to find a way that the fileUpload and markdown to have a common path that works.

---

<div class="post-metadata">

**Author:** ![bkarabinchak.psi](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/bkarabinchak.psi/32/83567_2.png) [@bkarabinchak.psi](https://forum.inductiveautomation.com/u/bkarabinchak.psi)\
**Post date:** [March 9, 2022, 1:43pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/8 "2022-03-09T13:43:51Z")

</div>

So is the end goal that a operator can take a picture from their smart phone, open up the perspective app and then upload the picture they just took?

It’s always useful to say what the semantic end goal is because with Ignition there are usually 10 different ways to accomplish the same thing and so you might have an idea of what you think you want to do but there may be a built in way or an easier way to handle things.

---

<div class="post-metadata">

**Author:** ![victordcq](https://avatars.discourse-cdn.com/v4/letter/v/f6c823/32.png) [@victordcq](https://forum.inductiveautomation.com/u/victordcq)\
**Post date:** [March 9, 2022, 1:47pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/9 "2022-03-09T13:47:11Z")

</div>

> [@SBL\_MC](#):
>
> markdown

why do you want to use a markdown to display an image?

---

<div class="post-metadata">

**Author:** ![SBL\_MC](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sbl_mc/32/56813_2.png) [@SBL\_MC](https://forum.inductiveautomation.com/u/SBL_MC)\
**Post date:** [March 9, 2022, 1:49pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/10 "2022-03-09T13:49:33Z")

</div>

The files uploaded need to be available as images that could be inserted into the text.

The Vision popup, top 3 labels comes from the URL.

 ![dagb](https://us1.discourse-cdn.com/inductiveautomation/original/3X/9/a/9a4ef06bfb0e08211221adae8219bb3087ee4cb3.png)

---

<div class="post-metadata">

**Author:** ![SBL\_MC](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sbl_mc/32/56813_2.png) [@SBL\_MC](https://forum.inductiveautomation.com/u/SBL_MC)\
**Post date:** [March 9, 2022, 1:54pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/11 "2022-03-09T13:54:12Z")

</div>

Using the perspective app they also can use the camera.

 ![sp](https://us1.discourse-cdn.com/inductiveautomation/original/3X/7/e/7eb9afde277cfd6c88c79ed5fb0c07a44e6ea6db.jpeg)

Not very responsive, trying to get the flow going first. 🙂

---

<div class="post-metadata">

**Author:** ![victordcq](https://avatars.discourse-cdn.com/v4/letter/v/f6c823/32.png) [@victordcq](https://forum.inductiveautomation.com/u/victordcq)\
**Post date:** [March 9, 2022, 1:59pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/12 "2022-03-09T13:59:58Z")

</div>

well, you shouldn’t put any security/sestive info in the url, like the username seems not safe

you could access files in the markdown here  
`C:\Program Files\Inductive Automation\Ignition\webserver\webapps\main`

example for image located here named “mmm.jpg”  
`C:\Program Files\Inductive Automation\Ignition\webserver\webapps\main\mmm.jpg`  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/d/5/d5b502a76a7e67528157da434658a6fa1792f412.png)

However these might not update as often as you want…

---

<div class="post-metadata">

**Author:** ![SBL\_MC](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sbl_mc/32/56813_2.png) [@SBL\_MC](https://forum.inductiveautomation.com/u/SBL_MC)\
**Post date:** [March 9, 2022, 2:05pm UTC](https://forum.inductiveautomation.com/t/pass-parameters-to-a-perspective-session-in-vision-either-by-opening-the-view-in-a-browser-or-passing-them-on-in-the-web-browser-module/57004/13 "2022-03-09T14:05:17Z")

</div>

All of the operators log in as “op” anyway, that’s how they want it 🙄  
Getting the username in the url is mostly for the future, if they would accept using individual user names and passwords.

The server is not accessible from outside the process network, no internet access.

Thanks! I tried to include to much of the webapps folder structure…
