Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
Make your voice heard. Take the 2019 Developer Survey now

Questions tagged [php]

This tag is used for questions which involve PHP code in any way. So as soon there is a PHP Exception returned or error report generated, this question qualifies to be tagged with PHP.

0
votes
3answers
102 views

Reason for using underscores in private / protected properties?

Often I'll be going through tutorials written by various people, and see underscores used for private or protected vars/properties within a class. e.g., one person will will have: protected $...
0
votes
0answers
26 views

'magento.catalog_product_index_group_price' doesn't exist' magento 1.9

Please, I am a newbie in magento, just got a job to maintain a client project,each time I try to index, I keep receiving this error. `magento.catalog_product_index_group_price' doesn't exist` Please,...
2
votes
1answer
91 views

How to make a SOAP call after successful order

Hi I am fairly new to Magento2 and it's API. I need to send out a SOAP call to the API of our distributor using PHP after a successful order has been placed (after completing the payment). Is there ...
0
votes
0answers
62 views

How to show Prices for OUT of stock products in Magento 2

Here is my question - How to show prices for all out of stock products? Here pic http://prntscr.com/krhurk I created the module from here https://magento.stackexchange.com/questions/160145/magento-2-...
1
vote
1answer
53 views

Install script not running

I know there's a million of these questions with answers but I still can't solve this. It does create the line in the core_resource table, but my install script is supposed to die to show it's running,...
6
votes
3answers
212 views

Magento add position 999 when assign product to category

I'm using Magento 1.9.x and trying to change default position number of products. Ex, when we assign product to category via product page i need to set it to 999 position I changed default position ...
5
votes
1answer
281 views

Magento 2 No such entity with cartid = help!

I'm experiencing this error on my site quite often: Exception #0 (Magento\Framework\Exception\NoSuchEntityException): No such entity with cartId = It's not using multiple stores, so the entity_ids ...
0
votes
1answer
32 views

Magento 2 - How to create a calculator

I've created a new module in magento 2 and I want to add some additional files so that I can create a calculator. I'm unsure where to create a file that calls the functions of my calculator class and ...
1
vote
1answer
34 views

Magento 2 Setting custom customer attributes

I have some custom attributes set in the customer information in the admin. I have a page setup with checkboxes which if checked should set these attributes to yes or no. I'm struggling with setting ...
0
votes
2answers
58 views

Decode code of Magento 2 Extension

I'm working on customization of extension functionality. I have to add my custom code with it, but when I have checked code all the codes are encoded and I can't see actual code there. So can anyone ...
0
votes
3answers
146 views

Magento 2 Adding custom attributes InstallData.php Error

I'm trying to add a few custom customer attributes, I've created a simple module to install the attributes but my InstallData.php file keeps failing. Here's my code: <?php namespace ...
0
votes
0answers
30 views

Modify the existing product collection in magento 2

I need to modify the existing product collection in magento 2. Product name, description, image etc are loaded from the third party url and inventory & pricing details are from magento db itself. ...
0
votes
2answers
54 views

How to remove a specific href from a top-menu link in Magento 2

