Link Functions
•add_query_arg()
•remove_query_arg()
Slide 7
Slide 7 text
Link Functions
•home_url( '/' )
Many more in
wp-‐includes/link-‐template.php.
Slide 8
Slide 8 text
FOURTH
Escaping and
Sanitization
Slide 9
Slide 9 text
FIFTH
Nonces
Slide 10
Slide 10 text
SIXTH
Ajax is easy
with WordPress
Slide 11
Slide 11 text
Ajax
• Hook your function to one of two variable
actions
• Use the same action name with the request to
admin-‐ajax.php
•check_ajax_referer() or use a nonce
Slide 12
Slide 12 text
Ajax
•wp_ajax_{$your_action}
•wp_ajax_nopriv_{$your_action}
• Hook to both if logged-in state isn’t relevant.
Slide 13
Slide 13 text
SEVENTH
Database Interactions
Slide 14
Slide 14 text
Database Interactions
• Use custom post types and custom taxonomies
instead.
• If you must, always $wpdb-‐>prepare() your
queries.