Please Help With Dynamic URL/Page Issue

3 replies
I have a bunch of dynamic pages that grab data from my website database. The pages are using an "echo" to create the meta title for each page. I have a weird duplicate page problem, im able to remove or add anything to the url and it modifies the meta titles and the title on the page that is echoed from database.

For example: mysite.com/pricestates?id=0&country=Canada

I get and exact duplicate of the page using: mysite.com/pricestates?id=0&country=ANYTHINGGGGGG
and even this will be the same page: mysite.com/pricestates?id=0&country

How can i keep it the original and get a 404 page not found for anything else?
#dynamic #issue #url or page
  • Profile picture of the author chrisranjana.com
    Originally Posted by webmonopoly View Post

    For example: mysite.com/pricestates?id=0&country=Canada

    I get and exact duplicate of the page using: mysite.com/pricestates?id=0&country=ANYTHINGGGGGG
    and even this will be the same page: mysite.com/pricestates?id=0&country

    How can i keep it the original and get a 404 page not found for anything else?
    Wouldn't it be better to modify the script so that some kind of error message appears for invalid countries ?
    Signature

    Chris, Developer, Chrisranjana.com,
    AWS Developer GCP Engineer Python NodeJS Programmer

    {{ DiscussionBoard.errors[7871821].message }}
    • Profile picture of the author webmonopoly
      Originally Posted by chrisranjana.com View Post

      Wouldn't it be better to modify the script so that some kind of error message appears for invalid countries ?
      excellent idea lol, im not a coder/designer so i wouldn't know how but i will pass this on to my guy. Thanks
      Signature
      Want To Make Real Passive Income? InvestorChamp.com
      {{ DiscussionBoard.errors[7871830].message }}
      • Profile picture of the author kevintb7
        Whoa, Hold the phone. It sounds like your developer is not sanitizing the input from that url, make sure he is or that is a huge security loophole and could open up your whole database to attack via SQL Injection....If you want PM me the url and I can try to break in.
        {{ DiscussionBoard.errors[7876007].message }}

Trending Topics