Hello I am trying to make 3 items on menu to be not click-able and I want to ask how to remove a specific href from a top-menu link in magento? (I don't want to remove from all menu ...
1
vote
1answer
80 views

Magento 2.2.5 Customer Registration Page Reloads After clicking the Create Account Button

I have a fresh installation of magento 2.2.5 with Magetigue theme and I have migrated the data from magento 1.9.3.7 to magento 2.2.5 using data migration tool. Now when I try to create an account by ...
3
votes
2answers
53 views

I want to add an extra amount if the payment method is cash on delivery

I have an E-commerce website where i want the users to pay extra some money if they choose "Cash on delivery" as payment option. Can you please help me achieve this? Thanks in advance
0
votes
0answers
22 views

Magento 2 addAttribute() method in UpgradeData script creating attribute and directly assigned to all atribute set?

I am using magento2.2 and created a module which will create attribute set and product attribute. But as soon as attribute is created using addAttribute() method it is directly assigned to all ...
0
votes
3answers
252 views

Magento 2 PHP Foreach loop help!

I'm trying to display the images of products on each order item, so far I have the image pulling through but it's only one of 3 product images. It's also displaying them on every order in the order ...
1
vote
2answers
332 views

M2 Free shipping if subtotal is higher than X amount

I am developing M2 store for a company that just serves only for domestic users. I recently bought the Amasty Inventory module and made the domestic cities.(No shipping available to the countries ...
0
votes
1answer
140 views

Magento 2 - Display search button

I need to add a icon instead the search input form and when I click on this icon to display the search input form? something like minicart.
0
votes
0answers
43 views

Magento 2 Setting a address as Default

Splitting Address Book I've split the address book up into two sections; one displays the default billing as if it's the same as the default shipping address, where as the other section displays the ...
2
votes
2answers
44 views

Magento CE 1.9 collecting the LowStockDate value

I've made a quick script to collect out of stock products that are: a) qty greater than 0 b) have been out of stock for 2 weeks. This will then set the is_instock_value for products that match those ...
1
vote
1answer
32 views

Customer Account page title is at the bottom, and margin-bottom is being set to 0 but i cant find where

I'm so close to having this site finished and then this happens. I logged into the customer account section to check all was good and then i was greeted with this... It should look like this... I ...
1
vote
1answer
26 views

Magento 2.2.5 : public function getConfiguredAmount(): \Magento\Framework\Pricing\Amount\AmountInterface

From this \vendor\magento\module-wishlist\Pricing\ConfiguredPrice\ConfigurableProduct.php File I find below code: public function getConfiguredAmount(): \Magento\Framework\Pricing\Amount\...
0
votes
1answer
82 views

Create Customer Account Not working

I am on Magento 2.2.5 (issue persisted on 2.2.4 as well). I am not able to create any new customer. Whenever I try to fill in the details in NEW CUSTOMER ACCOUNT form, "customer/account/create/", the ...
0
votes
2answers
47 views

How to create custom widget via Install?

I need to create widget category link via Upgrade. How to do this?
2
votes
1answer
113 views

Magento 1.9 Get Last Real Order Number

I would like to get the last order Number saved in database of the store and increment it to get what the current order number would be before it is saved as i would like to pass the the order number ...
0
votes
0answers
42 views

Magento 2: How to Pass Adjustment Fee to Credit Memo

Is it possible to pass and auto populate the Adjustment Fee to a new credit memo via url parameters? For example, the create Credit Memo url on an order is generated using the following: public ...
1
vote
0answers
36 views

Some orders come in without email

I have a strange problem in Magento store, some orders come in without email. As you can see on screen, such orders marked as Guest and group General, which basically refers to registered customers. ...
1
vote
0answers
21 views

When I remove item from checkout page in Magento 1.9, its showing error of form key

strong text when I delete one item its working fine but when I remove the second item then its showing error I didn't know why this is happening please anyone help me? https://madoverprint.com/...
0
votes
0answers
34 views

Paypal After payment not return to website show 404 error

For my Magento website Version 2.2.2 I am using Paypal express checkout but from few days I am facing the issue customers makes the payment at moment it doesn’t return back to website instead it shows ...
1
vote
1answer
30 views

Multiselect value does not rendered all previously selected value

I add an admin grid using the below mentioned url. Now I add a multi-select field in the form by editing at App/Code/Webkul/Grid/Block/Adminhtml/Grid/AddRow.php file.It is visible fine. I use implode()...
1
vote
0answers
24 views

While loading site it show all menus for seconds

While loading my site it show all menus for some seconds and then it disapears and all is normal. How can I solve this issue? I searched for it and read something about preloader.
1
vote
0answers
11 views

how to fetch value from URL and post in form M2

I have product grid in admin panel where I have edit link too. Edit link looks like http://localhost:8888/backend/division/products/productedit/a_id/10/id/26794/ in ui form I need to send this id :...
0
votes
0answers
52 views

How to apply tax on product in a custom module other than cart/quote?

So, the context of the question is I've a custom module in my project called "Negotiable Quotes". In this module, I'm using the catalog product as one of the options in negotiable quote's items. So, ...
1
vote
0answers
58 views

How to make vertical navigation collapse per category?

Please check as example https://www.uitverkoopgigant.nl/eglo-tarbes-hanglamp-9002759941918.html. Its made in Magento 2. Here you see that the category colapse all subcategories. How can I make it so ...
0
votes
1answer
75 views

How to call function from php file to .phtml file in magento 2

I am trying to add google reCaptcha for the newsletter. I have added the following code after <form>; <button class="g-recaptcha" data-sitekey="6Lfc-WsUAAAAAMvtAnrdwdDGxdiOsuPyFK4wse1D" ...
0
votes
2answers
94 views

Image in grid is not showing up in magento 1.9.3.9

I am trying to add Image column in the existing module. but images are not showing up. here is the screenshot. 8 and 9 are having the image because I added it in MySQL. here is my code. Grid.php ...
0
votes
1answer
23 views

How to get the db updated at timestamp value form custom table in magento 2?

I have to get the updated at value from db custom table. But if I print the value it is showing before 5 30 hrs. How to get the value in phtml file without using dependency injection.
1
vote
0answers
16 views

Magento 2: Split Order after checkout

I want to split an order after checkout into 2 sub orders, such as if 2 products are brought they should reflect as 2 sub-order's of a single order. Thanks in advance.
2
votes
1answer
38 views

I need to hide content on the weekend

I've got a countdown timer that shows one thing before 2pm and another for after 2pm. I need to now add something else that shows something else on the weekend and hides the first part. Here is what I ...
0
votes
0answers
46 views

How to create layered filter navigation in slider ?like the price slider in magento 1.9

I am trying to create filter using attribute in layered navigation.requirement is that i want those attribute filters in slider like the price slider.
1
vote
1answer
70 views

Magento 1.9 : removeitem action xml , remove css from specific page

I have an onestepcheckout module for magento and I need to remove all the css from the theme on my checkout page I need to remove this item <link rel="stylesheet" type="text/css" href="myurl.com/...
1
vote
0answers
40 views

Run magento2.2.3 on Local Machine - MAMP

I downloaded my live magento 2.2.3 based website into my local desktop Mamp directory. I imported the database into the local phpmyadmin. I edited the app/etc/env.php file to have the correct ...
0
votes
0answers
16 views

How To Update the cost of a product by using the advanced pricing in import function

How To Update the cost of a product by using the advanced pricing in import function. In my csv file if i add the cost field it was showing an error.so any one can help me???
1
vote
2answers
125 views

How to add category name of product as a class in body element

I have single product page on my site. The product is having category "beauty". Product display page having following body tag: <body data-container="body" class="catalog-product-view product-...
0
votes
4answers
521 views

Magento 2 : Composer runs out of memory

I am trying to install instamojo payment gateway to my magento2 store, as per the instructions givne by instamojo page https://docs.instamojo.com/page/instamojo-integeration-for-magento-2 i tried the ...
0
votes
3answers
123 views

How to re-submit form data in custom module?

I want to get post data in phtml . In case form data not save then show error and already fill form . <form class="trail-register-form" action="<?php echo htmlspecialchars($this->...
0
votes
2answers
37 views

How to add menu subitem in magento website?

I want to add menu sub item in the existing parent menu but couldn't get good resource to help me out? can we add sub-item menu through magento admin panel?
0
votes
1answer
79 views

How to override magento 1.9 newsletter model subscriber.php?

I'm trying to add first name and last name on my newsletter subscription. I would like to override the newsletter core functions of the controller and the subscriber model. Here is my code: config.xml ...
3
votes
2answers
64 views

unable to get order status in sales_order_place_after event in magento 1.9

Hello I am unable to get the order status in the observer sales_order_place_after I also tried other events like checkout_onepage_controller_success_action, checkout_type_onepage_save_order_after. ...