Home Backend Development PHP Tutorial How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

Jul 13, 2016 am 10:18 AM
page time and how yes site calculate page

How to calculate the time on site and the time on page, calculate the time on siteto calculate the time on site and the time on page, calculate the time on site_PHP tutorial>

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

Time on Site (hereinafter referred to as Ts) and Time on Page (hereinafter referred to as Tp) are important indicators for user experience analysis and traffic quality monitoring. But few people know how the average time on site (Average Time on Site) is calculated. Whether you use a competitive intelligence analysis tool or some kind of website analysis solution (in the website analysis solution, whether it is WebLog or JavaScript tag data, few people know how to calculate the average website visit time).

Therefore, the purpose of writing this article is to explain clearly how Tp and Ts are calculated.

Case How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial:

Someone visits your website homepage, and your website analysis tool starts counting How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial Session for this visitor. The visitor then browses two more pages and then leaves your site (leaving the site can be by closing the browser, typing a different URL in the address bar, or clicking on a link on your site to another site) Link...) For the sake of simplicity, we treat this process as a Session.

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

Here’s what we want to know:

Tp = Time spent on a page (Time spent on a page);

Ts = the total time the user spent on the entire website (Time spent on the website).

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

Assume this session starts at How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial:00:

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

Currently, all website analysis tools can accurately know the time when a page access request occurs, but this is not enough to explain how many Tp and Ts there are, because we need more information:

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

The user did not bounce, and clicked a link on the homepage to jump to page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. The current website analysis tool can also obtain the opening time of page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial, and it can know that it is the same user, so it can be easily calculated Tp from the home page:

Tp(Home) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial:0How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial – How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial:00 = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes.

Some content on page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial attracted the user, so the user continued to visit page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

Look from the picture above:

