Adrian
Adrian

Reputation: 2291

What is wrong with this query in wordpress?

I have the following query

query_posts('category_name='.$settings['categorieslider']&'posts_per_page='.$settings['numberofslides']);

and for some reason it's not working properly.

Upvotes: 1

Views: 55

Answers (2)

StreetCoder
StreetCoder

Reputation: 10061

You should write cat instead of category_name

Upvotes: 1

Bhumi Shah
Bhumi Shah

Reputation: 9476

try below code

query_posts('category_name='.$settings["categorieslider"].'&posts_per_page='.$settings['numberofslides']);

Upvotes: 3

Related Questions