Where are the src and srcset sizes coming from?

Themes and plugins can use the add_image_size function to define image sizes. Whenever an image is uploaded, WordPress will generate a separate image file for every size that is defined. Now, when you insert an image in your post, WordPress will ask you which size you want to use by default. This will be the … Read more

Change Header Image on Blog Post for Mobile View

You’re not calling the class correctly. The container has both the page-banner and the bg classes, so you should write it like this: .page-banner.bg And the class post-id-41012 doesn’t exist in your document. postid-41012 does. So try this way: @media (max-width: 767px) { .postid-41012 .page-banner.bg { background-image: url(‘https://staging3.ryanlawn.com/wp-content/uploads/2021/09/ggob-blog-banner-all-star-2021-m.jpg’) !important; } }

Responsive dropdown menu with smaller screen sizes

Looking at that tutorial, you need to match up the jQuery selector with the menu markup. You can see in this line navigation: $(‘#nav ul’), that the jQuery expects your menu to be in a <ul> inside a parent element with the id nav. Luckily, that’s really easy to do. Just change your wp_nav_menu() arguments … Read more

Add Image Size for Featured Image with Responsive Design

You can wrap the image in a figure. <!– html –> <figure class=”constrained-container”> <img src=”https://wordpress.stackexchange.com/questions/100091/my-image.jpg” alt=”What my image is about”/> </figure> Then style the figure as well as the image. /* css */ .constrained-container { height: 300px; overflow: hidden; /* this hides excess of the image */ } .constrained-container img { display: block; width: 100%; … Read more

Serve a different theme based on window size

You shouldn’t need to use a different theme. A good responsive theme should handle all sorts of device window sizes. The new default WP theme, Twenty Thirteen, is responsive mobile first and changes for different device screen sizes. http://wordpress.org/themes/twentythirteen

Faster fonts on mobile

WordPress has wp_is_mobile() function to detect mobile and handheld devices. You can use that to define your enqueue function to load fonts conditionally. You can enqueue fonts for non mobile devices like this. function my_enqueue_function() { if ( !wp_is_mobile() ) { wp_enqueue_style( ‘gfonts’, ‘http://fonts.googleapis.com/css?family=Arbutus+Slab’, false, NULL, ‘all’ ); } } add_action( ‘wp_enqueue_scripts’, ‘my_enqueue_function’ );

How to load different homepage on Mobile.?

This question is pretty vague but I’ll give it a shot. A few options: 1) Check out WPtouch – http://www.wptouch.com/ – This plugin gives you the ability to override certain aspects of your primary theme with mobile friendly templates instead. 2) This is not ideal but you could use some basic Javascript to check the … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)