Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8968789
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T17:30:11+00:00 2026-06-15T17:30:11+00:00

Possible Duplicate: How to identify if referrer is a 301 redirect Using htaccess Im

  • 0

Possible Duplicate:
How to identify if referrer is a 301 redirect

Using htaccess Im doing a 301 redirect to redirect old urls to the new urls, the issue is the url contains the id that is stored in the db. But I have a new db with new ids so now when the old url redirects to the new url a different record loads on the page. So what I did was store the old ids along with the new ids so I know what old id belongs to the new id. However how can I detect someone is trying to access the old url? Is there a way in php to detect the person coming to the page is being redirected via a 301? I dont want to add anything new to the url due to SEO reasons so I really need to know if I can detect if they came to this page via 301 redirect. Hope this makes sense.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T17:30:11+00:00Added an answer on June 15, 2026 at 5:30 pm

    Add another parameter to the redirect like redirect=true, check the param to let your app know it was a redirect, start the session, and then redirect again to the final, unaltered url, compare the session to know, that a user came from the redirected url.

    Or do what Salman says, use a canonical url.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Possible Duplicate: How do I make a request using HTTP basic authentication with PHP
Possible Duplicate: Python : how to append new elements in a list of list?
Possible Duplicate: Identify whether the selected text in a web page is bold nor
Possible Duplicate: How would I identify if a website originates from a mobile browser?
Possible Duplicate: Identify all objects of given class for further processing I want to
Possible Duplicate: fgetc does not identify EOF fgetc, checking EOF I have created a
Possible Duplicate: In javascript how can we identify whether an object is a Hash
Possible Duplicate: Method Syntax in Objective C I'm quite new to iPhone development and
Possible Duplicate: Probability of SHA1 collisions Let's say I'm trying to identify duplicate files
Possible Duplicate: Generate random number with non-uniform density I try to identify/create a function

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.