Advertisement
Guest User

Untitled

a guest
Jan 22nd, 2020
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.43 KB | None | 0 0
  1. {
  2. // Place your snippets for html here. Each snippet is defined under a snippet name and has a prefix, body and
  3. // description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
  4. // $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the
  5. // same ids are connected.
  6. // Example:
  7. // "Print to console": {
  8. // "prefix": "log",
  9. // "body": [
  10. // "console.log('$1');",
  11. // "$2"
  12. // ],
  13. // "description": "Log output to console"
  14. // }
  15.  
  16. "if have_rows()": {
  17. "prefix": "irows",
  18. "body": ["<?php if(have_rows('$1')): $2"],
  19. "description": "if have_rows"
  20. },
  21. "while have_rows()": {
  22. "prefix": "wrows",
  23. "body": ["<?php while(have_rows('$1')): the_row(); $2"],
  24. "description": "while have_rows"
  25. },
  26. "php": {
  27. "prefix": "php",
  28. "body": ["<?php $1;?>"],
  29. "description": "php"
  30. },
  31. "the_field()": {
  32. "prefix": "tfield",
  33. "body": ["<?php the_field('$1');?>"],
  34. "description": "the_field"
  35. },
  36. "get_field()": {
  37. "prefix": "gfield",
  38. "body": ["<?php echo get_field('$1');?>"],
  39. "description": "get_field"
  40. },
  41. "the_sub_field()": {
  42. "prefix": "tsfield",
  43. "body": ["<?php the_sub_field('$1');?>"],
  44. "description": "the_field"
  45. },
  46. "get_sub_field()": {
  47. "prefix": "gsfield",
  48. "body": ["<?php echo get_sub_field('$1');?>"],
  49. "description": "get_field"
  50. },
  51. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement