1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Help redirecting a page

Discussion in 'Web Design' started by udt89, Oct 6, 2015.

  1. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
    I have a mobile site that has a redirect to m.sitename.com for users when they are on a detected mobile device.

    The problem I have is this. Their location in google is found at www.sitename.com/locations/location-name/

    But if you click that link on your phone it brings you to m.sitename.com/locations/location-name which doesnt exist.

    How can i fix this? I tried editing the htaccess file in the main directory with no luck as well as the htaccess in the "m" folder.

    And I guess how can i make all the main site pages redirect to the correct m.sitename.com versions
     
    Last edited: Oct 6, 2015
  2. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
    anyone? really could use the help
     
  3. MrBlue

    MrBlue Senior Member

    Joined:
    Dec 18, 2009
    Messages:
    971
    Likes Received:
    680
    Occupation:
    Web/Bot Developer
    Instead of "m.sitename.com/locations/location-name" what are mobile users supposed to be redirected to?
     
  4. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
  5. Des_cartes

    Des_cartes Junior Member

    Joined:
    Jan 19, 2012
    Messages:
    160
    Likes Received:
    64
  6. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
    I want m.sitename.com/locations/location-name to go to m.sitename.com/locationname.html for each location
     
  7. Des_cartes

    Des_cartes Junior Member

    Joined:
    Jan 19, 2012
    Messages:
    160
    Likes Received:
    64
    Do you have multiple "locations" folders? is the "locationname.html" name file must be the same as the "location-name" in the desktop site?
     
  8. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
    no there is only one locations folder for the desktop site. There isnt a folder for the mobile site.

    the locationname.html is a mobile page in html (obviously) but the desktop page location-name is a wordpress page.

    Whats happening is, in Google, if you click a location that is listed under the listing in the results it is sending you to the desktop page but bc you are on your mobile device it is rewriting to m.sitename.com
     
  9. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
    I do appreciate the help. What you posted is close but I think maybe I need to add each specific location page and the corresponding html page in the M directory?
     
  10. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
    Did that info help any?
     
  11. irfan666

    irfan666 Newbie

    Joined:
    Oct 3, 2015
    Messages:
    10
    Likes Received:
    0
    You can also redirect domain from control panel
     
  12. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
    i dont want to redirect a domain....
     
  13. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
    still looking for some help
     
  14. roadhamster

    roadhamster Regular Member

    Joined:
    Mar 12, 2012
    Messages:
    335
    Likes Received:
    242
  15. udt89

    udt89 Regular Member

    Joined:
    Dec 22, 2009
    Messages:
    375
    Likes Received:
    98
    Location:
    New York
    still looking for a solution to this
     
  16. zotohost

    zotohost Registered Member

    Joined:
    Oct 25, 2015
    Messages:
    71
    Likes Received:
    4
    Sign up for cloudflare for free. They have custom redirect for mobile (google how to do it)