Using Memberstack 2.0? There is an updated version of this article here.
Available links and attributes to make your site look and feel like a web app.
About this article:
-
Difficulty level: Easy - information based
-
Technical background needed: Beginner - information based
-
Estimated read time: 2 mins
What and Why?
Memberstack integrates with your website via links and/or data attributes. This article lists all available links and attributes and explains each one's purpose.
Click here to see All Available Links →
Click here to see All Available Data Attributes →
Links
Signup & upgrade links
A new signup link is dynamically generated when you create a new Membership. By default, this link will launch the signup modal. However, it also acts as a downgrade and upgrade link for returning members.
#/ms/signup/{{membershipID}}
Login links
This link launches the login modal. Learn more →
#/ms/login
Profile modal link
Launch the member profile modal. This link is only visible to members. Learn more.
#/ms/profile
Hide a link to members-only content
Add the following code to links to members-only content. You can find the contentID on your Memberships page after you create a membership with members-only content. Note: Adding a ! before the contentID will invert the links visibility.
.../#/ms/content/{{contentID}}
Password reset link
Launch the password reset modal. See it in action →
#/ms/password-reset
Logout links
Automatically logs a member out of their current session. Only visible for members.
#/ms/logout
Hide a link from active members
Links with this code are only visible to new users who don't have an account. Add this to the end of a link.
.../#/ms/content/!members
Data Attributes
Note: Data attributes are only supported by a few website builders. If your site builder doesn't allow you to add attributes, see above for some equivalent links.
Attributes to hide/edit site content
data-ms-member="fieldID"
Will replace the text of an element with the user data you specify when placed on a contact form, div, span, link, or image.
data-ms-member="signup-field-ID"
data-ms-content="contentID"
Tag an element as members-only content. Add the following attribute to members-only content. You can find the contentID on your Memberships page after you create a membership with members-only content.
data-ms-content="contentID"
data-ms-content="!members"
Hide content from all active members.
data-ms-content="!members"
data-ms-content=“members”
Hide content from all non-members.
data-ms-content=“members”
Forms and input field attributes
data-ms-member="fieldID"
Will collect, display, or update members' data when placed on an input (field) inside of a Memberstack form.
data-ms-member="signup-field-ID"
data-ms-member="id"
Will replace the text of an element with the member id when placed on a contact form, div, span, link, or image.
data-ms-member="id"
data-ms-form="signup"
Specifies what form you would like to use as a signup form.
data-ms-form="signup"
data-ms-membership="membershipID"
Specifies what membership you would like to use on a signup form. This is in addition to the data-ms-form="signup" on the form element.
data-ms-membership="membershipID"
data-ms-form="login"
Specifies what form you would like to use as a login form.
data-ms-form="login"
data-ms-form="profile"
Collect or update user info to store in Memberstack.
Note: You can only update custom fields with this attribute. Member email and passwords must be updated in Memberstack's profile modal instead.
data-ms-form="profile"
----------------------------------------------------
Archived attributes
ms-email="true"
ms-password="true"
ms-field="ID"
ms-hide="ID"
ms-hide-element="true"
ms-hide-member="ID"
ms-logout="true"
ms-profile="true"
ms-update="profile"
ms-rewrite="VALUE"
ms-forgot="true"
ms-signup="true"
ms-login="true"
ms-forgot="true"
data-ms-rewrite="your-input"
Keywords: links, attributes, profile, modal, login, logout, profile, signup, content, member, reset, field, upgrade
Comments
0 comments
Please sign in to leave a comment.