- This topic has 14 replies, 2 voices, and was last updated 3 years, 3 months ago by David.
-
AuthorPosts
-
January 14, 2021 at 3:32 am #1618183Sourabh
Hi David,
Refer Snapshot and a URL in P-section and let me know how to change that search box same as visible in the sidebar, I think you have given me CSS for Sidebar search, so can I use the same for changing this search box also ??
What is the selector which I need to change.
January 14, 2021 at 6:59 am #1618592DavidStaffCustomer SupportHi there,
that CSS is specific to the sidebars. You also have similar CSS for .post class.
Adding elements one at a time like this is going to lead you to asking a lot of the same questions for lots of different elements.For all pages, posts, and archives the one element that is present for all is the
inside-article
– so you can use that CSS Selector apply that style to the container for any of your content ( not sidebars / widget areas )January 14, 2021 at 7:38 am #1618661SourabhHa.Ha.Ha, I am confused now.
So thought I need your help…
Hope you understand.
January 15, 2021 at 2:59 am #1619689DavidStaffCustomer SupportThe search form inside the page content is not a widget. It just a plain Search Form field without the
.widget
container – so you cannot simply style it in the same way….You can try
.entry-content .search-form
It will add the shadow just to the form.
But you may want to give it some padding, and make it an inline block to stop it from spanning the width of the entry-content eg..entry-content .search-form { padding: 20px; display: inline-block; }
January 15, 2021 at 6:20 am #1619889SourabhIndeed It’s a great help David, Thanks.
I created code and it’s working but a small issue is how to make the search bar long or short ?? (Refer P-Section for snapshot).
You can check out the code also with the credential if I made any fault..!!
January 15, 2021 at 7:59 am #1620193DavidStaffCustomer SupportI am not able to see the search page that was there before ?
January 15, 2021 at 8:19 am #1620231Sourabhwait, doing something with elementor hence it did not show, it is there now… Check
January 15, 2021 at 8:30 am #1620242Sourabhyes its visible now, you can check… also have a look as seems the search icon changing in mobile and tablet view (I hope length issue will fix it).
January 15, 2021 at 8:57 am #1620295DavidStaffCustomer SupportTry:
.entry-content .search-field { width: 100%; }
If you don’t want it overlapping the search icon then you can reduce the 100% width by a number of pixels like so:
.entry-content .search-field { width: calc(100% - 30px); }
January 15, 2021 at 9:22 am #1620346SourabhI think It’s already there in the code
January 15, 2021 at 9:54 am #1620381DavidStaffCustomer SupportThe CSS i provided targets the
search-field
not the formJanuary 15, 2021 at 10:05 am #1620394SourabhOkay I got it.. Thanks, I will adjust the value then…
The last question do we have any article on, how many CSS selectors are active on the GP theme, If I have to customize the same so that I can refer to the same…??
January 16, 2021 at 4:53 am #1621095DavidStaffCustomer SupportThat would be a very complicated document ๐
The best thing is to practice more with the browser developers tools.
Right click and inspect an element will display its Styles, you can see which selectors are being applied and which are common.January 16, 2021 at 5:00 am #1621105SourabhI tried, but it’s difficult to identify, Maybe I need a bit more practice. Thanks David.
January 16, 2021 at 8:10 am #1621427DavidStaffCustomer SupportYeah – it gets easier the more you use Dev Tools… before you know it you’ll be a CSS Ninja ๐
-
AuthorPosts
- You must be logged in to reply to this topic.