WordPress Shortcodes Guide

The frontend magic of AE Connect is powered by shortcodes. This document is a comprehensive detailing of AE Connect’s shortcodes.

Shortcodes

[ae-link]

This shortcode corresponds to the data-ae-register-link and  data-ae-login-link data tags data tag. More info about AE data tags can be found here.

Attributes:

  • type
    • Determines whether the link will be a login link or a register link
    • Can either be set to register or login
    • default is register
    • Ex) [ae-link type="login"]Login With Spotify[/ae-link]
  • service
    • The service that users may sign in with
    • default is email
    • Ex) [ae-link service="spotify"]Login With Spotify[/ae-link]
  • return (might not be viable)
    • the url that users will be returned to after signing in.
    • default is the client’s homepage
    • Ex) [ae-link service="spotify" return="https://example.com/welcome"]Login With Spotify[/ae-link]

[ae-window]

This shortcode corresponds to the data-ae-register-window and  data-ae-login-window data tags. More info about Appreciation Engine data tags can be found here.

  • type
    • Determines whether the link will be a login link or a register link
    • Can either be set to register or login
    • default is register
    • Ex) [ae-window type="register"]Login With Spotify[/ae-window]
  • return (might not be viable)
    • the url that users will be returned to after signing in.
    • default is the client’s homepage
    • Ex) [ae-window return="https://example.com/welcome"]Login With Spotify[/ae-window]

[ae-form]

This shortcode displays an email password form along with all social logins that the client has enabled at AE Connect settings -> General -> Social

This shortcode accepts no arguments.

[ae-logout]

This shortcode displays a logout link for users to logout of their WP/AE session. This shortcode corresponds to the data-ae-logout-link data tag. More info about Appreciation Engine data tags can be found here.

  • return (might not be viable)
    • the url that users will be returned to after signing in.
    • default is the client’s homepage
    • Ex) [ae-window return="https://example.com/welcome"]Login With Spotify[/ae-window]

[ae-forgot-password]

This shortcode corresponds to verify_reset_password trigger. More info about Appreciation Engine triggers can be found here.

This shortcode accepts no arguments.

Attributes

type

Shortcodes that have this attribute:

  • [ae-link]
  • [ae-window]

arguments:

  • register
  • login

service

Shortcodes that have this attribute:

  • [ae-link]
  • [ae-window]

arguments: (any service that the client has activated)

  • facebook
  • deezer
  • spotify
  • twitter
  • google
  • youtube
  • instagram

(+more)

return

Shortcodes that have this attribute:

  • [ae-link]
  • [ae-window]
  • [ae-logout]

arguments:

  • Any valid URL


Here is a real example of how to use one of these shortcodes:

Goal: Provide your users with Spotify sign-on link that will log them into your WordPress website with Spotify.

The shortcode:

[ae-link type="register" service="spotify"]Register With Spotify[/ae-link]

I've pasted this shortcode into the WordPress page editor like so:




    Here's what it should look like on the front-end of your site (You must be logged out of WordPress in order to see it)



    And when you click the link ...



    You'll see this modal popup, or you will be redirected to a page that has the same content.



    But if you are already signed into Spotify in your browser, but haven't used your Spotify account to sign in to your website, you'll be asked to grant permission to your Spotify app before signup.




    But yours will say Connect with [Whatever you named your Spotify Application]


    That pretty much sums it up! Head back to Step 3 if you're ready! 


    Still got questions? Please feel free to ask us! You can use the blue balloon on our main site, bottom right.



    How did we do?