-
AuthorPosts
-
April 28, 2014 at 5:13 pm #38250
JamesonParticipantHi, Support! Really love the theme – it’s one of the best purchases I’ve made lately. I’ve gone back and forward with the stacks with my shop, and I’ve settled on the Integrity stack for doing the most of what I want with my first store (with some CSS edits, of course). However, I’ve run into a wall, and I think I’ve checked just about all of your originally-overwhelming but ultimately-fantastic documentation, plus the forum search.
1. I’m trying to add content (probably a banner) with a little padding-bottom above the populated content of the shop, including the sidebar. How would I go about doing so?
2. Certain pages (checkout, cart, etc) won’t need the sidebar. Fiddling with the template doesn’t do the trick. How do I determine which pages can skip loading it?
I had a few more questions (sidebar -> background color, elements -> background color, elements -> borders, etc), but I’ve managed to sort out how to fix those by utilizing CSS edits and figuring out how the elements are referenced in the coding.
Thanks a ton!
April 29, 2014 at 1:54 am #38417
Colin MParticipantPlease share your CSS edits for styling the sidebar. I am trying to do that but can’t figure out how. 🙁
April 29, 2014 at 2:47 pm #38624
AlexanderKeymasterHi there!
Jameson, you could adds something like this to functions.php of a child theme.
add_action('woocommerce_before_main_content','custom_shop_before_main_content'); function custom_shop_before_main_content() { ?> <!--your banner here--> <?php }You can change sidebar conditions by overriding the sidebar template in a child theme. For example: x/framework/views/renew/wp-sidebar.php
It will take some coding knowledge, but that’s the best place to determine whether or not the sidebar should be loaded.
You can code in your conditions and set the$layoutvariable.Colin, I’d recommend checking our CSS Class Index. If you have any specific questions, feel free to open your own thread.
Take care!
May 1, 2014 at 7:16 pm #39548
JamesonParticipantThere’s a huge problem that surfaces when I add that…the white screen of death.
I tried it a number of times, always performing the following steps:1. Remove prior crashed child theme via FTP
2. Re-upload child theme
3. Live Preview > Save and Activate
4. Open the site to double-check (although WP-ADMIN is down when crashed anyway)
5. Check Customizer settings
6. Open “functions.php” under the child theme
7. Add the text
8. Save
9. Witness crashI’ve attempted this with several different things, since I know coding but not PHP (and ran it past some programmer friends), but I cannot figure out for the life of me why it crashes my site every time I try to implement it. I’ve made sure it’s gone into the “functions.php” page and for that specific child theme every time, and I’m at a loss.
Halp!
EDIT: Ran the entire “functions.php” (which includes no changes besides your suggested one) through an online PHP analysis, and it checks out. So I’m cruising through Shrug City right now. I’ll leave it be and continue putting together the banner and the resources it was going to link to, and wait to here what could fix it.
May 2, 2014 at 12:30 pm #39817
AlexanderKeymasterHi Jameson,
A white screen usually means there is a fatal PHP error. Can you please enable WP_DEBUG mode? You can do this by opening
wp-config.phpand addingdefine( 'WP_DEBUG' , true );just above/* That's all, stop editing! Happy blogging. */For example:

When you revisit the page with the white screen, you should have some error output. Let us know what you find out.
May 3, 2014 at 4:11 pm #40180
JamesonParticipantHi Support,
Fatal error: Cannot redeclare custom_shop_before_main_content() (previously declared in /home2/theramp3/public_html/thefairnecessities/wp-content/themes/x-child-integrity-light/functions.php:13) in /home2/theramp3/public_html/thefairnecessities/wp-content/themes/x/functions.php on line 112
This is the output. Since it’s very specific, and I understand what it’s telling me, I’ll look into this and see if I can fix it myself.
EDIT: Original problem fixed, but. Apparently, at some point I accidentally dropped the code into the X theme proper, so that’s gone and I was able to easily sort that out. However, nothing I put into the designated area in the code (images, text, what have you) will populate on the pages. Do I need to wrap it in some kind of shell for the PHP to recognize it, or am I doing something wrong?
May 3, 2014 at 9:36 pm #40262
RadModeratorHi Jameson,
Sorry, but I’m not sure what you meant. :/ Could you provide a URL address? Or maybe screenshot too.
Thank you.
May 4, 2014 at 1:36 pm #40400
JamesonParticipantThis reply has been marked as private.May 4, 2014 at 7:51 pm #40505
RadModeratorHi Jameson,
What fixes did you add? Right now I can’t tell what is wrong.
If you’re having function name conflict, you could just rename the function you added at child theme’s functions.php
Example :
add_action('woocommerce_before_main_content','my_renamed_function'); function my_renamed_function() { ?> <!--your banner here--> <?php }Thank you.
May 5, 2014 at 10:08 pm #40955
JamesonParticipantHi Support,
The only fix that I applied was to remove the duplicate code on the original X theme. This is all that I have in regards to the proposed fix to allow me to populate content above the automatically-generated content of the store and sidebar.
Here’s the screenshot I forgot to include.
May 6, 2014 at 1:49 pm #41193
AlexanderKeymasterHi Jameson,
Yes, the problem was that you had the code in both the parent and child theme. Using a child theme allows you to avoid modifying the parent theme. This way things are more “update proof” and your own code is preserved on theme updates.
Now you just need to replace
<!--your banner here -->with whatever HTML you want.May 10, 2014 at 9:59 am #42901
JamesonParticipantHi Support,
As I said above,
However, nothing I put into the designated area in the code (images, text, what have you) will populate on the pages. Do I need to wrap it in some kind of shell for the PHP to recognize it, or am I doing something wrong?In the screenshot, the placeholder text is there, but the problem is that -nothing- put into the field shows up.
May 10, 2014 at 10:10 am #42902
JamesonParticipant
Here is an example of what I mean. This, as a dummy url (although I’m sure http://www.pants.com is a thing) does not generate any changes to the shop.May 11, 2014 at 4:55 pm #43262
RadModeratorHi Jameson,
That link you provided is a park page, could you post a correct one? or maybe point your domain there 🙂
Thank you.
May 12, 2014 at 6:37 pm #43656
JamesonParticipantI checked it on a few browsers, and it always goes straight to the shop.
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-38250 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
