<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Body - Themespress</title>
	<atom:link href="https://themespress.ca/en/sujets/body/feed/" rel="self" type="application/rss+xml" />
	<link>https://themespress.ca/en/</link>
	<description>Des tutoriels et ressources WordPress</description>
	<lastBuildDate>Sun, 18 Sep 2022 17:06:36 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1</generator>

<image>
	<url>https://themespress.ca/wp-content/uploads/2020/10/cropped-Favicon-Themepress.ca_-32x32.png</url>
	<title>Body - Themespress</title>
	<link>https://themespress.ca/en/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Formidable Form: Display User&#8217;s IP</title>
		<link>https://themespress.ca/en/formidable-form-display-users-ip/</link>
					<comments>https://themespress.ca/en/formidable-form-display-users-ip/#respond</comments>
		
		<dc:creator><![CDATA[Daniel]]></dc:creator>
		<pubDate>Mon, 27 Jul 2020 20:43:03 +0000</pubDate>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Body]]></category>
		<category><![CDATA[Forms]]></category>
		<category><![CDATA[Plugins]]></category>
		<guid isPermaLink="false">https://themespress.ca/?p=4000</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[<div class="wpb-content-wrapper"><div class="vc_row wpb_row vc_row-fluid"><div class="wpb_column vc_column_container vc_col-sm-12"><div class="vc_column-inner"><div class="wpb_wrapper">
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>This tutorial will show you how to fetch your user&#8217;s ID and IP address and display it under the Admin column in the WordPress dashboard.</p>
<p>First off, how to fetch the user&#8217;s IP address with the form. In your form, <a href="https://shareasale.com/r.cfm?b=841990&amp;u=1476870&amp;m=64739&amp;urllink=&amp;afftrack=" target="_blank" rel="noopener noreferrer"><strong>Formidable Form</strong></a>, we will create a hidden form and in its advanced parameters, we will look up a default value which will be the IP address.<br />

<a href='https://themespress.ca/wp-content/uploads/2020/07/Get-IP.jpg'><img decoding="async" width="150" height="150" src="https://themespress.ca/wp-content/uploads/2020/07/Get-IP-150x150.jpg" class="attachment-thumbnail size-thumbnail" alt="" srcset="https://themespress.ca/wp-content/uploads/2020/07/Get-IP-150x150.jpg 150w, https://themespress.ca/wp-content/uploads/2020/07/Get-IP-100x100.jpg 100w" sizes="(max-width: 150px) 100vw, 150px" /></a>
<a href='https://themespress.ca/wp-content/uploads/2020/07/IP.jpg'><img decoding="async" width="150" height="150" src="https://themespress.ca/wp-content/uploads/2020/07/IP-150x150.jpg" class="attachment-thumbnail size-thumbnail" alt="" srcset="https://themespress.ca/wp-content/uploads/2020/07/IP-150x150.jpg 150w, https://themespress.ca/wp-content/uploads/2020/07/IP-100x100.jpg 100w" sizes="(max-width: 150px) 100vw, 150px" /></a>
</p>
<p>Donc concrètement, quand l&#8217;utilisateur va poster son formulaire, ça va avoir l&#8217;adresse IP en champ caché. When a user will send the form, the hidden form will contain their IP. The next step will be to display it in a column in the WordPress user section.</p>
<p>We will add two new filters <a href="http://hookr.io/filters/manage_users_columns/" target="_blank" rel="noopener noreferrer"><strong>manage_users_columns</strong></a> and <a href="https://developer.wordpress.org/reference/hooks/manage_users_custom_column/" target="_blank" rel="noopener noreferrer"><strong>manage_users_custom_column</strong></a></p>

		</div>
	</div>
