ansonphong / postworld

Wordpress Theme Development Framework
GNU General Public License v2.0
7 stars 0 forks source link

pw_query Fields Parameter not Registering #84

Closed ansonphong closed 8 years ago

ansonphong commented 10 years ago

Hi Haidy, I was trying to use the pw_query function and noticed that the fields parameter isn't working currently. No Matter what I enter into it, it returns all.

I see around lines 933 and lines 1039 we're running pw_get_posts() although if I run the same function individually (in a separate file) it's returning the correct results.

Additionally in the prepare_fields() function, I commented out this part

//else if($fields!='preview' && $fields!='ids' && gettype($fields)!='array')
//  $fields='all';

Since field sanitization is already handled inside pw_get_post() - although this didn't solve the issue.

Any ideas?

hmikhail commented 10 years ago

I tried fields = all and edit and ids, working fine.

Could you send the parameters or return of pw_query? (print_r(pw_query($args)))