Gift wrap extension User guide – Magento 2

Home » Gift wrap extension User guide – Magento 2

Overview 

Gift Wrap magento 2 extension offers customers to choose gift wrap option to products and add personalized gift message. Best Magento gift wrap plugin available in the market for magento 2 at lower price. Easy to setup.

Installation Steps for Gift Wrapper magento 2 Extension:

1.  Upload Extension files to the server

Upload the extension files inside Magento Installation folder.  Magento_App_Root folder is same as your Magento 2 Installation directory. Take a backup of the Magento files before replacing

2. Run Installation commands in SSH

Login to your server with SSH (using putty or similar tool).  Go to your Magento root folder (Usually public_html folder) and run commands below. This is the standard Magento extension installation procedure.

2 a) Enable Gift wrap modules using command below:

php bin/magento module:enable Globalecom_Giftwrapper

php bin/magento module:enable Globalecom_Giftmessage

2 b) Run upgrade command: (This is a standard Magento command)

php bin/magento setup:upgrade

2 c) Run di Compile command (Optional)

php -d memory_limit=-1 bin/magento setup:di:compile

2 d) Redeploy static content (Optional)

php -d memory_limit=-1 bin/magento setup:static-content:deploy

3. Verify if the module is listed:

After opening Stores ­>> Configuration­ >> Advanced­ >> Advanced, the module will be shown in the admin panel.

Configuration

1. Setup Gift wrap products and category in admin panel

Step 1: Add Products and Assign under Giftwrapper Category. These products are like Gift wrap options. Example: Green Gift Wrap. These options are displayed in Shopping cart page.

1 a) Admin Panel->>Products -> >Catalog -> >Add Product

Note: Choose attribute set as “default” while adding a new product.

1 b) Admin Panel->>Products -> >Categories -> >Add Gift Wrapper Category. Note down Category Id

2: Add a new Static block for Gift Wrapper

Admin Panel -> Content -> Blocks -> Add New block

Page Title: Choose Gift Wrapper
Self URL: giftwrap
Status: Enabled

Content: {{block class="Magento\Framework\View\Element\Template" name="catalog.product.choosegiftwrapper"  columnCount="5" template="Globalecom_Giftwrapper::product/choosegiftwrapper.phtml"}}

3. Set category id in front end phtml file

Step 1:Add the below code at end of the cart.phtml file, you can find the file path of cart.phtml by enabling template hints and viewing shopping cart page

echo $block->getLayout()->createBlock('Magento\Cms\Block\Block')->setBlockId('giftwrap')->toHtml();

Step 2: Open choosegiftwrapper.phtml file from the following location app/code/Globalecom/Giftwrapper/view/frontend/templates/product

Add gift wrapper category id in line no 35 in that file. Scroll up and Refer this section – Configuration # 1b to know the category id that you noted in admin.

Step 3: Finally clear cache of the website .Admin->>System->>Cache Management

Testing

1. Gift wrap function in front end

Open your Website -> Select a product -> Add to Cart -> View Shopping Cart page

Then add gift products  to cart and give message

2. Verify Gift wrap data in Admin back end

You can see gift wrap item and gift message in Admin->>Sales->>Orders

Questions

If you have any questions or issues, please contact technical support team via https://mage-extensions-themes.com/support/