How to filter blog pageviews using segments with regex
-
I must be overcomplicating this. I have a website with a blog structure that includes year subfolders, so: website.com/2019/blog-title, website.com/2018/blog-title, website.com/2017/blog-title, etc. I want to create a segment that I can apply in Site Content > All Pages to get quick stats for all blogs, regardless of year. (Pageviews, time on site, etc.) Unfortunately, Content Drilldown doesn't work well here as it is grouping by each year. I have tried setting up a segment using regex, but am getting a mixture of all pages, not just blog pages. I have set up the segment the following way:
Advanced > Conditions > Page, Matches Regex, /2019/(.*?)/
Advanced > Conditions > Page, Matches Regex, /2018/(.*?)/
Advanced > Conditions > Page, Matches Regex, /2017/(.*?)/
Am I going about this all wrong? Is my regex wrong? Any advice is appreciated!
Side note: glaringly obvious that now is the time to clean up my URLs. But I'd still love to see the data in its current URL state.
Thank you!
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Is there an efficient way to block/filter referral spam in Google Analytics for a large network of websites?
Hello, everyone - I'm looking for guidance on how to block or filter referral spam in Google Analytics. But I'm needing to block for an entire network of Wordpress websites. We have two networks which total over 2,500 websites. We are currently blocking sites we find out about via htaccess. This works, but only after we see we are getting hit with the spam. Updating 2,500+ Google Analytics accounts with filtering is not an ideal option due to the time factor and the fact that new bots coming out almost daily. We can continue the htaccess method, but does anyone have any other ideas for blocking referral spam for a large network of sites? These are the other ideas we have. 1. Blocking all traffic from Russia and China based up subnets. We know many will still get through, but it should block 50% of it, we hope.
Reporting & Analytics | | copyjack
2. Moving sites to Google Tag manager. This is a huge tasks but we have seen that sites using Tag Manager are not effected, at least for now. Other ideas are appreciated!0 -
Google Analytics is treating my blog like all the content is just on the home page.
Hello all, I installed Google Analytics on a main website and a blog (blog.travelexinsurance.com) While it appears to be tracking correctly (and when I test it in real time it shows that I'm visiting) but it is treating the entire blog as though it's one page. So I can't see data on blog post X. All I see is that X visitors came to my blog in aggregate. So I see blog.travelex.com has 999 visitors, but it doesn't show that /travel-luggage got 50 visits, while /insurace-tips got 75 and so forth. I assume I screwed up the tracking somehow, but can't figure out where I went wrong. Tracking on the main domain works just fine. It's specific to the blog.
Reporting & Analytics | | Patrick_G0 -
Is there a problem with using same gmail account for multiple site analytics and GWMT?
Hi, Is there a problem or a general recommendation about using the same gmail account for two different sites (both in Google Analytics and Webmaster tools)? Thanks
Reporting & Analytics | | BeytzNet0 -
Will my Google sub domain filter work
Bon Pormeriggio from cloudy hot sticky & Humid Wetherby UK 😉 I have three sub domains which are reporting all the same stat traffic. Phase 1 is complete in that sub domain tracking has been configured in the analytics code for: http://en.lewispr.be/
Reporting & Analytics | | Nightwing
http://fr.lewispr.be/
http://nl.lewispr.be/ But now i want to get traffic just from http://www.en.lewispr.be/ (Previously all three subdomains reported exactly the dame data). But its this stage I just want to double check. Ive set up a filter correcly as illustrated here:
http://i216.photobucket.com/albums/cc53/zymurgy_bucket/check-en-sub-domain-tracking_zps1b24f8af.jpg Will what ive done give me just traffic arriving at http://www.en.lewispr.be/ and not continue the problem of all three sub domains reporting exactly the same traffic?
Grazie tanto,
David0 -
Can you use Google tag manager to manage rich snippets/schema mark up?
Hi,Does anyone know if you can use the new Google tag manager to manage rich snippets? I've seen that there is an HTML section where you can edit HTML that isn't shown on the site - do you think this field could be used to add schema data?Thanks,Karen
Reporting & Analytics | | Digirank0 -
Which one should I be using 301 redirects
Hiya guys, I have a little problem, not sure which one I should be using, for 301, be easy on me I've not dealt with this before. So we have http://www.talknightlife.co.uk and I've done redirects for http://talknightlife.co.uk to http://www.talknightlife.co.uk host http://www.talknightlife.sheffieldspeedcameras.co.uk to http://www.talknightlife.co.uk Because my website is purely a forum and in the canonical error from the optimisation tool is showing 301 canonical = http://www.talknightlife.co.uk/forum.php should I be redirecting that to http://www.talknightlife.co.uk or the other way round, or just leave it ? I'm a little confused Cheers in advanced for your help guys
Reporting & Analytics | | Lukescotty0 -
Use Google Spreadsheet for Top Keywords Report
I've been using the super-awesome Google doc described here http://www.seomoz.org/blog/custom-reporting-using-google-analytics-and-google-docs for all kinds of reporting and I've customized it quite a bit. But I can't figure out how to feed text-based fields from GA into this doc. For example, can I make it so this doc spits out top 10 keywords? Thanks!
Reporting & Analytics | | Oxfam_America0 -
Stats show /blog/wp-cron.php at the top. What is it?
Hi, I have worked with websites for years but have no clue when it comes to Wordpress. We have our main website and then a Wordpress blog running in a subfolder that is only about a year old. The blog has only 7 posts so you can see how small it is vs main website with 200 pages. Usually our main index page of the site is at the top of the stats with the most views and this page /blog/wp-cron.php is about 30% lower. Now suddenly over the last month this page has jumped to the top and accessed almost as much as the home page of the site. We took a big hit with the latest Google Update so we are tyring to determine if there is anything technical in our site that has caused an issue. Thanks in advance Force7
Reporting & Analytics | | Force70