implenton
Forum Replies Created
-
Forum: Hacks
In reply to: Custom post theme – thumbnail supportHello @wojkam,
you might want to check if your theme supports post thumbnails. If not you can enable it like so:
add_theme_support( 'post-thumbnails' );in functions.phphttps://developer.ww.wp.xz.cn/reference/functions/add_theme_support/#post-thumbnails
https://codex.ww.wp.xz.cn/Function_Reference/register_post_type#supports
Forum: Hacks
In reply to: Auto-add post ID as a value in postmeta tableHello @nwarmenh,
Here is a working example implementation:
function save_the_thepostID( $post_id ) { update_post_meta( $post_id, 'thepostID', $post_id ); } add_action( 'save_post', 'save_the_thepostID' );save_post is an action triggered whenever a post or page is created or updated, which could be from an import, post/page edit form, xmlrpc, or post by email.
https://codex.ww.wp.xz.cn/Plugin_API/Action_Reference/save_post
The function update_post_meta() updates the value of an existing meta key (custom field) for the specified post.
https://codex.ww.wp.xz.cn/Function_Reference/update_post_meta
Whenever you update a post it makes sure the ID is saved to the
thepostIDmeta key.Forum: Fixing WordPress
In reply to: Hiding Slider WD in Uniform ThemeHello @thedesignhub,
It would be helpful if you would add here the code from the child theme’s
functions.phpandstyle.css, so we can take a look.Also if you would link your site URL.
Forum: Fixing WordPress
In reply to: Hiding Slider WD in Uniform ThemeHello @thedesignhub,
Hide it using CSS:
First, you should create a Child Theme
f you modify a theme directly, and it is updated, then your modifications may be lost. By using a child theme, you will ensure that your modifications are preserved.
Read a step by step guide here: https://codex.ww.wp.xz.cn/Child_Themes#How_to_Create_a_Child_Theme
The CSS code you need is this:
@media (max-width: 767px) { #section-slider { display: none; } }Using wp_is_mobile
If you don’t want to display the slider if you are visiting your website from a mobile device one way to go about this is to use the
wp_is_mobilefunction.You should realize that this does not detect a mobile phone specifically, as a tablet is considered a mobile device. Check the Plugins area for several helpful alternatives. It also should not be used for themes
https://codex.ww.wp.xz.cn/Function_Reference/wp_is_mobile
The slider is included in the
/template-parts/home-page.phpfile at line 18<!-- Section Slider --> <section class="uniform-home-section" id="section-slider"> <?php get_template_part( 'template-parts/section', 'homesider' ); ?> </section>(this in case you haven’t modified the file).
You can wrap this section of code in this:
<?php if ( ! wp_is_mobile() ) : ?> code to include the slider <?php endif; ?>Forum: Fixing WordPress
In reply to: Language mixupHello @prokops,
If you are running WordPress 4.0 or about the easiest way to switch your installation to a different language is to change in the admin.
https://codex.ww.wp.xz.cn/Installing_WordPress_in_Your_Language#WordPress_v4.0_and_above
WordPress core does come with translations for different languages including Danish, but not all plugins come with Danish translations. That’s the reason for ending up with the mix of English and Danish strings.
Maybe you would like to help out the developers and provide the translations yourself, if you would like to do that contact the plugin developers and read more about the process here: https://premium.wpmudev.org/blog/how-to-translate-a-wordpress-plugin/
I hope this answers you question.
Forum: Networking WordPress
In reply to: Network Admin url points to the old domainHello @bloggista,
from what you describe, it seems that there are references in your database to your old domain.
You might want to make sure that all strings which contain your old URL are replaced
https://codex.ww.wp.xz.cn/Moving_WordPress#Changing_Your_Domain_Name_and_URLs
https://interconnectit.com/products/search-and-replace-for-wordpress-databases/
Also, take a look at your wp-config.php and .htaccess file and check for your old URL.
I hope this leads you in a direction which solves your issue.
Hello @petrosini,
1. Is it possible to develop each language of the multisite under a subdomain structure?
It is certainly possible, take a look here: http://codex.ww.wp.xz.cn/Before_You_Create_A_Network#Domain-based
http://codex.ww.wp.xz.cn/Before_You_Create_A_Network#Types_of_multisite_network
One thing to be aware, that the main site by default is nameofthesite.com (is not living under a subdomain). One way to “fix” this is to can create a fourth installation that would act as your primary site and you can redirect the user to the spanish.nameofthesite.com.
2. Is it possible in a multisite to share one single image folder, instead of cloning the image folder when creating a site in the Administration?
By default this functionality is not provided, however, there are plugins which intend to add this functionality, for example, https://ww.wp.xz.cn/plugins/network-shared-media/
Make sure you do a little research about the plugins before you use it, because they come with certain limitations. Read more about the plugin I mentioned here: https://premium.wpmudev.org/blog/how-to-share-media-across-wordpress-multisite/
Forum: Fixing WordPress
In reply to: Extremely new – I'm trying to reinstall WordPress with ssh on nfh.Hello @robbintwobees,
You can reinstall WordPress from the admin panel. Try accessing this URL.
yoursite/wp-admin/update-core.php
and click on the Re-install now
WP-CLI does have an
updatecommand you can run, insteadinstallhttps://wp-cli.org/commands/core/update/
I hope this help
Forum: Installing WordPress
In reply to: non riesco a installare sul mio macHello @chibpm,
Un modo per installarlo è descritto qui
https://codex.ww.wp.xz.cn/Installing_WordPress_Locally_on_Your_Mac_With_MAMP#Step_1:_Installing_MAMPSpero che questo ti aiuta.
Hello @idumlupinar,
In order to PoEdit pick up the strings in the theme they have to be localized.
Read more about this here: https://codex.ww.wp.xz.cn/I18n_for_WordPress_Developers#Strings_for_Translation
Poedit can handle any themes or plugins that are localization-ready. Most of the actively maintained ones are and the ones that aren’t are often easily adapted. WordPress has great documentation on localization.
I hope this helps you.
Forum: Fixing WordPress
In reply to: User password for small follower groupHello @michaelhoppe,
Good news, this is possible!
You accomplish this using a plugin.
Here are some plugins:
https://ww.wp.xz.cn/plugins/password-protected/
https://ww.wp.xz.cn/plugins/hide-my-site/You can search for other plugins as well in the Plugin Directory and decide which one you like best. https://ww.wp.xz.cn/plugins/
Here is how you can install a plugin: https://codex.ww.wp.xz.cn/Managing_Plugins#Automatic_Plugin_Installation
I hope this help you.
Forum: Fixing WordPress
In reply to: Add 'news' section just like blog to my wordpress websiteHello @rpmandavya,
you have another section just like Posts (blogs) with the URL of http://www.thedigitalvibes.com/news/ without using a category.
What you are interested in is creating a custom post type:
https://codex.ww.wp.xz.cn/Post_Types#Custom_Post_Types
You can create a custom post type adding some code into your functions.php or you can use a plugin for that.
Here is a step by step tutorial that covers both versions: http://www.wpbeginner.com/wp-tutorials/how-to-create-custom-post-types-in-wordpress/
I hope this helps.
Forum: Fixing WordPress
In reply to: WordPress automatically removes "Hello @waleed2016,
Can you specify how exactly are you adding this script in your theme? Are you editing your theme file or are you trying to add this code in the content editor or some text widget?
Hello @uxarax,
you might want to consider passing extra parameters to the
get_pagesfunction likesort_columnmaking sure you always get the array of posts back in the order you specified.https://codex.ww.wp.xz.cn/Function_Reference/get_pages#Parameters
Cheers.
Forum: Fixing WordPress
In reply to: Sort pages by template usedHello @mikeshinobi,
since the template of the page is stored in a custom field
_wp_page_template, you can use this to sort the pages.Read more about how to use custom fields for ordering here: https://make.ww.wp.xz.cn/core/2015/03/30/query-improvements-in-wp-4-2-orderby-and-meta_query/
I hope this helps.