mark l chaves
Forum Replies Created
-
Cool. Share & enjoy π
Closing thread.
Hi @kronos1705,
You can view browser, OS, and mobile device data in your UA property under Audience > Technology and Audience > Mobile.
If you want to programmatically send a custom dimension to GA to set the user agent for each hit, you can follow this example PHP action hook.
https://gist.github.com/chavesm/8b86c58e66b3d1ca21bc3b4fd6412bd6
Remember to change the custom dimension index number in the gist to the one you create in your GA property.
Let us know how that goes π
Mark
- This reply was modified 5 years, 1 month ago by mark l chaves. Reason: Fixed report paths
- This reply was modified 5 years, 1 month ago by mark l chaves. Reason: Fixed strong tags
Hi @guyinpv,
You can disable MonsterInsights tracking with PHP action hooks. See below.
https://gist.github.com/chriscct7/98aa70dc7832f36575ea7a739209b436
That way you can avoid running multiple trackers by selectively disabling MonsterInsights tracking. But, you can still enjoy the convenience of analytics reports in your wp-admin area.
Thanks!
Mark
Hi @guyinpv,
You should really have only 1 GA platform on your site. But, GTM can come in handy for the few things (like videos) that MonsterInsights doesn’t track.
MonsterInsights can detect duplicate tracking code (except GTM), but it won’t prevent sending duplicate events. So if your client wants to use MonsterInsights and GTM at the same time on the same site, it’s probably best for them to disable all GTM page view type tags in their container.
Those tags will look like this.
Thanks for asking π
Mark
Forum: Fixing WordPress
In reply to: white space after iframe embed for mobileHello @cheungra,
The original height is 470px. You can try this CSS media query to reduce the height on smaller devices.
@media (max-width: 576px) { iframe.juxtapose { height: 370px; /* Original height is 470px. Adjust as needed. */ } }How to add custom CSS to WordPress.
Let me know how that goes.
Thanks!
- This reply was modified 5 years, 1 month ago by mark l chaves. Reason: Fixed CSS comments error
Forum: Developing with WordPress
In reply to: Responsive design in mobileHello @reberancs,
It looks like the (hidden) mobile menu is causing the problem.
In the screen capture below you can see that the hidden mobile menu’s width 395px while the iPhone’s width is 375px.
https://share.getcloudapp.com/9Zuxo7Xm
In this video, you can see when I click to close the mobile menu, it gets wider as it gets hidden.
https://share.getcloudapp.com/X6ueRpNl
Can you ask the kind folks at Elementor (or your theme developer) if they can confirm this and recommend a fix?
Thanks!
Closing due to staleness.
Hello @wppit,
Thatβs a great question. Thanks for asking.
Please look at the emove_type_attr_add_async.php file in the gist below.
https://gist.github.com/chavesm/1c9eb33ad489ccaecc606401f9bbd1b3#file-remove_type_attr_add_async-php
Carefully read the comments in the code. Yell if you have any questions π
Let us know how that goes.
Have an awesome weekend!
Mark`
Forum: Developing with WordPress
In reply to: How to override WP default menu cssHi @jana90,
Thanks for clarifying.
Based on what you’re trying to do and what you’re seeing, I think your theme’s CSS isn’t being picked up (not overridden).
It’s because the blue links with underlines and decorated bullet points are exactly the browser’s default CSS.
As @rossmitchell mentions, the next thing I would do to troubleshoot is to inspect your nav elements with Chrome or FireFox dev tools.
To reiterate @rossmitchell, a great test is to add your nav CSS classes directly to Appearance > Customise > Additional CSS. Make sure you purge your cache to see the changes.
Here’s the link to Chrome’s https://developers.google.com/web/tools/chrome-devtools/
If you have a public link to one of your pages, we can have a look too.
Cheers,
Mark
Forum: Developing with WordPress
In reply to: How to override WP default menu cssHi @jana90,
There are a few ways to add CSS in WordPress.
In your case, I think using a child theme would work best.
With a child theme setup, you can add CSS to your child theme’s style.css file. This should override parent theme and core WordPress styles.
Learn more here.
https://developer.wordpress.org/themes/advanced-topics/child-themes/
Also with a child theme setup, you can “include” (enqueue) any existing CSS files you have by adding action hooks to your child theme’s functions.php. E.g.,
/** * Add a CSS file from the child theme. */ function my_plugin_add_stylesheet() { wp_enqueue_style( 'my-style', get_stylesheet_directory_uri() . '/style.css', false, '1.0', 'all' ); } add_action( 'wp_enqueue_scripts', 'my_plugin_add_stylesheet' );Shout if you have any questions.
Cheers,
Mark
Hi @sathoro,
That’s a great question. Thanks for asking.
Please look at the second file in the gist below. The file name is
remove_type_attr_add_async.phphttps://gist.github.com/chavesm/1c9eb33ad489ccaecc606401f9bbd1b3
Carefully read the comments in the code. Yell if you have any questions π
Have an awesome weekend!
Mark
- This reply was modified 5 years, 2 months ago by mark l chaves.
Hi @galbaras,
I see that our team has been working with you on this.
I’m going to mark this as resolved. But, please feel free to post a follow-up to share or open a new thread as needed π
Cheers,
Mark
Hi @mttindustries-1,
Cool! Thanks for the update.
I’m going to close this thread. But, feel free to post a follow-up or create a new post as needed.
Cheers π
Mark
Forum: Everything else WordPress
In reply to: No responsive backgroundHello @ermarsot,
I just visited your site again. I don’t see any media queries or art-direction images.
Did you remove the code?
If you want me to help you troubleshoot, feel free to set up a test page and then post the link to the test page.
If you need more examples, I’ve got many live demos of art-direction responsive design on my CodePen and running my own site.
Just let me know π