Web Forms :: Ip's Per Country Counter / Ip For Website Visitor?
Apr 16, 2010how could i know the count for my website visitors/ Countries? how can i know the ip for my website visitor?
View 3 Replieshow could i know the count for my website visitors/ Countries? how can i know the ip for my website visitor?
View 3 RepliesMy code:
protected void Page_Load(object sender, EventArgs e)
{
String userHost = Request.UserHostName
}
This is fetching the IP address alright, but now I want to know the country of the visitor and USE that country name to redirect the visitor to some webpage accordingly.
I came across this library but have no clue how to use it in the project. Actually I do, but I am not sure so I am asking.
http://ipaddressextensions.codeplex.com/
When I download from the above the ZIP folder has a DLL file and an XML file. Now, what do I do with these two? Like include in the project. Then what do I type in the code file?
Something like the following.
if (countryName=="France")
{
response.redirect("www.mysite.fr") [code]....
How do I go about it? Also do I really need to type SO many if blocks for ALL the countries. How do I shorten this code?
I know google analytics can do it,but i need to store each user data on my own database - for various advanced reasons and want to manipulate it. Here are my series of questions
1)How do i calculate time (when the visitor visits the website the timer should start....and when the visitor closes the page on my ASP.NEt Website timer should stop...so collecting his timespan to visit the website(when the visitor closes the page how should i make timer stop....and make an entry of his visit into the database....tricky...but i know there is a way out but how???).
2) I neede to know from which country the user came from...I know to collect the IP address but how could we find out which country the user came from..???
3)the next thing i need to know is..I want to display reports on my ASP.NEt Website of all visitor information,country,date time he visited and which technology i can use...crystal reports will be fine for me...or should any other.
4) i need to make it look like google analytics and make it super fast ...so my website visitors shouldnt wait too long..
anyone implemented hit counter?i don't want to count the page when it refresh as the website viewed it must be count and not when refresh!and also i know to save using gloabal.asax and save to text file but it save as 1,11,111 etc but when reset again it start from 0,anybody implemented pl post codings
View 1 RepliesI was wounder how to display how many has saw an image in my gallery website ?
View 1 RepliesI would like to hide a flag in some country. How can I do that easily?
View 3 RepliesI'm facing with an old problem that it made me confuse very much. So I need your advice to make sure that I've been using the right way. My demand is to count the number of visitor in my website, so I've coded in Global.asax file:
[Code]....
Then, I used variable Application["SiteHitCounter"] and Application[CurrentUsers"] in another C# behind code file to show them on web page.The problem I'm facing is that the website can't show right total visitor number as in my database when I publish it to shared host.
I have an ASP.net/VB.net website, and I currently capture the visitor's IP address with the following code:
IPAddr = Page.Request.ServerVariables("HTTP_X_FORWARDED_FOR").
Does anyone know the corresponding code that can capture (1) the visitor's name (ID) and (2) location?
Note: I am trying to capture the true information from the visitor's computer, not false (proxy) information. As an example, the code:
"Page.Request.ServerVariables("REMOTE_ADDR")" produces a false (proxy) IP address.
I need to implement the website visitor count Usercontrol.
View 3 Replieshow to calculate the time the visitor has been on the website?
View 3 RepliesI want to display all the user's name who is login to my websites..
So I can see them who is online.
i have one dropdownlist in the gridview. i have to load that dropdownlist when that page is loaded. dropdownlist should contain the country list from country table
View 7 RepliesIn My project I have DoupDownList(ddl). In my ddl in need to bind country names along With Country Flag..So Can Any One Help Me In thi issue...Country Name And Country Flag Bouth i need to Bind in my ddl
View 5 RepliesI would like to develop a web application in which I can track the details(IP address...etc) of my website visitors....using vb
to implement the above web application
I want populate the dropdownlist1 with Country and dropdownlist2 with City of that Country from web
Is there a place on web where we can get a list of countries and cities handy, and then populate into our dropdownlists in ASP.net page.
I tried to add the filp Counter To My WebSite To Count The Number Of Visitors Using (Css,Jquery,Js)...
This Is The Link Of Tutorial [URL] ....
I want to data bind jQuery Counter just like we do to Ajax Counter. Also I would like to know that do we have events for jQuery counter just like we have a tick event in Ajax Counter?
View 9 RepliesThis should be pretty simple but I don't work on my website code too often so I thought I would ask about this. I have a download link for an application of mine on my website and I wanted to keep track of how many downloads are taking place so I want to create a counter. I added a table to the SQL database I already have on my website with the columns Downloads and CountID which is listed in the column properties as identity specification. At first I just had the column Downloads but when doing a query I was having problems so I added CountID and that made the query easy to do.
When the link on the download page on my website is clicked I wanted Downloads to increment by 1 each time. I used Visual Web Developer to build my site. Should I use a Web Method to increment that or is there a more direct method. I also noticed when I'm working in Visual Web Developer and I have the designer open for a webpage that in the toolbox items you have table and the icon looks the same as a table for an SQL Database. Should I perhaps use that? Add a table to this webpage and work with that?
I have a count on my website that shows the amount of visits it gets. What i want to do now is represent the number with images.
I already have the images [0-9] in a folder path : Images/digits/[0-9].gif
I have been searching on the internet for possible solutions to my problem. and found this web site: [URL] .... but have tried a million times to implement it in my website but failed...
i am displaying various countries names in my dropdownlist and i want to display the data using gridview like whenever i change the country in my ddl it should display the relevant data according to the country??below is my code but i am unable to see any data whenever i change the country in my ddl gridview is not appearing??
[Code]....
I'm trying to write an application that allows a visitor to use our service for 7 days. After 7 days, they will no longer be able to use it unless they sign up. What's the best way and the most accurate way to track it without collecting their credit card information? I'm trying to use the following code to track visiotr's ip. But I'm not sure if people are able to change their ip address or using a proxy server that will go through.
HttpContext.Current.Request.ServerVariables["REMOTE_ADDR"]
I have a HTML webpage and I want to display the I.P address of last 5 visitors who visited the webpage.
I want to display these five I.P address on the webpage itself.
i have get the piece of code from www.aspsbippets.com
protected void ExportToWord(object sender, EventArgs e)
{
//Get the data from database into datatable
string strQuery = "select CustomerID, ContactName, City, PostalCode" +
" from customers";
SqlCommand cmd = new SqlCommand(strQuery);
DataTable dt = GetData(cmd);
//Create a dummy GridView
GridView GridView1 = new GridView();
GridView1.AllowPaging = false;
GridView1.DataSource = dt;
GridView1.DataBind();
Response.Clear();
Response.Buffer = true;
Response.AddHeader("content-disposition",
"attachment;filename=DataTable.doc");
Response.Charset = "";
Response.ContentType = "application/vnd.ms-word ";
StringWriter sw = new StringWriter();
HtmlTextWriter hw = new HtmlTextWriter(sw);
GridView1.RenderControl(hw);
Response.Output.Write(sw.ToString());
Response.Flush();
Response.End();
}
this code create word documnet and automatically downloaded to visitor machine, how i can save it on server rather than visitor machine?
I am bit of a newbie but..... I am trying to DIM a counter in my VB code, add to it and then, at the end of my filling a form, I want to take the counter and put it in a label or something on the form. In other words, I want to count the rows and display them on my form. It will not let me take the counter and put it in the label even if I convert it to a string. I know is probably very simple, but how do I do this.
View 7 RepliesI have a special banner that will download an .exe file that is located in: "Files1/Setup.exe".
Now I do not have any click event for this banner which makes it impossible to write code that count the clicks on this banner to a .txt file.
I wonder how this can be possible to do?, for example is it possible to detect when this URL is requested in somehow and count this to a .txt file?
URL: [URL]