public IActionResult Short()
        {
            using (MySqlConnection connection = new MySqlConnection(HttpContext.ConfigurationManager.ApplicationDatabaseConnection))
            {
                connection.Open();
                using (var context = new Context(connection, false))
                {
                    AuthorizeAttribute authorize = new AuthorizeAttribute();
                    var user = authorize.AuthorizeAuthToken(HttpRequest, HttpContext.ConfigurationManager.ApplicationSecretKey);
                    if (user != null)
                    {
                        User = user;
                        HttpContext.Headers["Auth-Token"] = User.Token;
                    }

                    string shortUrl = Path.GetRandomFileName();
                    shortUrl = shortUrl.Replace(".", "");
                    shortUrl = HttpRequest.QueryParams["Host"] + "/app1/url/click/" + shortUrl;
                    int userId = 0;
                    if (User != null)
                    {
                        userId = context.Users
                                 .Where(b => b.Username == User.Username)
                                 .FirstOrDefault().Id;
                    }

                    var url = new UrlModel
                    {
                        Url     = HttpRequest.Parameters["url"],
                        Short   = shortUrl,
                        Created = DateTime.Now,
                        Deleted = false,
                        Clicks  = 0,
                        UserId  = userId
                    };
                    var pictureName = DateTime.Now.Subtract(DateTime.MinValue).TotalSeconds.ToString();
                    pictureName = pictureName.Replace(".", "");

                    // Linux

                    /*ProcessStartInfo startInfo = new ProcessStartInfo() { FileName = "/bin/bash", Arguments = "phantomjs screenshot.js " + HttpRequest.Parameters["url"] + " " + pictureName + ".jpg", };
                     * Process proc = new Process() { StartInfo = startInfo, };
                     * proc.Start();*/

                    //Windows
                    Process          p   = new Process();
                    ProcessStartInfo psi = new ProcessStartInfo();
                    psi.FileName        = "CMD.EXE";
                    psi.Arguments       = "/C C:\\phantomjs-2.1.1-windows\\bin\\phantomjs.exe C:\\Users\\dieguito12\\Code\\sharpener-framework\\src\\App1\\screenshot.js \"" + HttpRequest.Parameters["url"] + "\" C:\\Users\\dieguito12\\Code\\sharpener-framework\\src\\App1\\screenshots\\" + pictureName + ".jpg";
                    psi.CreateNoWindow  = true;
                    psi.UseShellExecute = false;
                    p.StartInfo         = psi;
                    p.Start();
                    p.WaitForExit();

                    context.Urls.Add(url);
                    context.SaveChanges();
                    NameValueCollection response = new NameValueCollection();
                    response.Add("urlId", url.Id.ToString());
                    response.Add("url", url.Url);
                    response.Add("shorUrl", url.Short);
                    response.Add("screenshot", HttpRequest.QueryParams["Host"] + "/app1/" + "screenshots/" + pictureName + ".jpg");
                    return(Json(Mvc.Json.Jsonify(response), 201));
                }
            }
        }