New to ruby, want to build that can do the following stuff

Hello,

I am pretty new to ruby and just started out with codeacademy(50% done).

I want to build a simple webapp/page that can do the following when a
user visits my site:

  1. If he is from a partucular country he should get redirected to one of
    the urls randomly set by me.
    a) if he uses andoird/ios/Windows then he should be redirected to
    apartical URL randomly from the URL’s set me by me.

first the app should be able to filter country then device NOT vice
versa.

is there any framework or anything that can help me acieve this?

btw this is just a basic overview of what I want to build.

Thanks for reading.

Yuvraj

If you want a web app you should finish the codecademy course and then
have a look at Rails.

You should be able to determine a user’s country by their IP and one of
the various APIs available for geolocation.

A quick bit of googling turned up this for mobile detection:
request.user_agent =~ /iPhone|iPad|Android/i

I see.

Thanks for the help Joel, I really appreciate it. :slight_smile:

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs