Author Topic: Website development and design troubleshooting/ question  (Read 34921 times)

Offline whYME

  • Dansdeals Presidential Platinum Elite
  • ********
  • Join Date: May 2008
  • Posts: 3216
  • Total likes: 1229
  • DansDeals.com Hat Tips 3
  • Gender: Male
    • View Profile
Re: Website development and design troubleshooting/ question
« Reply #200 on: January 28, 2022, 10:09:29 AM »
Can anyone help with a Wordpress question?

I uploaded a pdf and set the slug/permalink. I would like to be able to upload a new file and keep the same url. Visiting the permalink works, however, when clicked it redirects to where the file is stored - mywebsite.com/wp-content/uploads/filename.pdf. Is there a way to have it show the permalink in the url, so that if someone bookmarks the page and then comes back later they will see the updated file?

TIA
Seems to me your question is can you make the slug/permalink be a rewrite rather than a redirect?

(I don't really know wordpress so don't know the answer.)

Offline etech0

  • Dansdeals Lifetime 10K Presidential Platinum Elite
  • *******
  • Join Date: Dec 2013
  • Posts: 12418
  • Total likes: 2480
  • DansDeals.com Hat Tips 1
    • View Profile
  • Location: not lakewood
  • Programs: DDF
Re: Website development and design troubleshooting/ question
« Reply #201 on: January 28, 2022, 10:13:16 AM »
Seems to me your question is can you make the slug/permalink be a rewrite rather than a redirect?

(I don't really know wordpress so don't know the answer.)
Unsure, I use a plugin called Redirection which allows redirects and passthroughs (where it shows the url you choose but the page at the target url). It works really nicely but it doesn't allow passthroughs for pdf files.
Workflowy. You won't know what you're missing until you try it.

Offline whYME

  • Dansdeals Presidential Platinum Elite
  • ********
  • Join Date: May 2008
  • Posts: 3216
  • Total likes: 1229
  • DansDeals.com Hat Tips 3
  • Gender: Male
    • View Profile
Re: Website development and design troubleshooting/ question
« Reply #202 on: January 28, 2022, 10:36:33 AM »
Unsure, I use a plugin called Redirection which allows redirects and passthroughs (where it shows the url you choose but the page at the target url). It works really nicely but it doesn't allow passthroughs for pdf files.
Ok so "passthrough" is their name for rewrite.

It's not just "showing" the target url with a redirect, it's actually going to that page instead. The rewrite engine is basically sending back a message "go find this content at <TARGET_URL>" and the browser then requests that other page.

With a rewrite, the rewrite engine basically tells the server "instead of <SLUG_URL> give me the page <TARGET_URL>" and then passes it back to the browser as <SLUG_URL>

Offline etech0

  • Dansdeals Lifetime 10K Presidential Platinum Elite
  • *******
  • Join Date: Dec 2013
  • Posts: 12418
  • Total likes: 2480
  • DansDeals.com Hat Tips 1
    • View Profile
  • Location: not lakewood
  • Programs: DDF
Re: Website development and design troubleshooting/ question
« Reply #203 on: January 28, 2022, 10:49:40 AM »
Ok so "passthrough" is their name for rewrite.

It's not just "showing" the target url with a redirect, it's actually going to that page instead. The rewrite engine is basically sending back a message "go find this content at <TARGET_URL>" and the browser then requests that other page.

With a rewrite, the rewrite engine basically tells the server "instead of <SLUG_URL> give me the page <TARGET_URL>" and then passes it back to the browser as <SLUG_URL>
Interesting!
And here's info about the plugin I use https://redirection.me/support/redirect-actions/
Workflowy. You won't know what you're missing until you try it.

Offline whYME

  • Dansdeals Presidential Platinum Elite
  • ********
  • Join Date: May 2008
  • Posts: 3216
  • Total likes: 1229
  • DansDeals.com Hat Tips 3
  • Gender: Male
    • View Profile
Re: Website development and design troubleshooting/ question
« Reply #204 on: January 28, 2022, 11:05:39 AM »
The rewrite engine is basically sending back a message "go find this content at <TARGET_URL>" and the browser then requests that other page.
I forgot to say, if it is a redirect, make sure it's a 302 (temporary) not 301 (permanent) redirect. Otherwise, once someone visits the slug link they'll have it cached in the browser and even after you change the target the browser might go straight to the old target link without even querying the slug link first.

Offline etech0

  • Dansdeals Lifetime 10K Presidential Platinum Elite
  • *******
  • Join Date: Dec 2013
  • Posts: 12418
  • Total likes: 2480
  • DansDeals.com Hat Tips 1
    • View Profile
  • Location: not lakewood
  • Programs: DDF
Re: Website development and design troubleshooting/ question
« Reply #205 on: January 28, 2022, 11:07:45 AM »
I forgot to say, if it is a redirect, make sure it's a 302 (temporary) not 301 (permanent) redirect. Otherwise, once someone visits the slug link they'll have it cached in the browser and even after you change the target the browser might go straight to the old target link without even querying the slug link first.
Ah, it has options for that but I never knew what it meant. Thanks!
Workflowy. You won't know what you're missing until you try it.