ideacom
Forum Replies Created
-
Forum: Developing with WordPress
In reply to: Problem with template_include and body_classThank @joyously for the quick answer.
As for your question :
My code goes into a plugin. That code is just a simplify version to work with in function.php for testing purpose.
As for what i’m trying to achieve : i’m trying to replicate woocommerce way of building template with https://gist.github.com/bmarshall511/8e00dd4acd081c3bd1f27bae22122e34 as guide. I create template in my plugin folder, associate them to certains page. Then the user can create his own child template if he desire in the theme folder to overwrite the template.
This makes sense to me since that represents the page template that the user chose in the editor, not the name of the template file being used.
At this point maybe this is the direction the wordpress team went with. I don’t find it logical since in my case the user didn’t select any template at all. In any case this is fine with me, I will try to find another way to handle the template.
Thank.
Forum: Plugins
In reply to: [Broken Link Checker] Does not startI got the same error on the latest WordPress and php 7.2
Forum: Plugins
In reply to: [Broken Link Checker] Broken Link Checker PHP ErrorsI got the first error too :
[12-Jun-2019 13:17:39 UTC] PHP Deprecated: Function create_function() is deprecated in /wp-content/plugins/broken-link-checker/core/core.php on line 957
I found the problem. I was using a promo code for both the faulty product and it seem to trigger is_wcpa_product for some unknow reason.
I deleted the promo code and everything work fine now.
It may be worth to investigate if there is a conflict between this and the plugin.
Thank.
Forum: Plugins
In reply to: [WP Responsive Menu] One menu for multilingual sites doesn’t workQuick fix for those of us stuck waiting for an update :
Go to
/wp-content/plugins/wp-responsive-menu/inc/wprmclass.php line 363Edit
if( is_object( $menu ) ) : wp_nav_menu( array( 'menu'=>$menu->name,'container'=>false,'items_wrap'=>'%3$s' ) ); endif;
for
if(ICL_LANGUAGE_CODE == "fr") wp_nav_menu( array( 'menu'=>"Menu FR", 'container'=>false, 'items_wrap'=>'%3$s' ) ); else wp_nav_menu( array( 'menu'=>"Menu EN", 'container'=>false, 'items_wrap'=>'%3$s' ) );
Forum: Plugins
In reply to: [WP Responsive Menu] One menu for multilingual sites doesn’t work@sagarseth9 if its harder than expected to implement, cant you give us a hack like this? We have been waiting for a month now.
if(lang = "en") do_shortcode('[responsive_menu name_menu="Menu EN" other_option_here=""]'); else do_shortcode('[responsive_menu name_menu="Menu FR" other_option_here=""]');
to add in header.php
Thank.
Forum: Plugins
In reply to: [WP Responsive Menu] One menu for multilingual sites doesn’t workStill waiting for the plugin update.
Can we have an ETA?
Thank.
Forum: Plugins
In reply to: [WP Responsive Menu] One menu for multilingual sites doesn’t workI have the same problem. I’m waiting for the patch.
Thank you.
If it was for a personal projet I would not mind using subdomain.
Do you think its some kind of wordpress limitation?
Hello, im running apache 2.4+.
Your code is working for simple redirection like
<If “%{HTTP_HOST} == ‘test.com'”>
RewriteRule / “https://www.google.com”
<If>
<If “%{HTTP_HOST} != ‘test.com'”>
RewriteRule / “https://www.hotmail.com”
<If>But, if I use “if” with wordpress code in it, it dosent work anymore :
<If “%{HTTP_HOST} != ‘test.com'”>
wordpress code here
</If>
<If “%{HTTP_HOST} != ‘test.com'”>
wordpress code here
</If>I made some test and as soon as I use <If “%{HTTP_HOST} != ‘test.com'”> everything crash except home page.
I think there is some redirect at work we dont know of which prevent the use of this method.