Tp(page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial:How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial0 – How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial:0How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes.

The user exits from page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial, ending the session:

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

So, how long did this user stay on page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial? The problem arises because all current website analysis tools do not capture the "time stamp" when the user leaves page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial, so we cannot calculate how long the user stayed on page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial! Therefore:

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = 0 minutes.

Because the request time of the next page cannot be provided! Web analytics tools don't know how long a user spent on the last page of a session. This is true for most web analytics tools.

Let us use the following figure to represent the dwell time of each page website analysis tool statistics:

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

Tp (Home) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = 0 minutes

So, how long does this Session stay on the entire website?

Ts = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial0 minutes

Is it reasonable?

I think it may not be reasonable, because you don’t know how much time the visitor spent on the last page, so the time statistics given by the website analysis tool will generally be less than the actual time the user stays on the website.

Case How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial:

How are Time on Site and Time on Page calculated when browsing the website with a multi-Tab browser?

Firefox's multi-tab page browsing method has earned it a reputation, but it has caused trouble when it comes to calculating Time on Page and Time on Site. When a user opens a link to the same website in another tab, that is, browses the same website through two tabs at the same time, how will Time on Page and Time on Site be calculated?

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

This situation confuses the calculation of time by website analysis tools.

The picture below is a common user browsing website scenario. Through this scenario, we can understand the impact of multi-tab page browsing...

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

  • A user comes to the homepage in the picture above, and then opens a link on this page in a new tab. At this time, the homepage occupies one tab page, and the newly opened page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial after clicking the link occupies another tab page. .
  • At this time, the user does not close page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial after browsing page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial, and returns to the home page using Tab to continue browsing the home page.
  • While browsing the homepage, the user clicked another link on the homepage and jumped to page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial, but no new tab was opened. The current tab page was opened.
  • Then, the user switches to the tab where page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial is located, clicks the link to enter page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial, and closes the current tab on page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial.
  • Then, the user clicks the link on page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial to go to page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. Of course, it is still the same tab. Finally, close the tab on page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial and the session ends.

How to calculate Time on Site in this case? Different website analysis tools have two calculation methods for this "multi-tab type" browsing behavior.

Method How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial:

The website analysis tool records the above multi-Tab browsing situation one by one according to different tabs, that is, the following calculation occurs:

Statistical result output: How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial access processes (i.e. How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial Sessions), each Session corresponds to a Tab.

SessionHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial (Tab where the homepage is located in the picture above):

Tp (Home) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = 0 minutes

Ts (the entire visit duration of the same Tab) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial0 minutes

SessionHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial (Tab where page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial is located in the picture above):

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = 0 minutes

Ts (the entire access time of the newly opened Tab) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

In this case: How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial Sessions and How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial UV (Unique Visitor) will be recorded in the report of the website analysis tool.

Method How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial:

Some website analysis tools will merge multiple tabs into the same access process to eliminate the impact of multiple tabs (tab pages).

It’s still the same example as above, but let’s change the presentation method - the picture below shows the same process, and different colors represent different Tabs.

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

Statistical result output: How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial access process (i.e. How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial Session), which contains two Tabs. The entire access process is reorganized as shown above through "time stamps".

This Session:

Tp (Home) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minute

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = 0 minutes

Ts = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial0 minutes

Which statistical method do you think is more reasonable, and which method do you prefer?

Please be sure to ask your website analysis service provider which of the above two methods they use to calculate the time and access process of multi-Tab (tab page) browsing.

More and more people are now using multi-tab browsing, so which method you choose will have a huge impact on the final data output of your website analysis - there is no doubt that the final data of the two methods will definitely There will be obvious differences.

Solution:

Get the page (Tab) closing time (The page can be closed by closing the browser or Tab page, or typing a different URL in the address bar, or clicking on a link to another website on your website link...)

The latest user experience visual analysis tool "Bang Analysis" independently developed by Tribe State (Beijing) Technology Co., Ltd. obtains the page closing time. By calculating the time difference between page opening and closing, you can easily and accurately obtain the page stay. time and session time.

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

This Session:

Tp (Home) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minute

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Tp (page How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial) = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

Ts = How to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial minutes

The time on page is accurately obtained, but how significant is it? We will discuss it in detail in the next article, so stay tuned!

Reprinted from: http://www.bangfx.com/research/?p=How to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial

Calculate the time spent on a certain web pageto calculate the time on site and the time on page, calculate the time on site_PHP tutorial>

Use js code to write two functions. One is called when the web page is loaded. Make a timer in this function to get the current system time. Call it when the web page exits. Then stop the timer in the function that exits the web page. Then do a time calculation and subtract the time when the web page is loaded from the time when it stops to calculate the time the web page stays

How to effectively increase the time on page?to calculate the time on site and the time on page, calculate the time on site_PHP tutorial>

How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. Study the three functions of residence time:
How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. The longer the entire website residence time, the higher the search engine’s evaluation (weight) of the website.
How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. Study the residence time of a single page to understand the user's access behavior and improve the page.
Residence time is only one factor that search engines consider the quality of a website
How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. Whether the page design is reasonable, this is also the best reflection of the browsing habits of the product. Know what information is useful to users!
How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. Stay on the homepage The longer the time, the better. The longer the list page (entry) is not, the longer the better. The longer the product page stays, the better.
How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. The home page should be concise, or it should be easier to see what he wants, easy to understand, and clearly classified.
How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. The list page must have a filtering function, so that users can find the content they want faster.
How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. Rich content: detailed product introduction, multiple photos of physical products, reviews, similar products (the combination of pictures and text reduces users’ reading fatigue)
How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. The text content is readable and the fonts size
How to calculate the time on site and the time on page, calculate the time on site_PHP tutorial. Expand user needs: open a different directory and related recommendations

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/How to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorialHow to calculate the time on site and the time on page, calculate the time on site_PHP tutorial.htmlTechArticleHow to calculate the time on site and the time on page, calculate the time on site (Time on Site, hereinafter referred to as Ts) and Time on Page (Time on Page, briefly below...
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

How to copy a page in Word How to copy a page in Word Feb 20, 2024 am 10:09 AM

Want to copy a page in Microsoft Word and keep the formatting intact? This is a smart idea because duplicating pages in Word can be a useful time-saving technique when you want to create multiple copies of a specific document layout or format. This guide will walk you through the step-by-step process of copying pages in Word, whether you are creating a template or copying a specific page in a document. These simple instructions are designed to help you easily recreate your page without having to start from scratch. Why copy pages in Microsoft Word? There are several reasons why copying pages in Word is very beneficial: When you have a document with a specific layout or format that you want to copy. Unlike recreating the entire page from scratch

CUDA's universal matrix multiplication: from entry to proficiency! CUDA's universal matrix multiplication: from entry to proficiency! Mar 25, 2024 pm 12:30 PM

General Matrix Multiplication (GEMM) is a vital part of many applications and algorithms, and is also one of the important indicators for evaluating computer hardware performance. In-depth research and optimization of the implementation of GEMM can help us better understand high-performance computing and the relationship between software and hardware systems. In computer science, effective optimization of GEMM can increase computing speed and save resources, which is crucial to improving the overall performance of a computer system. An in-depth understanding of the working principle and optimization method of GEMM will help us better utilize the potential of modern computing hardware and provide more efficient solutions for various complex computing tasks. By optimizing the performance of GEMM

How to calculate addition, subtraction, multiplication and division in word document How to calculate addition, subtraction, multiplication and division in word document Mar 19, 2024 pm 08:13 PM

WORD is a powerful word processor. We can use word to edit various texts. In Excel tables, we have mastered the calculation methods of addition, subtraction and multipliers. So if we need to calculate the addition of numerical values ​​in Word tables, How to subtract the multiplier? Can I only use a calculator to calculate it? The answer is of course no, WORD can also do it. Today I will teach you how to use formulas to calculate basic operations such as addition, subtraction, multiplication and division in tables in Word documents. Let's learn together. So, today let me demonstrate in detail how to calculate addition, subtraction, multiplication and division in a WORD document? Step 1: Open a WORD, click [Table] under [Insert] on the toolbar, and insert a table in the drop-down menu.

How to add trusted sites in Google Chrome How to add trusted sites in Google Chrome Jul 19, 2024 pm 04:14 PM

How to add trusted sites in Google Chrome? Some users cannot browse the web normally because the page prompts that it is not secure when surfing the Internet. At this time, they can add the website as a trusted site, and we can access it normally and surf the Internet smoothly. The editor below will bring you the steps to add a trusted site in Google Chrome. The steps are simple and easy to operate, and even beginners can easily get started. Friends who need it can learn about it together. How to add a trusted site in Google Chrome: 1. Open Google Chrome and click the three dots in the upper right corner. Click [Settings]. Choose privacy settings and security. (As shown in the picture) 2. Click Website Settings at the bottom of the page. (As shown in the picture) 3. Click on the unsafe content at the bottom of the page. (As shown in the picture) 4. Click the Add button to the right of the Allow option. (As shown in the picture) 5. Lose

How to count the number of elements in a list using Python's count() function How to count the number of elements in a list using Python's count() function Nov 18, 2023 pm 02:53 PM

How to use Python's count() function to calculate the number of an element in a list requires specific code examples. As a powerful and easy-to-learn programming language, Python provides many built-in functions to handle different data structures. One of them is the count() function, which can be used to count the number of elements in a list. In this article, we will explain how to use the count() function in detail and provide specific code examples. The count() function is a built-in function of Python, used to calculate a certain

Count the number of occurrences of a substring recursively in Java Count the number of occurrences of a substring recursively in Java Sep 17, 2023 pm 07:49 PM

Given two strings str_1 and str_2. The goal is to count the number of occurrences of substring str2 in string str1 using a recursive procedure. A recursive function is a function that calls itself within its definition. If str1 is "Iknowthatyouknowthatiknow" and str2 is "know" the number of occurrences is -3. Let us understand through examples. For example, input str1="TPisTPareTPamTP", str2="TP"; output Countofoccurrencesofasubstringrecursi

How to use the Math.Pow function in C# to calculate the power of a specified number How to use the Math.Pow function in C# to calculate the power of a specified number Nov 18, 2023 am 11:32 AM

In C#, there is a Math class library, which contains many mathematical functions. These include the function Math.Pow, which calculates powers, which can help us calculate the power of a specified number. The usage of the Math.Pow function is very simple, you only need to specify the base and exponent. The syntax is as follows: Math.Pow(base,exponent); where base represents the base and exponent represents the exponent. This function returns a double type result, that is, the power calculation result. Let's

How to quickly refresh a web page? How to quickly refresh a web page? Feb 18, 2024 pm 01:14 PM

Page refresh is very common in our daily network use. When we visit a web page, we sometimes encounter some problems, such as the web page not loading or displaying abnormally, etc. At this time, we usually choose to refresh the page to solve the problem, so how to refresh the page quickly? Let’s discuss the shortcut keys for page refresh. The page refresh shortcut key is a method to quickly refresh the current web page through keyboard operations. In different operating systems and browsers, the shortcut keys for page refresh may be different. Below we use the common W

See all articles