Pop Up UI in the browser

Hey,

I have a couple of AMI’s i would like to feed user input trough,

my hope was to have this as part of the shotgun web UI

Something like this (taken from the edit selected cmd)

A couple of input fields and check boxes, nothing too outrages.
what ever settings is set should ideally be passed through a
Custom protocol handler, to our own tools.

I’m having a hard time finding this,
maybe its already in the documentation and i am just not seeing it?

-Esben

4 Likes

Hi Esben

You can’t unfortunately, build a custom UI natively in Shotgun, but you could make AMIs modal overlay:


That displays an iframe that you could load a URL with your own UI in.
Maybe that would work for you?

Thanks
Phil

1 Like

Hey philip,

Thanks for the reply, I will try and make that work.

1 Like

Hey again,

So if i don’t have Modal overlay enabled,
Using a html on our locally hosted server that also hosts our wordpress blog.
it opens a new window in the browser, so far so good.

The second i enable modal overlay it does one of two things:

if its a http it still just opens a new browser window that’s runs the html.
if its a https it opens a frame within the correct window with nothing in it.

I have tried simple code like adding one button or changing the bg to pink but the pop up is always a white empty box.

now i am NOT a web developer, my expertise lies squarely within Python so i might be missing something really obvious.

Does the modal overlay require anything specific to function?

Hi Esben

I’m not expert on Shotgun AMI’s my self, so I’ll see if I can get someone else to take a look for you later today.

However, one thing I do know is it would need to be an https address, in order for it to work.

I guess another question I have is, are you able to load your page and have it display correctly independently without the Shotgun AMI part?

Best
Phil

yes,
if i access the page directly as a address
or run it without the modal overlay check box it works.

1 Like

Hi Esben,

Like Phil mentined, you’ll need to use https. Alongside the https address, you’ll also need an SSL certificate. You can generate your own for testing or you can use a site like letsencrypt.com to generate one for something you’re planning to use in production.

Here’s a bit of code that I wrote a while back that should help you get a barebones Python Flask web server up and running as an AMI:

With that up and running, you should be able to point your AMI at https://127.0.0.1:5000 and see Shotgun’s payload get dumped out to your modal.

2 Likes