- This topic has 9 replies, 2 voices, and was last updated 8 years, 1 month ago by Mahesh.
-
AuthorPosts
-
September 27, 2016 at 6:53 pm #100399maviedecoeliaqueParticipant
Hello,
sorry for my english, I’m french.
Today, I created a child theme for the theme Catch box. Everything looks great but I have a problem with my menu in mobiles.
I took 2 pics to show you my problem.
The first is how my site looks like with the theme catch box (It’s what I want).
The second shows how my site looks like with my child theme.
What can I do to have a site like the first with my own child theme ?Thank you so much for your help,
MathildeSeptember 28, 2016 at 10:25 am #100465MaheshParticipant@maviedecoeliaque: Have you done any customization in the child theme? Please activate child theme and let me know so I can check it.
Regards,
MaheshSeptember 28, 2016 at 11:24 am #100470maviedecoeliaqueParticipantThanks. Yes I did any customization but even if I delete any of this customization in the CSS, I have the same probleme.
In the functions.php, I wrote :
<?php
/**
** activation theme
**/
add_action( ‘wp_enqueue_scripts’, ‘theme_enqueue_styles’ );
function theme_enqueue_styles() {
wp_enqueue_style( ‘parent-style’, get_template_directory_uri() . ‘/style.css’ );
}
?>In the style.css, I wrote :
/*
Theme Name: Catch-box-enfant
Description: Theme enfant de Mathilde maviedecoeliaque
Author: Mathilde – maviedecoeliaque
Author URI: https://maviedecoeliaque.fr
Template: catch-box
Version: 0.1.0
*//* =Menu
————————————————————– */#access,
#access-footer {
background: #3d3d3d; /* Show a solid color for older browsers */
background: -moz-linear-gradient(#40A4A4, #40A4A4);
background: -o-linear-gradient(#40A4A4, #40A4A4);
background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#40A4A4), to(#40A4A4)); /* older webkit syntax */
background: -webkit-linear-gradient(#40A4A4, #40A4A4);
clear: both;
display: block;
float: left;
margin: 0 auto 2px;
width: 100%;
}
#access ul.menu a,
#access-secondary ul.menu a {
display: block;
font-family: ‘Rancho’ , cursive;
font-size: 1.4em;
}/* =Content
———————————————– */#main {
background-color: #eee;
clear: both;
}
.entry-title,
.entry-title a {
color: #B70150;
text-decoration: none;
font-family: ‘Rancho’, cursive;
}/* =Widgets
———————————————– */.widget-area {
font-size: 13px;
line-height: 1.80em;
}
#secondary .widget_catchbox_social_widget {
padding: 1em 1em 0.2em;
}
.widget-title {
border-bottom: 2px solid #ccc;
color: #09687D;
font-size: 18px;
font-weight: bold;
letter-spacing: 0.1em;
font-family: ‘Rancho’, cursive;
}
.widget ul {
font-size: 16px;
margin: 0 0em;
}/* =Padding and Margins
———————————————– */.widget {
padding: 20px;
}This is all I write in my child theme.
Thanks for your help,
MathildeSeptember 28, 2016 at 1:04 pm #100477MaheshParticipant@maviedecoeliaque: Following CSS in your child theme’s style.css is causing the issue:
#access, #access-footer { background: #3d3d3d; /* Show a solid color for older browsers */ background: -moz-linear-gradient(#40A4A4, #40A4A4); background: -o-linear-gradient(#40A4A4, #40A4A4); background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#40A4A4), to(#40A4A4)); /* older webkit syntax */ background: -webkit-linear-gradient(#40A4A4, #40A4A4); clear: both; display: block; float: left; margin: 0 auto 2px; width: 100%; }
display: block is causing the issue.
Regards,
MaheshSeptember 28, 2016 at 3:38 pm #100486maviedecoeliaqueParticipantThanks, so do I remove the line display: block in the child theme, the parent theme or both of theme to fix the problem?
regards,
MathildeSeptember 28, 2016 at 4:06 pm #100492MaheshParticipant@maviedecoeliaque: Just the child theme. Let me know if any problem.
Regards,
MaheshSeptember 28, 2016 at 4:51 pm #100495maviedecoeliaqueParticipantI remove the display: block and lines clear: both, float: left, margin and width, but it doesn’t change anything, I’m sorry.
Regards,
MathildeSeptember 29, 2016 at 10:15 am #100528MaheshParticipant@maviedecoeliaque: I checked your child theme, I remove the above block of CSS and the menu from the mobile view was gone, it fixed the issue. In fact, just removing
display: block;
fixed it.
Its CSS in your child theme that is causing the issue. If you have tried removing it and it is still displays, may be some caching problem then.Regards,
MaheshSeptember 29, 2016 at 12:18 pm #100539maviedecoeliaqueParticipantThank you so much, I remove the display block in the #access-secondary ul.menu a and in the #access footer and it’s perfect !
Thank you for your help and your patience,
Regards,
MathildeSeptember 29, 2016 at 3:46 pm #100557MaheshParticipant@maviedecoeliaque: Thank you for your appreciation. Have a nice day!
Regards,
Mahesh -
AuthorPosts
- The topic ‘My menu doesn't look the same in mobiles with Catch box theme and my child theme’ is closed to new replies.