# Read pathname as a Variable

**URL:** <https://community.glideapps.com/t/read-pathname-as-a-variable/34809>\
**Category:** Ask for Help\
**Created:** [November 20, 2021, 11:40am UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809 "2021-11-20T11:40:07Z")\
**Posts on this page:** 15\
**Page:** 1

<div class="post-metadata">

**Author:** ![arosauro](https://avatars.discourse-cdn.com/v4/letter/a/dc4da7/32.png) [@arosauro](https://community.glideapps.com/u/arosauro)\
**Post date:** [November 20, 2021, 11:40am UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/1 "2021-11-20T11:40:08Z")

</div>

Hi there,

I’d like to use the **pathname** as a variable in my app

For instance.:  
[https://myglideapp.com/\*\*option-1](https://myglideapp.com/**option-1)\*\*  
[https://myglideapp.com/\*\*option-2](https://myglideapp.com/**option-2)\*\*

We have two options here.:  
/option-1  
/option-2

So that, when I send the **link** to a customer, my app opens with the “selected” option.  
Is it possible? Any Idea?

Tks, Augusto.

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [November 20, 2021, 11:49am UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/2 "2021-11-20T11:49:02Z")

</div>

The closest thing we have to that is Deep Links.

> **[Deep Links](https://docs.glideapps.com/all/reference/design-and-structure/deep-links)**
>
> Link to different screens in your app with URLs

---

<div class="post-metadata">

**Author:** ![arosauro](https://avatars.discourse-cdn.com/v4/letter/a/dc4da7/32.png) [@arosauro](https://community.glideapps.com/u/arosauro)\
**Post date:** [November 20, 2021, 12:35pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/3 "2021-11-20T12:35:48Z")

</div>

Tks Darren, but not what I need…

I’d like to choose an option before by the link I send to a customer…  
Any further Idea? That’s comon behavior in HTML…

Augusto

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [November 20, 2021, 12:37pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/4 "2021-11-20T12:37:59Z")

</div>

So sort of like a prefilled link? That’s not possible.

---

<div class="post-metadata">

**Author:** ![arosauro](https://avatars.discourse-cdn.com/v4/letter/a/dc4da7/32.png) [@arosauro](https://community.glideapps.com/u/arosauro)\
**Post date:** [November 20, 2021, 12:44pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/5 "2021-11-20T12:44:48Z")

</div>

Is there a way by using the data editor… ?

![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/6/6/6631f43a1bde087b15bcda2e7f26eaae13f75812.png)

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [November 20, 2021, 2:21pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/6 "2021-11-20T14:21:33Z")

</div>

No, that’s extracting a part of the URL that you input into the column.

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [November 20, 2021, 2:25pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/7 "2021-11-20T14:25:18Z")

</div>

Maybe this…

> [@Deep link and domain server redirect](https://community.glideapps.com/t/deep-link-and-domain-server-redirect/34243):
>
> Hi Gliders, I’m trying to have nice and short URLs for customers which directly leads them to their individual profile screen in the app. Through a rewrite rule in the .htaccess file on my subdomain [go.mydomain.com](http://go.mydomain.com) I want to redirect to the deep link URL and hence to the correct screen. If I’m using the deep link URL right in the browser it works and the correct screen is shown. If I’m redirecting this same URL through the server redirect, the browser first loads the correct URL but then the …

---

<div class="post-metadata">

**Author:** ![Robert\_Petitto](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/robert_petitto/32/25193_2.png) [@Robert\_Petitto](https://community.glideapps.com/u/Robert_Petitto)\
**Post date:** [November 20, 2021, 2:25pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/8 "2021-11-20T14:25:31Z")

</div>

Ya… glide doesn’t have a way to pre fill forms or fields from url parameters. That would be nice, though!

---

<div class="post-metadata">

**Author:** ![christoph](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/christoph/32/22794_2.png) [@christoph](https://community.glideapps.com/u/christoph)\
**Post date:** [November 20, 2021, 2:56pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/9 "2021-11-20T14:56:48Z")

</div>

I’m not sure how I can repost it, or do you mean copy and paste into a new post?

---

<div class="post-metadata">

**Author:** ![Darren\_Murphy](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/darren_murphy/32/47326_2.png) [@Darren\_Murphy](https://community.glideapps.com/u/Darren_Murphy)\
**Post date:** [November 20, 2021, 2:58pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/10 "2021-11-20T14:58:11Z")

</div>

Sorry, my mistake. I thought you had posted it in #regulars, but then I double-checked and realised that you’d posted in #help-how-to

So just ignore me 🙂

---

<div class="post-metadata">

**Author:** ![arosauro](https://avatars.discourse-cdn.com/v4/letter/a/dc4da7/32.png) [@arosauro](https://community.glideapps.com/u/arosauro)\
**Post date:** [November 20, 2021, 3:06pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/11 "2021-11-20T15:06:00Z")

</div>

Many uses for a functionality like that…

[https://myglideapp.com/](https://myglideapp.com/) **menu.restaurant\_1**  
[https://myglideapp.com/](https://myglideapp.com/) **menu.restaurant\_2**

Any workarround?

---

<div class="post-metadata">

**Author:** ![arosauro](https://avatars.discourse-cdn.com/v4/letter/a/dc4da7/32.png) [@arosauro](https://community.glideapps.com/u/arosauro)\
**Post date:** [November 20, 2021, 9:16pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/12 "2021-11-20T21:16:52Z")

</div>

Well… well… well… :))

Deep Links works fine in “Detail Screens”, as I could understood…  
Brings me a “Giant Link”, but… works…

I’ve made a small video for those who are having difficulties…  
You have to pick up the link inside Glide, for a specific “Detail Page”, and then use it… Other insights are appreciatted !!!

---

<div class="post-metadata">

**Author:** ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)\
**Post date:** [November 20, 2021, 11:41pm UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/13 "2021-11-20T23:41:44Z")

</div>

Yes, you can grab the deep link either using the action like you did or the URL bar of the browser. It does not solve your “prefill” problem though.

---

<div class="post-metadata">

**Author:** ![arosauro](https://avatars.discourse-cdn.com/v4/letter/a/dc4da7/32.png) [@arosauro](https://community.glideapps.com/u/arosauro)\
**Post date:** [November 21, 2021, 1:33am UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/14 "2021-11-21T01:33:39Z")

</div>

That is a big lack in Glide… but the sofware is really good… very easy to work whith…

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/system/32/53398_2.png) [@system](https://community.glideapps.com/u/system)\
**Post date:** [November 22, 2021, 1:34am UTC](https://community.glideapps.com/t/read-pathname-as-a-variable/34809/15 "2021-11-22T01:34:16Z")

</div>

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.
