Customize Buttons
Multiple Buttons - Share Different Pages
Use the following code as a template for configuring multiple buttons to share different links.
<a class="a2a_dd" href="http://www.addtoany.com/share_save">Share Page 1</a>
<script type="text/javascript">
a2a_config = {
linkname: 'Example Page 1',
linkurl: 'http://www.example.com/page_1.html'
};
</script>
<script type="text/javascript" src="http://static.addtoany.com/menu/page.js"></script>
|
<a class="a2a_dd" href="http://www.addtoany.com/share_save">Share Page 2</a>
<script type="text/javascript">
a2a_config.linkname = 'Example Page 2';
a2a_config.linkurl = 'http://www.example.com/page_2.html';
a2a.init('page');
</script>
|
<a class="a2a_dd" href="http://www.addtoany.com/share_save">Share Page 3</a>
<script type="text/javascript">
a2a_config.linkname = 'Example Page 3';
a2a_config.linkurl = 'http://www.example.com/page_3.html';
a2a.init('page');
</script>
Tip: As seen above, the external script (http://static.addtoany.com/menu/page.js) initiates an AddToAny menu on the preceding a2a_dd class name. After the external script has been defined, calling a2a.init('page') for subsequent buttons will also initiate a menu. Either method can be used, but using a2a.init('page') instead of another external script reference can save extra HTTP requests.
Tip: As seen above, the shorthand code for a2a_config should only be used once. Subsequent additions should take the form a2a_config.property = value.
