Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $exists = db_select('node', 'n')
- ->fields('n', array('nid'))
- ->condition('type', 'blog')
- ->condition('uid', $account->uid)
- ->condition('status', 1)
- ->range(0, 1)
- ->addTag('node_access')
- ->execute()
- ->fetchField();
Add Comment
Please, Sign In to add comment