<div id="ts-enlighterjs-container-8226239" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-8226239" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="custom" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">function add_column( $column ) {
    $column[&#039;userip&#039;] = &#039;IP utilisateur&#039;;
    return $column;
}
add_filter( &#039;manage_users_columns&#039;, &#039;add_column&#039; );

/*this will add column value in user list table*/
function add_column_value( $val, $column_name, $user_id ) {
   switch ($column_name) {
        case &#039;userip&#039; :
	// Remplacer 1094 par l&#039;ID du champ cach&eacute; de votre formulaire IP Adress
        return FrmProEntriesController::get_field_value_shortcode(array(&#039;field_id&#039; =&amp;gt; 1094, &#039;entry&#039; =&amp;gt; $entry_id, &#039;user_id&#039; =&amp;gt; $user_id));
        break;
        default:
    }
    return $val; 
}
add_filter( &#039;manage_users_custom_column&#039;, &#039;add_column_value&#039;, 10, 3 );</pre></div>
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>Pour obtenir notre valeur IP de l&#8217;utilisateur, nous allons utiliser <a href="https://formidableforms.com/knowledgebase/get-a-value-from-an-entry/" target="_blank" rel="noopener noreferrer"><strong>FrmProEntriesController::get_field_value_shortcode</strong></a> that will allow you to display the Formidable form&#8217;s value of the field and inclure an argument is necessary.</p>
<p>In our return Query, we have added the following arguments: <strong>field_id</strong>, <strong>entry</strong>, and <strong>user_id</strong>  matching the user&#8217;s ID in the results table. This means, for example, to fetch the value matching the ID 1094 of each value each user ID.<br />
<strong><br />
NB: Make sure to do a backup of your theme, files and database before proceeding with these tutorials.</strong></p>

		</div>
	</div>
</div></div></div></div>
</div><p>The post <a href="https://themespress.ca/en/formidable-form-display-users-ip/">Formidable Form: Display User’s IP</a> first appeared on <a href="https://themespress.ca/en/">Themespress</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://themespress.ca/en/formidable-form-display-users-ip/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>How to Display WordPress User&#8217;s ID</title>
		<link>https://themespress.ca/en/how-to-display-wordpress-users-id/</link>
					<comments>https://themespress.ca/en/how-to-display-wordpress-users-id/#respond</comments>
		
		<dc:creator><![CDATA[Daniel]]></dc:creator>
		<pubDate>Thu, 25 Jun 2020 13:59:01 +0000</pubDate>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Body]]></category>
		<category><![CDATA[Users]]></category>
		<guid isPermaLink="false">https://themespress.ca/?p=4004</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[<div class="wpb-content-wrapper"><div class="vc_row wpb_row vc_row-fluid"><div class="wpb_column vc_column_container vc_col-sm-12"><div class="vc_column-inner"><div class="wpb_wrapper">
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>In this tutorial, we will configure a function that will allow us to display WordPress admin users&#8217; IDs. We will use the following filter:  <a href="https://developer.wordpress.org/reference/hooks/manage_users_custom_column/" target="_blank" rel="noopener noreferrer">manage_users_custom_column</a></p>

		</div>
	</div>
<div id="ts-enlighterjs-container-6417687" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-6417687" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="custom" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">function addo_custom_add_user_id_column($columns) {
    $columns[&#039;user_id&#039;] = &#039;User ID&#039;;
    return $columns;
}
add_filter(&#039;manage_users_columns&#039;, &#039;addo_custom_add_user_id_column&#039;);
//Adds Content To The Custom Added Column
function addo_show_user_id_column_content($value, $column_name, $user_id) {
    $user = get_userdata( $user_id );
    if ( &#039;user_id&#039; == $column_name )
        return $user_id;
    return $value;
}
add_filter(&#039;manage_users_custom_column&#039;,  &#039;addo_show_user_id_column_content&#039;, 10, 3);</pre></div>
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>After configuring this filter, you can also use <a href="https://developer.wordpress.org/reference/hooks/pre_get_users/" target="_blank" rel="noopener noreferrer">pre_get_users</a> in order to sort the users&#8217; IDs. <strong><a href="https://themespress.ca/utilisateurs-wordpress-trier-en-ordre-par-id/" target="_blank" rel="noopener noreferrer">WordPress users: Sort by ID</a></strong></p>

		</div>
	</div>
</div></div></div></div>
</div><p>The post <a href="https://themespress.ca/en/how-to-display-wordpress-users-id/">How to Display WordPress User’s ID</a> first appeared on <a href="https://themespress.ca/en/">Themespress</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://themespress.ca/en/how-to-display-wordpress-users-id/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>How to Add Pages/Posts IDs In WordPress Admin Columns</title>
		<link>https://themespress.ca/en/adding-pages-posts-ids-wordpress-admin-columns/</link>
					<comments>https://themespress.ca/en/adding-pages-posts-ids-wordpress-admin-columns/#respond</comments>
		
		<dc:creator><![CDATA[Daniel]]></dc:creator>
		<pubDate>Tue, 09 Jun 2020 16:59:15 +0000</pubDate>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Body]]></category>
		<category><![CDATA[Users]]></category>
		<guid isPermaLink="false">https://themespress.ca/?p=4006</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[<div class="wpb-content-wrapper"><div class="vc_row wpb_row vc_row-fluid"><div class="wpb_column vc_column_container vc_col-sm-12"><div class="vc_column-inner"><div class="wpb_wrapper">
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>With this tutorial, we will show you how to use two filters that will allow us to display the pages and posts ID in properly identified columns in the WordPress users section of your website. The first filter will build the properly identified column <a href="https://codex.wordpress.org/Plugin_API/Filter_Reference/manage_pages_columns" target="_blank" rel="noopener noreferrer">manage_pages_columns</a> and <a href="https://codex.wordpress.org/Plugin_API/Filter_Reference/manage_posts_columns" target="_blank" rel="noopener noreferrer">manage_posts_columns</a>.</p>
<p>Once that&#8217;s done, we want to display the IDs in our columns. Two more filters are required: <a href="https://codex.wordpress.org/Plugin_API/Action_Reference/manage_posts_custom_column" target="_blank" rel="noopener noreferrer">manage_posts_custom_column</a> and <a href="https://developer.wordpress.org/reference/hooks/manage_pages_custom_column/" target="_blank" rel="noopener noreferrer">manage_pages_custom_column</a>.</p>
<p>These filters can also be used for custom post types sometimes used to generate portfolios, testimonials, products, etc&#8230;</p>

		</div>
	</div>
<div id="ts-enlighterjs-container-7864656" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-7864656" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="custom" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">add_filter( &#039;manage_pages_columns&#039;, &#039;pages_add_id_column&#039;, 5 );
add_action( &#039;manage_pages_custom_column&#039;, &#039;pages_id_column_content&#039;, 5, 2 );
function pages_add_id_column( $columns ) {
   $columns[&#039;monid&#039;] = &#039;ID&#039;;
   return $columns;
}

function pages_id_column_content( $column, $id ) {
  if( &#039;monid&#039; == $column ) {
    echo $id;
  }
}


add_filter( &#039;manage_posts_columns&#039;, &#039;posts_add_id_column&#039;, 5 );
add_action( &#039;manage_posts_custom_column&#039;, &#039;posts_id_column_content&#039;, 5, 2 );
function posts_add_id_column( $columns ) {
   $columns[&#039;monid&#039;] = &#039;ID&#039;;
   return $columns;
}

function posts_id_column_content( $column, $id ) {
  if( &#039;monid&#039; == $column ) {
    echo $id;
  }
}</pre></div></div></div></div></div>
</div><p>The post <a href="https://themespress.ca/en/adding-pages-posts-ids-wordpress-admin-columns/">How to Add Pages/Posts IDs In WordPress Admin Columns</a> first appeared on <a href="https://themespress.ca/en/">Themespress</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://themespress.ca/en/adding-pages-posts-ids-wordpress-admin-columns/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>How to Disable Gutenberg</title>
		<link>https://themespress.ca/en/how-to-disable-gutenberg/</link>
					<comments>https://themespress.ca/en/how-to-disable-gutenberg/#respond</comments>
		
		<dc:creator><![CDATA[Daniel]]></dc:creator>
		<pubDate>Fri, 18 Jan 2019 20:30:05 +0000</pubDate>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Body]]></category>
		<category><![CDATA[Filters]]></category>
		<guid isPermaLink="false">https://themespress.ca/?p=4213</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[<div class="wpb-content-wrapper"><div class="vc_row wpb_row vc_row-fluid"><div class="wpb_column vc_column_container vc_col-sm-12"><div class="vc_column-inner"><div class="wpb_wrapper">
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>Since version 5.0, WordPress has implemented a new visual CMS tool called Gutenberg.</p>
<p>Given that a lot of WordPress users have been using custom CMS plugins, using Gutenberg can cause multiple problems and headaches for users who have been using WordPress with their custom tools for years. Also some users might find it more cumbersome and complicated to use; especially when used with a different method for quite some time.</p>
<p>The filters below will allow you to easily disable Gutenberg and keep working like you&#8217;ve been for the last few years.</p>

		</div>
	</div>
<h2 style="text-align: left" class="vc_custom_heading vc_do_custom_heading" >Disable Content Manager - Gutenberg</h2><div id="ts-enlighterjs-container-5919760" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-5919760" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">////////////////////////Disable Gutenberg ///////////////////////
add_filter(&#039;use_block_editor_for_post&#039;, &#039;__return_false&#039;, 10); 
// disable for post types 
add_filter(&#039;use_block_editor_for_post_type&#039;, &#039;__return_false&#039;, 10);</pre></div><h2 style="text-align: left" class="vc_custom_heading vc_do_custom_heading" >Disable Widgets Manager - Gutenberg</h2><div id="ts-enlighterjs-container-3812554" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-3812554" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">////////////////////// Disable Widgets Manager - Gutenberg
if ( ! function_exists( &#039;viamulti_activate_classic_widgets&#039; ) ) :
function viamulti_activate_classic_widgets() {
    remove_theme_support( &#039;widgets-block-editor&#039; );
}
endif;
add_action( &#039;after_setup_theme&#039;, &#039;viamulti_activate_classic_widgets&#039; );</pre></div></div></div></div></div>
</div><p>The post <a href="https://themespress.ca/en/how-to-disable-gutenberg/">How to Disable Gutenberg</a> first appeared on <a href="https://themespress.ca/en/">Themespress</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://themespress.ca/en/how-to-disable-gutenberg/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Sort by Post Type in WordPress Admin Columns</title>
		<link>https://themespress.ca/en/sort-by-post-type-in-wordpress-admin-columns/</link>
					<comments>https://themespress.ca/en/sort-by-post-type-in-wordpress-admin-columns/#respond</comments>
		
		<dc:creator><![CDATA[Daniel]]></dc:creator>
		<pubDate>Mon, 12 Nov 2018 11:55:03 +0000</pubDate>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Body]]></category>
		<category><![CDATA[Users]]></category>
		<guid isPermaLink="false">https://themespress.ca/?p=4217</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[<div class="wpb-content-wrapper"><div class="vc_row wpb_row vc_row-fluid"><div class="wpb_column vc_column_container vc_col-sm-12"><div class="vc_column-inner"><div class="wpb_wrapper">
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>With this tutorial, we will show you how to sort post type results in WordPress admin by sorting with a post type meta key in numerical order. </p>
<p>So let&#8217;s say for example that you want to sort by ID the job post type from highest to lowest. First, we will need to build the necessary columns for our Job post type.</p>
<p>So here&#8217;s to adding our id-job column; make sure to change the post type name. </p>

		</div>
	</div>
<div id="ts-enlighterjs-container-6602437" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-6602437" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">//////////////////////////////////// Admin columns Informations Post Type /////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////////////
add_filter( &#039;manage_emplois_posts_columns&#039;, &#039;themespress_custom_mycpt_columns&#039; );
function themespress_custom_mycpt_columns( $columns ) {
  $columns[&#039;id-emploi&#039;] = __( &#039;Id de l&#039;emploi&#039;, &#039;themespress&#039; );
  return $columns;
}</pre></div>
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>We will display our results in the column by following the instruction; if we want to add more columns.</p>

		</div>
	</div>
<div id="ts-enlighterjs-container-3026821" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-3026821" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">add_filter( &#039;manage_emplois_posts_columns&#039;, &#039;themespress_custom_edit_mycpt_columns&#039; );
function themespress_custom_edit_mycpt_columns( $columns ) {
//////////////////////////////////// Admin columns Informations Post Type /////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////////////
  switch ( $column ) {
    case &#039;id-emploi&#039; :
	// On appelle notre meta key
        echo get_post_meta( $post_id, &#039;id-emploi&#039;, true );
	break;
    }
}</pre></div>
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>We will now do our parse_query that will enable us to sort our Job ID from highest to lowest. We add a condition &#8220;return&#8221; if we are not in the WP admin.</p>

		</div>
	</div>
<div id="ts-enlighterjs-container-8139163" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-8139163" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">add_filter( &#039;parse_query&#039;, &#039;themespress_custom_post_sort&#039; );
function themespress_custom_post_sort($query) {
 
    if ( ! is_admin() )
        return $query;
 
    global $current_screen;
    if ( isset( $current_screen ) &amp;&amp; &#039;emplois&#039; === $current_screen-&gt;post_type ) {
        $query-&gt;query_vars[&#039;orderby&#039;]  = &#039;meta_value&#039;;
        $query-&gt;query_vars[&#039;meta_key&#039;] = &#039;id-emploi&#039;;
        $query-&gt;query_vars[&#039;order&#039;]    = &#039;DESC&#039;;
    }
}</pre></div></div></div></div></div>
</div><p>The post <a href="https://themespress.ca/en/sort-by-post-type-in-wordpress-admin-columns/">Sort by Post Type in WordPress Admin Columns</a> first appeared on <a href="https://themespress.ca/en/">Themespress</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://themespress.ca/en/sort-by-post-type-in-wordpress-admin-columns/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Create a Custom Link for your Template Pages</title>
		<link>https://themespress.ca/en/create-a-custom-link-for-your-template-pages/</link>
					<comments>https://themespress.ca/en/create-a-custom-link-for-your-template-pages/#respond</comments>
		
		<dc:creator><![CDATA[Daniel]]></dc:creator>
		<pubDate>Sat, 03 Dec 2016 20:40:22 +0000</pubDate>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Body]]></category>
		<category><![CDATA[Functions]]></category>
		<category><![CDATA[Themes]]></category>
		<guid isPermaLink="false">https://themespress.ca/?p=6236</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[<div class="wpb-content-wrapper"><div class="vc_row wpb_row vc_row-fluid"><div class="wpb_column vc_column_container vc_col-sm-12"><div class="vc_column-inner"><div class="wpb_wrapper">
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>This tutorial will show you how to create a custom link for your template page: <strong>get_page_link</strong>.</p>
<p>First thing we need to do is create our template page in the root folder of our WordPress theme.</p>

		</div>
	</div>
<h2 style="text-align: left" class="vc_custom_heading vc_do_custom_heading" >Create a template page: For example: User Favorites</h2><div id="ts-enlighterjs-container-9897635" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-9897635" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="standard" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">&lt;?php
/**
 * Recent User Favorites
 *
 * This file contains the markup for recent entries displayed in the
 * 404 pages of the Prime theme.
 *
 * @package Nomdutheme
 */
?&gt;</pre></div>
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>The next step is creating the new page in WordPress Admin and associate it to the newly created template.</p>
<p>We will use a query, Post type, to match with our template page with the  <strong>_wp_page_template</strong> meta Key and our template name as a value (Remplace <strong>user-profile.php</strong> by your template page). We will ask to return your page on demand.</p>

		</div>
	</div>
<div id="ts-enlighterjs-container-5569474" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-5569474" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">function viadirectory_userprofile_id() {
	$args = [
	&#039;post_type&#039;     =&gt; &#039;page&#039;,
	&#039;fields&#039;        =&gt; &#039;ids&#039;,
	&#039;nopaging&#039;      =&gt; true,
	&#039;meta_key&#039;      =&gt; &#039;_wp_page_template&#039;,
	&#039;meta_value&#039;    =&gt; &#039;user-profile.php&#039;
	];
	$pages = get_posts( $args );
	foreach ( $pages as $page ) 
	return $page;
}</pre></div>
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>We will now create our custom permalink in order to load up the desired template. You can also add a custom CSS styling.</p>
<p>We will be using the <strong><a href="https://codex.wordpress.org/Function_Reference/get_page_link" target="_blank" rel="noopener">get_page_link</a></strong> function and include another function, viadirectory_userprofile_id(), which returns the page query.</p>

		</div>
	</div>
<div id="ts-enlighterjs-container-2497412" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-2497412" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="php" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">&lt;ul&gt;
 	&lt;li style=&quot;list-style-type: none;&quot;&gt;
 	&lt;li class=&quot;&lt;?php if (is_page_template(&#039;user-profile.php&#039;)) { echo &#039;active&#039;; } else {}; ?&gt;&quot;&gt;&lt;/l&gt;
&lt;/ul&gt;
</pre></div>
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>You now have a dynamic link that loads the desired <a href="https://developer.wordpress.org/themes/template-files-section/page-template-files/page-templates/" target="_blank" rel="noopener">Template Page</a>.</p>

		</div>
	</div>
</div></div></div></div>
</div><p>The post <a href="https://themespress.ca/en/create-a-custom-link-for-your-template-pages/">Create a Custom Link for your Template Pages</a> first appeared on <a href="https://themespress.ca/en/">Themespress</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://themespress.ca/en/create-a-custom-link-for-your-template-pages/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>WordPress Via Sidebar: Sidebar Generator Plugin</title>
		<link>https://themespress.ca/en/wordpress-via-sidebar-sidebar-generator-plugin/</link>
					<comments>https://themespress.ca/en/wordpress-via-sidebar-sidebar-generator-plugin/#respond</comments>
		
		<dc:creator><![CDATA[Daniel]]></dc:creator>
		<pubDate>Thu, 04 Feb 2016 14:34:37 +0000</pubDate>
				<category><![CDATA[Plugins]]></category>
		<category><![CDATA[Body]]></category>
		<guid isPermaLink="false">https://themespress.ca/?p=6435</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[<div class="wpb-content-wrapper"><div class="vc_row wpb_row vc_row-fluid"><div class="wpb_column vc_column_container vc_col-sm-12"><div class="vc_column-inner"><div class="wpb_wrapper">
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>Our <strong>WordPress Via Sidebar</strong> plugin allows users to generate as many sidebars as they need for a post or page..</p>
<h2>Functionalities:</h2>
<p>Choose the number of sidebar to create<br />
Display a Sidebar ID by default<br />
Generate or delete sidebars<br />
Select which sidebar to display for your posts and pages<br />
Display the complete list of sidebars available<br />
Easy to use function for your sidebar.php file</p>
<p>For WordPress beginners, we offer additional information under &#8220;How to use sidebars with the Plugin WordPress Via Sidebar plugin&#8221;.</p>
<p><strong>Version : 2.1.2<br />
Last updated: July 14 2021</strong></p>
<p><a class="more" href="/en/products/plugins-wordpress/via-sidebar-wordpress-plugin/">WordPress Via Sidebar</a> plugin</p>

		</div>
	</div>
</div></div></div></div>
</div><p>The post <a href="https://themespress.ca/en/wordpress-via-sidebar-sidebar-generator-plugin/">WordPress Via Sidebar: Sidebar Generator Plugin</a> first appeared on <a href="https://themespress.ca/en/">Themespress</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://themespress.ca/en/wordpress-via-sidebar-sidebar-generator-plugin/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
