Blog

Read our blogs and explore more about latest updates, tips, tricks, turorials and features. TheOnlineHelper offers multiple categories in blogs to help you choose your favourtie piece of writing.

Blog

  1. How to get Currency data: Code, Rate, Symbol in Magento 2

    There are the steps to get the currency data like code, rate, and symbol in Magento 2 create the block class Get the output of the currency data in phtml file Create the block class Directory app/code/VendorName/ModuleName/Block/Demo.php Content of Demo.php <?phpnamespace VendorName\ModuleName\Block;class Demo extends \
    Read more
  2. How to get Logo url, Image Url, Alt text, Logo size in Magento 2 Programmatically

    There are the steps to get logo url, image url, Alt text and logo size in magento 2 create the block class Declare function in template (.phtml) file Create the block class Directory app/code/VendorName/ModuleName/Block/Demo.php Content of Demo.php <?phpnamespace VendorName\ModuleName\Block;class Demo extends \Magento\Framework\View\
    Read more
  3. How to Add Command line in to Console CLI in Magento 2

    Follow these steps add the command line in to console CLI in magento 2. create the di.xml create command class Create di.xml file  In di.xml file you will define the command. Directory app/code/VendorName/ModuleName/etc/di.xml  Content of di.xml <?xml version="1.0"?><config xmlns:xsi="http://www.w3.org/2001/XMLSchema-
    Read more
  4. How to get store information in Magento 2 Programmatically

    There are the following steps to get the store information in Magento 2: Create the block class Get store information in phtml file Create the block class Directory app/code/VendorName/ModuleName/Block/Demo.php Content of Demo.php <?phpnamespace VendorName\ModuleName\Block;class Demo extends \Magento\Framework\View\Element\Template{
    Read more
  5. How to Create and Assign Customer Group in Magento 2

    To create the customer group follow these steps: Go to Admin Panel, click on the CUSTOMERS > Customer groups. Click on the Add New Customer Group button. In the field of Group Name, set the group name. Select the Tax Class. In the field of Excluded Website, Select websites you want to exclude from this customer group. Click on the Save
    Read more
  6. How to Create/Save Admin Grid in Magento 2

    Follow the following steps to create the admin grid in Magento 2: Create database schema Create routes admin Create admin menu Create Controller Create Admin Grid using Component Create Admin Grid using Layout Create database schema Create the database file in the setup directory. Directory app/code/VendorName/ModuelName/Setup/
    Read more
  7. How to Create a Catalog Price Rule in Magento 2

    There are the following steps to create the cart price rule in Magento 2 Create a New Catalog Price Rule Set the Catalog Price Conditions Set the Catalog Price Actions Apply the Rule Create a new Catalog rule Go to Admin Panel, click on the Marketing > Promotions >Catalog Price Rule. To add a new rule, click on the Add New Rule
    Read more
  8. How to Setup Promotions / Cart Price Rules in Magento 2

    There are the following steps to create the cart price rule in Magento 2 Create a New Cart Price Rule Set the Cart Price Conditions Set the Cart Price Actions Set the Cart Price Labels Apply the Rule Create a new cart rule Go to Admin Panel, click on the Marketing > Promotions > Cart Price Rule. To add a new rule, click on the
    Read more
  9. How to Set Production Mode in Magento 2

    <h2 id="show-current-magento-2-mode">Show current Magento 2 Mode</h2> <p>Run the following command to show the current mode:</p> <pre class="highlight"><code>php bin/magento deploy:mode:show</code></pre> <p>Currently, we are in default mode. We can set to&nbsp;<strong>Production
    Read more
  10. How to Add Custom Discount in Magento 2

    <h3>Enter a total in the&nbsp;sale.xml&nbsp;file</h3> <p><strong>Directory</strong></p> <p>app/code/VendorName/ModuleName/etc/sales.xml</p> <p><strong>Content for this file</strong></p> <pre class="highlight"><code>&lt;config xmlns:xsi="http://www.w3
    Read more

Items 41-50 of 238

Show per page