# Forward

# Get more retweet information

Usually developers want to get some information when the forwarded Weixin Mini Program is opened a second time, such as the identifier of the group. Now by calling wx.showShareMenu and settingwithShareTicketto [[ TAG-5-START]] true, When a user forwards a Mini Program to any group chat, and the forwarding card is opened by another user in the group chat, it can be obtained by [ApageonLaunch]]]((App#onlaunchobject-object)) or [A pageonShow]]]((App#onshowobject-object)) shareTicket。 ThisshareTicket`can get forwarding information by calling the wx.getShareInfo interface.

# Initiate a retweet within the page

Start from base library version 1.2.0. Please remaining backward compatible.

By giving thebuttoncomponent an attributeopen-type = "share",Can trigger Page.onShareAppMessage Event, related component: button .

# Use the guide

The Tweet button is designed to help users share content and services more smoothly with their friends. Posting should be a spontaneous act by the user and within reach when needed. Developers will get a better user experience if they follow the following guidelines when using.

  1. Clarity of meaning: A clear, intuitive graphical button will reduce the time for the user to understand it. In our resource download center, you can find button material like this and use it directly. Or you can have the flexibility to design the style of clearly meaningful buttons according to the design style of your business. Of course, you can also use the copy button directly to "forward to a friend," which is also clear enough.
  2. Convenience of clicking: button clicking hot areas should not be too small or too large. At the same time, the retweet button, like other buttons, should not be too secure in the heat zone so as not to allow the user to misoperate.
  3. Appearance on demand: Not all pages are suitable for placing retweet buttons, nonpublic content involving user privacy, or scenarios that may interrupt the user's current operating experience, and this feature is not recommended. At the same time, because we take screenshots of the user's screen as a rendering during the forwarding process, care should be taken to help users block personal information.
  4. Respect your wishes: Naturally, not all users like to share your Weixin Mini Program with friends.Therefore, it should not be a temptation or a forced action, such as forwarding a feature to unlock it.Please note that such practices are not only not recommended but may also violate our operating practices and we strongly recommend that you read this section before using it.

Above, we have listed the most important points. If you have time, you can browse through the Design Guide and in full, and I'm sure you'll find more.

# Note

  1. When you don't customize the retweet picture, by default, the image of the current page, starting at the top, at an 80 percent screen width, is used as the retweet image.
  2. Debugging support for forwarding see Debugging support for plain forwarding and Forwarding with shareTicket
  3. shareTicketreturns when forwarding non-private messages, only when forwarded to a group chat is opened.shareTicketshareTicketis available for both group chat and single chat when forwarding private messages.See Private Messaging Guide
  4. ShareTicketis valid only for the current Weixin Mini Program life cycle
  5. Due to the policy change, the Weixin Mini Program group-related capabilities are adjusted, and developers can first use the group ID in the [wx.getShareInfo]] interface for functional development.
  6. WeChat 7.0.12 Starting with Weixin Mini Program, it is supported for a group owner to simultaneously set the message as a group to-do message for the group when forwarding, and the group to-dos message appears at the bottom of the chat window as a bubble.By default, each time a group to-do message is forwarded, a to-do bubble is generated.Modification via wx.updateShareMenu interfaceThetoDoActivityIdattribute can aggregate multiple do-it-yourself messages into one, i.e. forward the sametoDaActivityIdgroup do-it messages, and only one do-it message bubble appears.toDoActivityIdneeds to be created via [updatableMessage.createActivityId [[TA-1-END]] interface before forwarding.