Quantcast
Channel: polylang – WordPress.org Forums
Viewing all articles
Browse latest Browse all 11471

Chouby on "[Plugin: Polylang] SQL query for a italian post?"

$
0
0

Do you really need to use a sql query? You can use the get_posts function. For example:

$posts = get_posts(array(
	'numberposts' => -1,
	'nopaging'    => true,
	'post_type'   => 'postitem',
	'post_status' => 'publish',
	'lang'        => 'it',
));

Viewing all articles
Browse latest Browse all 11471

Trending Articles