This package runs as a WordPress plugin and includes a few example templates for Auto Amazon Links, a WordPress plugin that generates Amazon links, to help developers start building their own templates.
- Clone this repository to your working directory.
- Rename the root directory,
amazon-auto-links-example-tempaltes
, to something you like such asauto-amazon-links-your-templates
. - Modify the plugin header comment in the plugin main file,
amazon-auto-links-example-templates.php
/**
* Plugin Name: Auto Amazon Links - Example Templates
* Description: Example Auto Amazon Links templates.
* Author: Michael Uno (miunosoft)
* Version: 2.0.0
*/
to your desired one. It should look like
/**
* Plugin Name: Auto Amazon Links - Your Templates
* Description: Does something your want.
* Author: Your Name
* Version: 1.0.0
*/
- Rename the main plugin file name,
amazon-auto-links-example-templates.php
, to something you like such asauto-amazon-links-your-templates.php
. - Rename the namespace defined in PHP files by replacing
AutoAmazonLinks\Templates\Examples
with something you like such asAutoAmazonLinks\Templates\YourTemplates
. - Rename the existing templates directories such as,
lightslider
,minimal
to your desired names such asyour-slider
,your-simplicity
or something. - Start modifying
style.css
in the template directory. - After finishing modifying the stylesheet, take a screenshot of your template and replace
screenshot.jpg
with yours.
In functions.php
, use the wp_enqueue_scripts
and enqueue_embed_scripts
action hooks to call your functions that enqueue resources.
See how the lightslider
template loads JavaScript scripts with the ResourceLoader
class.
In functions.php
, use the aal_filter_template_default_item_format_{template id}
filter hooks to call your functions that enqueue resources.
See how the lighslider
template defines the default Item Format unit option with the OutputFormats
class.
According to the Amazon Associates policy, you should keep the proportions of product thumbnails while resizing them is okay.
(a) You will not add to, delete from, or otherwise alter any Program Content in any way, including by adding additional information, except that you may resize Program Content consisting of a graphic image in a manner that maintains the original proportions of the image or truncate Program Content consisting of text in a manner that does not materially alter the meaning of the text or cause the text to become factually incorrect, or misleading.
Truncating text that does not lead to misleading its original meaning seems to be allowed. When you are uncertain, ask them to be safe.
- Prepare your plugin
readme.txt
- Create a zip file of your plugin files. You can use the export script (tool/export/export.sh)
- Have an account on wordpress.org by singing up if you don't have one yet.
- After logging in, submit a request on wordpress.org from this page.
GPL 2 or later