Magento 2 :: Add custom class in referenceContainer using xml

Added device-hardware class

<referenceContainer name="main.content" htmlTag="main" htmlId="maincontent" htmlClass="page-main device-hardware"/>

Advertisements

Magento 2 :: JQuery Format

<script type="text/javascript">
	require(['jquery','jquery/ui'], function ($) {
	    $("#descrptn_link").click(function() {
	        if ($(window).scrollTop() > 170) {
	            $('html, body').animate({
	            scrollTop: $("#descrptn").offset().top + 45}, 2000);
	        }
	        else{
	            $('html, body').animate({
	            scrollTop: $("#descrptn").offset().top - 90}, 2000);
	        }
	    });
	});
</script>

Ubuntu : send email from local server

Install SSMTP packet:

sudo apt-get install ssmtp

open the configuration file:

sudo nano /etc/ssmtp/ssmtp.conf

Add new content as below (don’t forget change your_email and your_email_password, your_email_username):

Root=your_email@gmail.com
Mailhub=smtp.gmail.com:465
RewriteDomain=gmail.com
AuthUser=your_gmail_username # (before the @gmail.com part)
AuthPass=your_gmail_password
FromLineOverride=Yes
UseTLS=Yes

At last, do a test:

echo testing|mail -s 'Test Mail' example@gmail.com

Magento: All Events Listing

Here is the list of magento events:

