Forums
-
- Forum
- Posts
-
- Installing BuddyPress
- 23,840
- How-to & Troubleshooting
- 129,881
- Creating & Extending
- 25,910
- Requests & Feedback
- 9,553
- Third Party Plugins
- 9,834
- Showcase
- 3,316
- Ideas
- 1,402
- Miscellaneous
- 9,184
-
Looks okay. I would change:
`foreach ($postcat as $value)`
to
`foreach ((array)$postcat as $value)`
just in case something happens and $postcat isn’t an array.
Have you tried r-a-y’s suggestion for using the `bb_get_postmeta()` and `bb_update_postmeta()` functions rather than a direct query?