ColorlibHQ / illdy

Illdy is a free one page WordPress business theme with a minimal design
GNU General Public License v3.0
44 stars 38 forks source link

[Bug] Contact Us Title not displaying on front end. #181

Closed laranz closed 7 years ago

laranz commented 7 years ago

In line #24 and #42 in /wp-content/themes/illdy/sections/front-page-contact-us.php

The title variable is wrongly getting, it should be

$general_title = get_theme_mod( 'illdy_contact_us_title', __( 'Contact us', 'illdy' ) ); and $general_title = get_theme_mod( 'illdy_contact_us_title' );

We had a word general.

cristianraiber commented 7 years ago

@giucu91 - please see this.

thiagovilla commented 7 years ago

This worked for me!

thiagovilla commented 7 years ago

Also, removing "general_" from the address and customer support titles solved the issue for these variables.

laranz commented 7 years ago

@thiagoth23 Yeah, it will be fixed in the next version. 👍

LuigiBella commented 7 years ago

@laranz or @thiagoth23 Could you please describe in detail how to fix it in the meantime? You can see the issue at my domain here: http://www.bradfordcowork.com

Thanks so much!

thiagovilla commented 7 years ago

@LuigiBella it's been a while since I last did this. Do you have the front-page-contact-us.php original file on yourself? Attach it here and I can take a look.

LuigiBella commented 7 years ago

@thiagoth23 Thanks so much for replying, I managed a work around but would love to find why it broke in the first place.

To get the About and Contact Us titles to display I went to the Customizer and changed the default text from About to "- About -", I did the same thing for the Contact Title.

Here is the original file from version 1.0.35; version 2.0 brought a whole other array of issues such as breaking the customizer, removing the background of the contact form, and changing the footer so I went back to version 1.0.35 and can get the customizer working as long as I disable the Illdy Companion plugin:

front-page-contact-us.php.zip

thiagovilla commented 7 years ago

Yikes! I hate it when a newer version screws up more than the previous one!

Uhm, let's see! Okay, so here's lines 24-28:

$general_title = get_theme_mod( 'illdy_contact_us_general_title', __( 'Contact us', 'illdy' ) ); $general_entry = get_theme_mod( 'illdy_contact_us_general_entry', __( 'And we will get in touch as soon as possible.', 'illdy' ) ); $general_contact_form_7 = get_theme_mod( 'illdy_contact_us_general_contact_form_7' ); $general_address_title = get_theme_mod( 'illdy_contact_us_general_address_title', __( 'Address', 'illdy' ) ); $customer_support_title = get_theme_mod( 'illdy_contact_us_general_customer_support_title', __( 'Customer Support', 'illdy' ) );

And 42-46:

$general_title = get_theme_mod( 'illdy_contact_us_general_title' ); $general_entry = get_theme_mod( 'illdy_contact_us_general_entry' ); $general_contact_form_7 = get_theme_mod( 'illdy_contact_us_general_contact_form_7' ); $general_address_title = get_theme_mod( 'illdy_contact_us_general_address_title' ); $customer_support_title = get_theme_mod( 'illdy_contact_us_general_customer_support_title' );

FIX

What I did the last time was remove the "general_" prefix from WITHIN the get_theme_mod method, NOT the variable name! See:

BEFORE:

$general_title = get_theme_mod( 'illdy_contact_us_general_title', __( 'Contact us', 'illdy' ) );

AFTER:

$general_title = get_theme_mod( 'illdy_contact_us_title', __( 'Contact us', 'illdy' ) );

captura de tela de 2017-06-27 08-55-23

So here's your file with the "general_" prefix removed from lines 24-28, 42-46. Try it and let me know if it worked.

front-page-contact-us.php.zip

LuigiBella commented 7 years ago

@thiagoth23 Once again, thank you! but strangely enough, it doesn't appear to have worked; here is what happened: screen shot 2017-06-27 at 3 19 37 pm

and you can see the website with the original script here: bradfordcowork.com

thiagovilla commented 7 years ago

That's awkward. It worked for me. Have you tried refreshing your cache? Try shift + F5, a new machine or a private tab.