File Name Event
Mage/Admin/Model/Session.php admin_session_user_login_success
Mage/Admin/Model/Session.php admin_session_user_login_failed
Mage/Admin/Model/User.php admin_user_authenticate_before
Mage/Admin/Model/User.php admin_user_authenticate_after
Mage/Adminhtml/Block/Api/User.php api_user_html_before
Mage/Adminhtml/Block/Catalog/Category/Tab/Attributes.php adminhtml_catalog_category_edit_prepare_form
Mage/Adminhtml/Block/Catalog/Category/Tabs.php adminhtml_catalog_category_tabs
Mage/Adminhtml/Block/Catalog/Category/Tree.php adminhtml_catalog_category_tree_is_moveable
Mage/Adminhtml/Block/Catalog/Category/Tree.php adminhtml_catalog_category_tree_can_add_root_category
Mage/Adminhtml/Block/Catalog/Category/Tree.php adminhtml_catalog_category_tree_can_add_sub_category
Mage/Adminhtml/Block/Catalog/Product/Attribute/Edit/Tab/Main.php adminhtml_product_attribute_types
Mage/Adminhtml/Block/Catalog/Product/Attribute/Edit/Tab/Main.php adminhtml_catalog_product_attribute_edit_prepare_form
Mage/Adminhtml/Block/Catalog/Product/Attribute/New/Product/Attributes.php adminhtml_catalog_product_edit_prepare_form
Mage/Adminhtml/Block/Catalog/Product/Attribute/New/Product/Attributes.php adminhtml_catalog_product_edit_element_types
Mage/Adminhtml/Block/Catalog/Product/Attribute/Set/Main.php adminhtml_catalog_product_attribute_set_main_html_before
Mage/Adminhtml/Block/Catalog/Product/Attribute/Set/Toolbar/Main.php adminhtml_catalog_product_attribute_set_toolbar_main_html_before
Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute/Tab/Attributes.php adminhtml_catalog_product_form_prepare_excluded_field_list
Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Attributes/Create.php adminhtml_catalog_product_edit_tab_attributes_create_html_before
Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Attributes.php adminhtml_catalog_product_edit_prepare_form
Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Attributes.php adminhtml_catalog_product_edit_element_types
Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Price/Recurring.php catalog_product_edit_form_render_recurring
Mage/Adminhtml/Block/Catalog/Product/Grid.php adminhtml_catalog_product_grid_prepare_massaction
Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Gallery/Content.php catalog_product_gallery_prepare_layout
Mage/Adminhtml/Block/Cms/Page/Edit/Tab/Content.php adminhtml_cms_page_edit_tab_content_prepare_form
Mage/Adminhtml/Block/Cms/Page/Edit/Tab/Design.php adminhtml_cms_page_edit_tab_design_prepare_form
Mage/Adminhtml/Block/Cms/Page/Edit/Tab/Main.php adminhtml_cms_page_edit_tab_main_prepare_form
Mage/Adminhtml/Block/Cms/Page/Edit/Tab/Meta.php adminhtml_cms_page_edit_tab_meta_prepare_form
Mage/Adminhtml/Block/Customer/Edit/Tab/Carts.php adminhtml_block_html_before
Mage/Adminhtml/Block/Permissions/User.php permissions_user_html_before
Mage/Adminhtml/Block/Promo/Catalog/Edit/Tab/Main.php adminhtml_promo_catalog_edit_tab_main_prepare_form
Mage/Adminhtml/Block/Promo/Quote/Edit/Tab/Actions.php adminhtml_block_salesrule_actions_prepareform
Mage/Adminhtml/Block/Promo/Quote/Edit/Tab/Coupons/Form.php adminhtml_promo_quote_edit_tab_coupons_form_prepare_form
Mage/Adminhtml/Block/Promo/Quote/Edit/Tab/Main.php adminhtml_promo_quote_edit_tab_main_prepare_form
Mage/Adminhtml/Block/Promo/Widget/Chooser.php adminhtml_block_promo_widget_chooser_prepare_collection
Mage/Adminhtml/Block/Report/Grid.php adminhtml_widget_grid_filter_collection
Mage/Adminhtml/Block/Sales/Reorder/Renderer/Action.php adminhtml_customer_orders_add_action_renderer
Mage/Adminhtml/Block/System/Config/Form/Fieldset/Modules/DisableOutput.php adminhtml_system_config_advanced_disableoutput_render_before
Mage/Adminhtml/Block/System/Config/Tabs.php adminhtml_block_system_config_init_tab_sections_before
Mage/Adminhtml/Block/System/Store/Edit/Form.php adminhtml_store_edit_form_prepare_form
Mage/Adminhtml/Block/Template.php adminhtml_block_html_before
Mage/Adminhtml/Block/Widget/Container.php adminhtml_widget_container_html_before
Mage/Adminhtml/Controller/Action.php adminhtml_controller_action_predispatch_start
Mage/Adminhtml/controllers/CacheController.php adminhtml_cache_flush_all
Mage/Adminhtml/controllers/CacheController.php adminhtml_cache_flush_system
Mage/Adminhtml/controllers/CacheController.php adminhtml_cache_refresh_type
Mage/Adminhtml/controllers/CacheController.php clean_media_cache_after
Mage/Adminhtml/controllers/CacheController.php clean_catalog_images_cache_after
Mage/Adminhtml/controllers/Catalog/CategoryController.php category_prepare_ajax_response
Mage/Adminhtml/controllers/Catalog/CategoryController.php catalog_category_prepare_save
Mage/Adminhtml/controllers/Catalog/CategoryController.php catalog_controller_category_delete
Mage/Adminhtml/controllers/Catalog/Product/Action/AttributeController.php catalog_product_to_website_change
Mage/Adminhtml/controllers/Catalog/Product/GalleryController.php catalog_product_gallery_upload_image_after
Mage/Adminhtml/controllers/Catalog/ProductController.php catalog_product_new_action
Mage/Adminhtml/controllers/Catalog/ProductController.php catalog_product_edit_action
Mage/Adminhtml/controllers/Catalog/ProductController.php catalog_product_prepare_save
Mage/Adminhtml/controllers/Catalog/ProductController.php catalog_controller_product_delete
Mage/Adminhtml/controllers/Cms/PageController.php cms_page_prepare_save
Mage/Adminhtml/controllers/Cms/PageController.php adminhtml_cmspage_on_delete
Mage/Adminhtml/controllers/Cms/PageController.php adminhtml_cmspage_on_delete
Mage/Adminhtml/controllers/CustomerController.php adminhtml_customer_prepare_save
Mage/Adminhtml/controllers/CustomerController.php adminhtml_customer_save_after
Mage/Adminhtml/controllers/Permissions/RoleController.php admin_permissions_role_prepare_save
Mage/Adminhtml/controllers/Promo/CatalogController.php adminhtml_controller_catalogrule_prepare_save
Mage/Adminhtml/controllers/Promo/QuoteController.php adminhtml_controller_salesrule_prepare_save
Mage/Adminhtml/controllers/ReportController.php on_view_report
Mage/Adminhtml/controllers/Sales/Order/CreateController.php adminhtml_sales_order_create_process_data_before
Mage/Adminhtml/controllers/Sales/Order/CreateController.php adminhtml_sales_order_create_process_data
Mage/Adminhtml/controllers/Sales/Order/CreditmemoController.php adminhtml_sales_order_creditmemo_register_before
Mage/Adminhtml/controllers/System/Config/System/StorageController.php add_synchronize_message
Mage/Adminhtml/controllers/System/ConfigController.php admin_system_config_section_save_after
Mage/Adminhtml/controllers/System/ConfigController.php admin_system_config_changed_section_{$section}
Mage/Adminhtml/controllers/System/Convert/ProfileController.php $adapter->getEventPrefix(
Mage/Adminhtml/controllers/System/StoreController.php store_group_save
Mage/Adminhtml/controllers/System/StoreController.php $eventName
Mage/Adminhtml/controllers/System/StoreController.php store_delete
Mage/Adminhtml/Model/Config/Data.php model_config_data_save_before
Mage/Adminhtml/Model/Config.php adminhtml_init_system_config
Mage/Adminhtml/Model/Sales/Order/Create.php sales_convert_order_to_quote
Mage/Adminhtml/Model/Sales/Order/Create.php sales_convert_order_item_to_quote_item
Mage/Adminhtml/Model/Sales/Order/Create.php checkout_submit_all_after
Mage/Api/Model/User.php api_user_authenticated
Mage/Bundle/Block/Catalog/Product/View/Type/Bundle.php bundle_product_view_config
Mage/Bundle/Model/Product/Price.php prepare_catalog_product_collection_prices
Mage/Bundle/Model/Product/Price.php catalog_product_get_final_price
Mage/Bundle/Model/Product/Price.php catalog_product_get_final_price
Mage/Bundle/Model/Resource/Indexer/Price.php catalog_product_prepare_index_select
Mage/Bundle/Model/Resource/Indexer/Price.php prepare_catalog_product_price_index_table
Mage/Bundle/Model/Resource/Price/Index.php catalog_product_prepare_index_select
Mage/Catalog/Block/Product/Abstract.php catalog_block_product_status_display
Mage/Catalog/Block/Product/List/Upsell.php catalog_product_upsell
Mage/Catalog/Block/Product/List.php catalog_block_product_list_collection
Mage/Catalog/Block/Product/View/Type/Configurable.php catalog_product_type_configurable_price
Mage/Catalog/Block/Product/View.php catalog_product_view_config
Mage/Catalog/controllers/CategoryController.php catalog_controller_category_init_before
Mage/Catalog/controllers/CategoryController.php catalog_controller_category_init_after
Mage/Catalog/controllers/Product/CompareController.php catalog_product_compare_add_product
Mage/Catalog/controllers/Product/CompareController.php catalog_product_compare_remove_product
Mage/Catalog/Helper/Output.php catalog_helper_output_construct
Mage/Catalog/Helper/Product/View.php catalog_controller_product_view
Mage/Catalog/Helper/Product.php catalog_controller_product_init_before
Mage/Catalog/Helper/Product.php catalog_controller_product_init
Mage/Catalog/Model/Category.php catalog_category_tree_move_before
Mage/Catalog/Model/Category.php $this->_eventPrefix.’_move_before
Mage/Catalog/Model/Category.php $this->_eventPrefix.’_move_after
Mage/Catalog/Model/Category.php category_move
Mage/Catalog/Model/Convert/Adapter/Product.php $this->_eventPrefix . ‘_after
Mage/Catalog/Model/Product/Action.php catalog_product_attribute_update_before
Mage/Catalog/Model/Product/Action.php catalog_product_website_update_before
Mage/Catalog/Model/Product/Action.php catalog_product_website_update
Mage/Catalog/Model/Product/Attribute/Backend/Media.php catalog_product_media_save_before
Mage/Catalog/Model/Product/Attribute/Backend/Media.php catalog_product_media_add_image
Mage/Catalog/Model/Product/Attribute/Source/Inputtype.php adminhtml_product_attribute_types
Mage/Catalog/Model/Product/Option/Api.php catalog_product_prepare_save
Mage/Catalog/Model/Product/Status.php catalog_product_status_update
Mage/Catalog/Model/Product/Type/Abstract.php $eventName
Mage/Catalog/Model/Product/Type/Configurable/Price.php catalog_product_get_final_price
Mage/Catalog/Model/Product/Type/Configurable/Price.php catalog_product_type_configurable_price
Mage/Catalog/Model/Product/Type/Grouped/Price.php catalog_product_type_grouped_price
Mage/Catalog/Model/Product/Type/Price.php catalog_product_get_final_price
Mage/Catalog/Model/Product.php $this->_eventPrefix.’_validate_before
Mage/Catalog/Model/Product.php $this->_eventPrefix.’_validate_after
Mage/Catalog/Model/Product.php catalog_model_product_duplicate
Mage/Catalog/Model/Product.php catalog_product_is_salable_before
Mage/Catalog/Model/Product.php catalog_product_is_salable_after
Mage/Catalog/Model/Product.php $this->_eventPrefix.’_delete_after_done
Mage/Catalog/Model/Resource/Category/Collection.php $this->_eventPrefix . ‘_load_before
Mage/Catalog/Model/Resource/Category/Collection.php $this->_eventPrefix . ‘_load_after
Mage/Catalog/Model/Resource/Category/Collection.php $this->_eventPrefix . ‘_add_is_active_filter
Mage/Catalog/Model/Resource/Category/Flat/Collection.php $this->_eventPrefix . ‘_load_before
Mage/Catalog/Model/Resource/Category/Flat/Collection.php $this->_eventPrefix . ‘_load_after
Mage/Catalog/Model/Resource/Category/Flat/Collection.php $this->_eventPrefix . ‘_add_is_active_filter
Mage/Catalog/Model/Resource/Category/Flat.php catalog_category_tree_init_inactive_category_ids
Mage/Catalog/Model/Resource/Category/Flat.php catalog_category_flat_loadnodes_before
Mage/Catalog/Model/Resource/Category/Tree.php catalog_category_tree_init_inactive_category_ids
Mage/Catalog/Model/Resource/Category/Tree.php catalog_category_tree_move_before
Mage/Catalog/Model/Resource/Category/Tree.php catalog_category_tree_move_after
Mage/Catalog/Model/Resource/Category.php catalog_category_change_products
Mage/Catalog/Model/Resource/Layer/Filter/Price.php catalogindex_prepare_price_select
Mage/Catalog/Model/Resource/Layer/Filter/Price.php catalog_prepare_price_select
Mage/Catalog/Model/Resource/Product/Collection.php catalog_prepare_price_select
Mage/Catalog/Model/Resource/Product/Collection.php catalog_product_collection_load_before
Mage/Catalog/Model/Resource/Product/Collection.php catalog_product_collection_load_after
Mage/Catalog/Model/Resource/Product/Collection.php catalog_product_collection_before_add_count_to_categories
Mage/Catalog/Model/Resource/Product/Collection.php catalog_product_collection_apply_limitations_before
Mage/Catalog/Model/Resource/Product/Collection.php catalog_product_collection_apply_limitations_after
Mage/Catalog/Model/Resource/Product/Compare/Item/Collection.php catalog_product_compare_item_collection_clear
Mage/Catalog/Model/Resource/Product/Flat/Indexer.php catalog_product_flat_prepare_columns
Mage/Catalog/Model/Resource/Product/Flat/Indexer.php catalog_product_flat_prepare_indexes
Mage/Catalog/Model/Resource/Product/Flat/Indexer.php catalog_product_flat_rebuild
Mage/Catalog/Model/Resource/Product/Flat/Indexer.php catalog_product_flat_update_product
Mage/Catalog/Model/Resource/Product/Indexer/Eav/Abstract.php prepare_catalog_product_index_select
Mage/Catalog/Model/Resource/Product/Indexer/Eav/Decimal.php prepare_catalog_product_index_select
Mage/Catalog/Model/Resource/Product/Indexer/Eav/Source.php prepare_catalog_product_index_select
Mage/Catalog/Model/Resource/Product/Indexer/Eav/Source.php prepare_catalog_product_index_select
Mage/Catalog/Model/Resource/Product/Indexer/Price/Default.php prepare_catalog_product_index_select
Mage/Catalog/Model/Resource/Product/Indexer/Price/Default.php prepare_catalog_product_price_index_table
Mage/Catalog/Model/Resource/Product/Indexer/Price/Grouped.php catalog_product_prepare_index_select
Mage/CatalogIndex/Model/Data/Abstract.php catalogindex_get_minimal_price
Mage/CatalogIndex/Model/Indexer.php catalogindex_plain_reindex_after
Mage/CatalogIndex/Model/Indexer.php catalogindex_prepare_price_select
Mage/CatalogIndex/Model/Resource/Price.php catalogindex_prepare_price_select
Mage/CatalogIndex/Model/Resource/Price.php catalogindex_prepare_price_select
Mage/CatalogIndex/Model/Resource/Price.php catalogindex_prepare_price_select
Mage/CatalogIndex/Model/Resource/Price.php catalogindex_prepare_price_select
Mage/CatalogSearch/Model/Fulltext.php catalogsearch_index_process_start
Mage/CatalogSearch/Model/Fulltext.php catalogsearch_index_process_complete
Mage/CatalogSearch/Model/Resource/Advanced.php catalog_prepare_price_select
Mage/CatalogSearch/Model/Resource/Fulltext.php catalogsearch_reset_search_result
Mage/CatalogSearch/Model/Resource/Fulltext.php catelogsearch_searchable_attributes_load_after
Mage/Checkout/controllers/CartController.php checkout_cart_add_product_complete
Mage/Checkout/controllers/CartController.php checkout_cart_update_item_complete
Mage/Checkout/controllers/MultishippingController.php checkout_controller_multishipping_shipping_post
Mage/Checkout/controllers/MultishippingController.php checkout_multishipping_controller_success_action
Mage/Checkout/controllers/OnepageController.php checkout_onepage_controller_success_action
Mage/Checkout/controllers/OnepageController.php checkout_controller_onepage_save_shipping_method
Mage/Checkout/Helper/Data.php checkout_allow_guest
Mage/Checkout/Model/Cart/Api.php checkout_type_onepage_save_order_after
Mage/Checkout/Model/Cart/Api.php checkout_submit_all_after
Mage/Checkout/Model/Cart.php checkout_cart_product_add_after
Mage/Checkout/Model/Cart.php checkout_cart_update_items_before
Mage/Checkout/Model/Cart.php checkout_cart_update_items_after
Mage/Checkout/Model/Cart.php checkout_cart_save_before
Mage/Checkout/Model/Cart.php checkout_cart_save_after
Mage/Checkout/Model/Cart.php checkout_cart_product_update_after
Mage/Checkout/Model/Session.php custom_quote_process
Mage/Checkout/Model/Session.php checkout_quote_init
Mage/Checkout/Model/Session.php load_customer_quote_before
Mage/Checkout/Model/Session.php checkout_quote_destroy
Mage/Checkout/Model/Type/Multishipping.php checkout_type_multishipping_set_shipping_items
Mage/Checkout/Model/Type/Multishipping.php checkout_type_multishipping_create_orders_single
Mage/Checkout/Model/Type/Multishipping.php checkout_submit_all_after
Mage/Checkout/Model/Type/Multishipping.php checkout_multishipping_refund_all
Mage/Checkout/Model/Type/Onepage.php checkout_type_onepage_save_order_after
Mage/Checkout/Model/Type/Onepage.php checkout_submit_all_after
Mage/Cms/Controller/Router.php cms_controller_router_match_before
Mage/Cms/Helper/Page.php cms_page_render
Mage/Cms/Helper/Wysiwyg/Images.php cms_wysiwyg_images_static_urls_allowed
Mage/Cms/Model/Page.php cms_page_get_available_statuses
Mage/Cms/Model/Wysiwyg/Config.php cms_wysiwyg_config_prepare
Mage/Core/Block/Abstract.php core_block_abstract_prepare_layout_before
Mage/Core/Block/Abstract.php core_block_abstract_prepare_layout_after
Mage/Core/Block/Abstract.php core_block_abstract_to_html_before
Mage/Core/Block/Abstract.php core_block_abstract_to_html_after
Mage/Core/Controller/Response/Http.php http_response_send_before
Mage/Core/Controller/Response/Http.php controller_response_redirect
Mage/Core/Controller/Varien/Action.php controller_action_layout_load_before
Mage/Core/Controller/Varien/Action.php controller_action_layout_generate_xml_before
Mage/Core/Controller/Varien/Action.php controller_action_layout_generate_blocks_before
Mage/Core/Controller/Varien/Action.php controller_action_layout_generate_blocks_after
Mage/Core/Controller/Varien/Action.php controller_action_layout_render_before
Mage/Core/Controller/Varien/Action.php controller_action_layout_render_before_’.$this->getFullActionName(
Mage/Core/Controller/Varien/Action.php controller_action_predispatch
Mage/Core/Controller/Varien/Action.php controller_action_predispatch_’ . $this->getRequest(
Mage/Core/Controller/Varien/Action.php controller_action_predispatch_’ . $this->getFullActionName(
Mage/Core/Controller/Varien/Action.php controller_action_postdispatch_’.$this->getFullActionName(
Mage/Core/Controller/Varien/Action.php controller_action_postdispatch_’.$this->getRequest(
Mage/Core/Controller/Varien/Action.php controller_action_postdispatch
Mage/Core/Controller/Varien/Action.php controller_action_noroute
Mage/Core/Controller/Varien/Action.php controller_action_nocookies
Mage/Core/Controller/Varien/Front.php controller_front_init_before
Mage/Core/Controller/Varien/Front.php controller_front_init_routers
Mage/Core/Controller/Varien/Front.php controller_front_send_response_before
Mage/Core/Controller/Varien/Front.php controller_front_send_response_after
Mage/Core/Helper/Data.php $eventName
Mage/Core/Model/Abstract.php model_load_before
Mage/Core/Model/Abstract.php $this->_eventPrefix.’_load_before
Mage/Core/Model/Abstract.php model_load_after
Mage/Core/Model/Abstract.php $this->_eventPrefix.’_load_after
Mage/Core/Model/Abstract.php model_save_commit_after
Mage/Core/Model/Abstract.php $this->_eventPrefix.’_save_commit_after
Mage/Core/Model/Abstract.php model_save_before
Mage/Core/Model/Abstract.php $this->_eventPrefix.’_save_before
Mage/Core/Model/Abstract.php model_save_after
Mage/Core/Model/Abstract.php $this->_eventPrefix.’_save_after
Mage/Core/Model/Abstract.php model_delete_before
Mage/Core/Model/Abstract.php $this->_eventPrefix.’_delete_before
Mage/Core/Model/Abstract.php model_delete_after
Mage/Core/Model/Abstract.php $this->_eventPrefix.’_delete_after
Mage/Core/Model/Abstract.php model_delete_commit_after
Mage/Core/Model/Abstract.php $this->_eventPrefix.’_delete_commit_after
Mage/Core/Model/Abstract.php $this->_eventPrefix.’_clear
Mage/Core/Model/App.php application_clean_cache
Mage/Core/Model/Layout/Update.php core_layout_update_updates_get_after
Mage/Core/Model/Layout.php core_layout_block_create_after
Mage/Core/Model/Locale.php core_locale_set_locale
Mage/Core/Model/Locale.php currency_display_options_forming
Mage/Core/Model/Observer.php core_clean_cache
Mage/Core/Model/Resource/Db/Collection/Abstract.php core_collection_abstract_load_before
Mage/Core/Model/Resource/Db/Collection/Abstract.php $this->_eventPrefix.’_load_before
Mage/Core/Model/Resource/Db/Collection/Abstract.php core_collection_abstract_load_after
Mage/Core/Model/Resource/Db/Collection/Abstract.php $this->_eventPrefix.’_load_after
Mage/Core/Model/Resource.php resource_get_tablename
Mage/Core/Model/Session/Abstract.php core_session_abstract_clear_messages
Mage/Core/Model/Session/Abstract.php core_session_abstract_add_message
Mage/CurrencySymbol/Model/System/Currencysymbol.php admin_system_config_changed_section_currency_before_reinit
Mage/CurrencySymbol/Model/System/Currencysymbol.php admin_system_config_changed_section_currency
Mage/Customer/controllers/AccountController.php customer_register_success
Mage/Customer/Helper/Data.php customer_registration_is_allowed
Mage/Customer/Model/Address/Abstract.php customer_address_format
Mage/Customer/Model/Customer.php customer_customer_authenticated
Mage/Customer/Model/Session.php customer_session_init
Mage/Customer/Model/Session.php customer_login
Mage/Customer/Model/Session.php customer_logout
Mage/Eav/Block/Adminhtml/Attribute/Edit/Main/Abstract.php adminhtml_block_eav_attribute_edit_form_init
Mage/Eav/Model/Entity/Collection/Abstract.php eav_collection_abstract_load_before
Mage/GiftMessage/Block/Message/Inline.php gift_options_prepare_items
Mage/GiftMessage/Model/Api/V2.php magento/Mage/GiftMessage/Model/Api/V2.php
Mage/GiftMessage/Model/Api/V2.php checkout_controller_onepage_save_shipping_method
Mage/GiftMessage/Model/Api.php magento/Mage/GiftMessage/Model/Api.php
Mage/GiftMessage/Model/Api.php checkout_controller_onepage_save_shipping_method
Mage/GoogleBase/controllers/Adminhtml/Googlebase/TypesController.php controller_action_postdispatch_adminhtml
Mage/GoogleCheckout/Block/Link.php googlecheckout_block_link_html_before
Mage/GoogleCheckout/controllers/RedirectController.php googlecheckout_checkout_before
Mage/GoogleCheckout/Model/Api/Xml/Callback.php googlecheckout_create_order_before
Mage/GoogleCheckout/Model/Api/Xml/Callback.php googlecheckout_save_order_after
Mage/GoogleCheckout/Model/Api/Xml/Callback.php checkout_submit_all_after
Mage/GoogleCheckout/Model/Api/Xml/Checkout.php google_checkout_discount_item_price
Mage/GoogleCheckout/Model/Api.php googlecheckout_api_deliver_carriers_array
Mage/ImportExport/Model/Import/Entity/Product.php catalog_product_import_finish_before
Mage/Index/Model/Indexer.php start_index_events’ . $this->_getEventTypeName($entity
Mage/Index/Model/Indexer.php end_index_events’ . $this->_getEventTypeName($entity
Mage/Index/Model/Indexer.php start_process_event’ . $this->_getEventTypeName($entityType
Mage/Index/Model/Indexer.php end_process_event’ . $this->_getEventTypeName($entityType
Mage/Index/Model/Process.php after_reindex_process_’ . $this->getIndexerCode(
Mage/Index/Model/Process.php index_process_change_status
Mage/Log/Model/Resource/Log.php log_log_clean_before
Mage/Log/Model/Resource/Log.php log_log_clean_after
Mage/Log/Model/Resource/Visitor/Collection.php log_visitor_collection_load_before
Mage/Log/Model/Visitor.php visitor_init
Mage/Page/Block/Html/Topmenu.php page_block_html_topmenu_gethtml_before
Mage/Page/Block/Html/Topmenu.php page_block_html_topmenu_gethtml_after
Mage/Payment/Block/Form/Cc.php payment_form_block_to_html_before
Mage/Payment/Block/Info.php payment_info_block_prepare_specific_information
Mage/Payment/Model/Method/Abstract.php payment_method_is_active
Mage/Paypal/Model/Cart.php paypal_prepare_line_items
Mage/Paypal/Model/Payment/Transaction.php $this->_eventPrefix . ‘_load_by_txn_id_before
Mage/Paypal/Model/Payment/Transaction.php $this->_eventPrefix . ‘_load_by_txn_id_after
Mage/Persistent/controllers/IndexController.php persistent_session_expired
Mage/Persistent/Model/Observer.php persistent_session_expired
Mage/Poll/controllers/VoteController.php poll_vote_add
Mage/Reports/Model/Resource/Order/Collection.php sales_prepare_amount_expression
Mage/Review/controllers/ProductController.php review_controller_product_init_before
Mage/Review/controllers/ProductController.php review_controller_product_init
Mage/Review/Model/Resource/Review/Collection.php review_review_collection_load_before
Mage/Rss/Block/Catalog/Category.php rss_catalog_category_xml_callback
Mage/Rss/Block/Catalog/New.php rss_catalog_new_xml_callback
Mage/Rss/Block/Catalog/NotifyStock.php rss_catalog_notify_stock_collection_select
Mage/Rss/Block/Catalog/Review.php rss_catalog_review_collection_select
Mage/Rss/Block/Catalog/Special.php rss_catalog_special_xml_callback
Mage/Rss/Block/Catalog/Tag.php rss_catalog_tagged_item_xml_callback
Mage/Rss/Block/Order/New.php rss_order_new_collection_select
Mage/Rss/Block/Wishlist.php rss_wishlist_xml_callback
Mage/Rule/Model/Environment.php rule_environment_collect
Mage/Sales/Model/Convert/Order.php sales_convert_order_to_quote
Mage/Sales/Model/Convert/Quote.php sales_convert_quote_to_order
Mage/Sales/Model/Convert/Quote.php sales_convert_quote_address_to_order
Mage/Sales/Model/Convert/Quote.php sales_convert_quote_address_to_order_address
Mage/Sales/Model/Convert/Quote.php sales_convert_quote_payment_to_order_payment
Mage/Sales/Model/Convert/Quote.php sales_convert_quote_item_to_order_item
Mage/Sales/Model/Observer.php clear_expired_quotes_before
Mage/Sales/Model/Order/Creditmemo.php sales_order_creditmemo_refund
Mage/Sales/Model/Order/Creditmemo.php sales_order_creditmemo_cancel
Mage/Sales/Model/Order/Invoice.php sales_order_invoice_pay
Mage/Sales/Model/Order/Invoice.php sales_order_invoice_cancel
Mage/Sales/Model/Order/Invoice.php sales_order_invoice_register
Mage/Sales/Model/Order/Item.php sales_order_item_cancel
Mage/Sales/Model/Order/Payment/Transaction.php $this->_eventPrefix . ‘_load_by_txn_id_before
Mage/Sales/Model/Order/Payment/Transaction.php $this->_eventPrefix . ‘_load_by_txn_id_after
Mage/Sales/Model/Order/Payment.php sales_order_payment_place_start
Mage/Sales/Model/Order/Payment.php sales_order_payment_place_end
Mage/Sales/Model/Order/Payment.php sales_order_payment_capture
Mage/Sales/Model/Order/Payment.php sales_order_payment_pay
Mage/Sales/Model/Order/Payment.php sales_order_payment_cancel_invoice
Mage/Sales/Model/Order/Payment.php sales_order_payment_void
Mage/Sales/Model/Order/Payment.php sales_order_payment_refund
Mage/Sales/Model/Order/Payment.php sales_order_payment_cancel_creditmemo
Mage/Sales/Model/Order/Payment.php sales_order_payment_cancel
Mage/Sales/Model/Order/Pdf/Abstract.php pdf_item_draw_after
Mage/Sales/Model/Order.php sales_order_place_before
Mage/Sales/Model/Order.php sales_order_place_after
Mage/Sales/Model/Order.php order_cancel_after
Mage/Sales/Model/Quote/Address/Total/Discount.php sales_quote_address_discount_item
Mage/Sales/Model/Quote/Address/Total/Discount.php sales_quote_address_discount_item
Mage/Sales/Model/Quote/Address.php $this->_eventPrefix . ‘_collect_totals_before
Mage/Sales/Model/Quote/Address.php $this->_eventPrefix . ‘_collect_totals_after
Mage/Sales/Model/Quote/Config.php sales_quote_config_get_product_attributes
Mage/Sales/Model/Quote/Item.php sales_quote_item_qty_set_after
Mage/Sales/Model/Quote/Item.php sales_quote_item_set_product
Mage/Sales/Model/Quote/Payment.php $this->_eventPrefix . ‘_import_data_before
Mage/Sales/Model/Quote.php sales_quote_remove_item
Mage/Sales/Model/Quote.php sales_quote_add_item
Mage/Sales/Model/Quote.php sales_quote_product_add_after
Mage/Sales/Model/Quote.php $this->_eventPrefix . ‘_collect_totals_before
Mage/Sales/Model/Quote.php $this->_eventPrefix . ‘_collect_totals_after
Mage/Sales/Model/Quote.php $this->_eventPrefix . ‘_merge_before
Mage/Sales/Model/Quote.php $this->_eventPrefix . ‘_merge_after
Mage/Sales/Model/Resource/Order/Abstract.php $this->_eventPrefix . ‘_init_virtual_grid_columns
Mage/Sales/Model/Resource/Order/Abstract.php $this->_eventPrefix . ‘_update_grid_records
Mage/Sales/Model/Resource/Order/Abstract.php $this->_eventPrefix . ‘_save_attribute_before
Mage/Sales/Model/Resource/Order/Abstract.php $this->_eventPrefix . ‘_save_attribute_after
Mage/Sales/Model/Resource/Order/Address/Collection.php $this->_eventPrefix . ‘_load_after
Mage/Sales/Model/Resource/Order/Collection/Abstract.php $this->_eventPrefix . ‘_set_sales_order
Mage/Sales/Model/Resource/Quote/Address/Collection.php $this->_eventPrefix.’_load_after
Mage/Sales/Model/Resource/Quote/Item/Collection.php prepare_catalog_product_collection_prices
Mage/Sales/Model/Resource/Quote/Item/Collection.php sales_quote_item_collection_products_after_load
Mage/Sales/Model/Resource/Sale/Collection.php sales_sale_collection_query_before
Mage/Sales/Model/Service/Quote.php checkout_type_onepage_save_order
Mage/Sales/Model/Service/Quote.php sales_model_service_quote_submit_success
Mage/Sales/Model/Service/Quote.php sales_model_service_quote_submit_failure
Mage/Sales/Model/Service/Quote.php sales_model_service_quote_submit_after
Mage/SalesRule/Model/Quote/Discount.php sales_quote_address_discount_item
Mage/SalesRule/Model/Quote/Discount.php sales_quote_address_discount_item
Mage/SalesRule/Model/Rule/Condition/Combine.php salesrule_rule_condition_combine
Mage/SalesRule/Model/Rule.php salesrule_rule_get_coupon_types
Mage/SalesRule/Model/Validator.php salesrule_validator_process
Mage/Sendfriend/controllers/ProductController.php sendfriend_product
Mage/Tag/Model/Resource/Indexer/Summary.php prepare_catalog_product_index_select
Mage/Tag/Model/Resource/Product/Collection.php tag_tag_product_collection_load_after
Mage/Tax/Model/Calculation/Rate.php tax_settings_change_after
Mage/Tax/Model/Calculation/Rate.php tax_settings_change_after
Mage/Tax/Model/Calculation/Rate.php tax_settings_change_after
Mage/Tax/Model/Calculation/Rule.php tax_settings_change_after
Mage/Tax/Model/Calculation/Rule.php tax_settings_change_after
Mage/Tax/Model/Calculation.php tax_rate_data_fetch
Mage/Wishlist/Block/Customer/Wishlist/Item/Options.php product_option_renderer_init
Mage/Wishlist/controllers/IndexController.php wishlist_add_product
Mage/Wishlist/controllers/IndexController.php wishlist_update_item
Mage/Wishlist/controllers/IndexController.php wishlist_share
Mage/Wishlist/Helper/Data.php wishlist_items_renewed
Mage/Wishlist/Model/Resource/Item/Collection.php wishlist_item_collection_products_after_load
Mage/Wishlist/Model/Wishlist.php wishlist_item_add_after
Mage/Wishlist/Model/Wishlist.php wishlist_add_item
Mage/Wishlist/Model/Wishlist.php wishlist_product_add_after
Mage/XmlConnect/Controller/AdminAction.php adminhtml_controller_action_predispatch_start
Mage/XmlConnect/controllers/CartController.php checkout_cart_add_product_complete
Mage/XmlConnect/controllers/CartController.php enterprise_giftcardaccount_add
Mage/XmlConnect/controllers/CartController.php checkout_cart_update_item_complete
Mage/XmlConnect/controllers/CheckoutController.php checkout_controller_onepage_save_shipping_method
Mage/XmlConnect/controllers/CheckoutController.php checkout_controller_onepage_save_shipping_method
Mage/XmlConnect/controllers/ReviewController.php review_controller_product_init_before
Mage/XmlConnect/controllers/ReviewController.php review_controller_product_init
Mage/XmlConnect/controllers/WishlistController.php wishlist_add_product
Mage/XmlConnect/Model/Queue.php before_save_message_queue
/cron.php always
/cron.php $cronMode
/shell/indexer.php shell_reindex_init_process
/shell/indexer.php $process->getIndexerCode(
/shell/indexer.php shell_reindex_finalize_process

Magento2 : Product Collection

Get Award winning product where award winning is a custom attribute.

/* Get Award Winning prduct list
     * @return $collection
    */
    public function getAwardWinningProduct(){
        
        $productcollection =    $this->_objectManager->create('Magento\Catalog\Model\ResourceModel\Product\Collection')
                                ->addAttributeToSelect('*')
                                ->addAttributeToFilter('status', array('eq' => 1))
                                ->addAttributeToFilter('award_winning', array('eq' => 1));

        return $productcollection;
    }

Full page code of Data helper file

<?php
/**
* Techievolve
*
* NOTICE OF LICENSE
*
* This source file is subject to the marketplace.techievolve.com license that is 
* http://marketplace.techievolve.com/license-agreement.html
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade this extension to newer
* version in the future.
*
* @category Techievolve
* @package Techievolve_Vgod
* @module vgod
* @author Techievolve Developer* <support@techievolve.com>
* @copyright Copyright (c) 2018 Techievolve (http://marketplace.techievolve.com/)
* @license http://marketplace.techievolve.com/license-agreement.html
*/

namespace Techievolve\Vgod\Helper;
 
/**
 * Techievolve Vgod Helper
*/
 
Class Data extends \Magento\Framework\App\Helper\AbstractHelper {

    protected $_scopeConfig;
    protected $_httpFactory;
    protected $_storeManager;
    protected $_filesystem ;
    protected $_imageFactory;
    protected $_objectManager;
     
    const XML_PATH_ENABLED = 'techievolve/vgod/enabled';
    
    /**
    * @param \Magento\Framework\App\Helper\Context $context
    */
    public function __construct(
        \Magento\Framework\App\Helper\Context $context,
        \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig,
        \Magento\Framework\HTTP\Adapter\FileTransferFactory $httpFactory,
        \Magento\Store\Model\StoreManagerInterface $storeManager,
        \Magento\Framework\Filesystem $filesystem,
        \Magento\Framework\Image\AdapterFactory $imageFactory,
        \Magento\Framework\ObjectManagerInterface $objectManager
        
    ) {
        $this->_scopeConfig = $scopeConfig;
        $this->_httpFactory = $httpFactory;
        $this->_storeManager = $storeManager;
        $this->_filesystem = $filesystem;
        $this->_imageFactory = $imageFactory;
        $this->_objectManager = $objectManager;
        
        parent::__construct($context);
    }
 
    /**
      * Check if extension enabled
      * @return string|null
    */
     
    public function isEnabled() {
         
        return $this->scopeConfig->isSetFlag(self::XML_PATH_ENABLED,\Magento\Store\Model\ScopeInterface::SCOPE_STORE);
    }
    
    public function isHomeBottomBannerEnabledForDesktop(){
        
        return $this->scopeConfig->getValue('techievolve_vgod/home_page_banner_bottom_desktop/enabled', \Magento\Store\Model\ScopeInterface::SCOPE_STORE);
    }
    
    public function getHomeBottomBannerBlockIdForDesktop(){
        
        return $this->scopeConfig->getValue('techievolve_vgod/home_page_banner_bottom_desktop/cms_block_desktop', \Magento\Store\Model\ScopeInterface::SCOPE_STORE);
    }
    
    public function isHomeBottomBannerEnabledForMobile(){
        
        return $this->scopeConfig->getValue('techievolve_vgod/home_page_banner_bottom_mobile/enabled', \Magento\Store\Model\ScopeInterface::SCOPE_STORE);
    }

    public function getHomeBottomBannerBlockIdForMobile(){
        
        return $this->scopeConfig->getValue('techievolve_vgod/home_page_banner_bottom_mobile/cms_block_mobile', \Magento\Store\Model\ScopeInterface::SCOPE_STORE);
    }
    
    /* Get Award Winning prduct list
     * @return $collection
    */
    public function getAwardWinningProduct(){
        
        $productcollection =    $this->_objectManager->create('Magento\Catalog\Model\ResourceModel\Product\Collection')
                                ->addAttributeToSelect('*')
                                ->addAttributeToFilter('status', array('eq' => 1))
                                ->addAttributeToFilter('award_winning', array('eq' => 1));

        return $productcollection;
    }
    
    public function getCurrentStoreId(){
		$currentStore = $this->_storeManager->getStore();
		return $currentStore->getId();
	}
    
    /*
	 * Get Media Url
	*/
	
	public function getMediaUrl(){
		return $this->_storeManager->getStore()->getBaseUrl(\Magento\Framework\UrlInterface::URL_TYPE_MEDIA);
	}
	
	/*
	 * Get Media Path
	*/
	
	public function getMediaPath(){
		return $this->_filesystem->getDirectoryRead(\Magento\Framework\App\Filesystem\DirectoryList::MEDIA);
	}
    
    public function getProductAwardWinningImageUrl($_product){

        $imagehelper = $this->_objectManager->create('Magento\Catalog\Helper\Image');
        return $imagehelper->init($_product,'award_winning_image')->setImageFile($_product->getAwardWinningImage())->getUrl();
    }
}

Magento 2 : Study Notes

Cacheable and uncacheable pages

To create an uncacheable page, mark any block on that page as uncacheable in the layout using cacheable="false".

Example:

<?xml version="1.0"?>
<!-- /** * Copyright © 2013-2017 Magento, Inc. All rights reserved. * See COPYING.txt for license details. */ -->
<layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/layout_generic.xsd">
    <container name="root">
        <block class="Magento\Paypal\Block\Payflow\Link\Iframe" name="payflow.link.iframe" template="payflowlink/redirect.phtml" cacheable="false"/>
    </container>
</layout>

Note

During theme development, when you change any files stored here, you need to clear
pub/static (preserving the `.htaccess` file in place) and var/view_preprocessed directories,
and then reload the pages. Otherwise the old versions of files are displayed on the storefront.

Enable/ Disable Module

Show status of module: it will list all enable and disable module

bin/magento module:status

Enable a module:

bin/magento module:enable --clear-static-content Module_Name

here Module_Name is the name of the module you are enabling.
Now we can see that the module is recognised and approved (enabled) by the system. This means that ’Module_Name’ => 1 entry has been placed in the array within the app/etc/config.php file.
Then you get a notification to “register” the module on a database level as well.

bin/magento setup:upgrade

Disable a module:

bin/magento module:disable --clear-static-content Module_Name

Magento: Custom Module Set Meta Data Using Config Data

Using Helper Function:
1. Create functions in your module helper file
app/code/local/Namespace/Module/Helper/Data.php

<?php
class Namespace_Module_Helper_Data extends Mage_Core_Helper_Abstract {
	
	/* Module Meta Title
	 * @return string
	 * @author Sushant Vishwas <sushant@techievolve.com>
	*/
	public function getModuleMetaTitle(){
		$store = Mage::app()->getStore();
		return Mage::getStoreConfig('section_name/group_name/meta_title',$store);
	}
	
	/* Module Meta Description
	 * @return string
	 * @author Sushant Vishwas <sushant@techievolve.com>
	*/
	public function getModuleMetaDescription(){
		$store = Mage::app()->getStore();
		return Mage::getStoreConfig('section_name/group_name/meta_description',$store);
	}
	
	/* Module Meta Keyword
	 * @return string
	 * @author Sushant Vishwas <sushant@techievolve.com>
	*/
	public function getModuleMetaKeyWord(){
		$store = Mage::app()->getStore();
		return Mage::getStoreConfig('section_name/group_name/meta_title',$store);
	}
}

2. Get Data from Config in your layout file
app/design/frontend/default/default/layout/namespace_module.xml

<?xml version="1.0"?>
<layout version="0.1.0">
    <default>
    </default>
    <module_index_index>
        <reference name="head">
			<action method="setTitle" translate="title" module="module"><title helper="module/data/getModuleMetaTitle"/></action>
			<action method="setDescription" translate="title" module="module"><title helper="module/data/getModuleMetaDescription"/></action>
			<action method="setKeywords" translate="title" module="module"><title helper="module/data/getModuleMetaKeyWord"/></action>
		</reference>
        <reference name="content">
            <block type="module/module" name="module" template="module/module.phtml" />
        </reference>
    </module_index_index>
</layout> 

Or You can also set meta information using block file:
app/code/local/Namespace/Module/Block/BlockFile.php
In your block _prepareLayout fubction add the following code:

public function _prepareLayout() {
		
		if ($head = $this->getLayout()->getBlock('head')){
            $head->setTitle($this->htmlEscape(Mage::getStoreConfig('module/module_landing_page_meta/meta_title', Mage::app()->getStore()->getStoreId())));
			$head->setDescription($this->htmlEscape(Mage::getStoreConfig('module/module_landing_page_meta/meta_description', Mage::app()->getStore()->getStoreId())));
			$head->setKeywords($this->htmlEscape(Mage::getStoreConfig('module/module_landing_page_meta/meta_keywords', Mage::app()->getStore()->getStoreId())));
        }
		parent::_prepareLayout();
 
        $pager = $this->getLayout()->createBlock('page/html_pager', 'custom.pager');
        $pager->setAvailableLimit(array(6=>6,12=>12,24=>24,'all'=>'all'));
        $pager->setCollection($this->getCollection());
        $this->setChild('pager', $pager);
        $this->getCollection()->load();
        return $this;
    }