Questions tagged [php]

This tag is used for questions that 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.

Filter by
Sorted by
Tagged with
0
votes
0answers
219 views

Magento 1.9.2.4: Show category images in top navigation menu

Hi I am using copy of rwd theme to make a custom theme. What i need to do is to show category image in the top menu, I am trying to make it happen through renderer.phtml. Tried a lot of thing but ...
0
votes
0answers
48 views

Clear All form including dropdown on Save

I have a block of code that I call for a dropdown in the form. The issue is when the product data is 'submitted' from the save button the form the old data stay there, but only in dropdowns . The '...
0
votes
1answer
458 views

How to implement my own action in custom admin grid?

I have custom admin grid which shows data from my table. Last column in this table is "Actions". And there are two actions (links) - "Approve" and "Reject". My links looks like: http://mgtraining.box/...
0
votes
1answer
139 views

paypal sha256 related CURL issue

To test the SHA256 compatibility for paypal - in my linux web server I tried the below and got this error. I do have the SHA256 SSL certificates installed though. curl https://api-3t.paypal.com/nvp ...
0
votes
1answer
2k views

Use custom classes in Magento 2 controller

I'm migrating my module from Magento 1 to Magento 2, some code is no longer working. Instantiating the class doesn't work anymore, is there a different way to do it in Magento 2? include("...
0
votes
3answers
699 views

Unable to send inquiry in contact form

I have an issue with my contact form. I have created a static block and I insert this code {{block type='core/template' name='contactForm' action='/contact-us/index/post' template='contacts/form....
0
votes
1answer
405 views

Magento2: Layered navigation at top of category page

In Magento2, I want layered navigation to be shown in the content area at the top of the product listing. I managed to do it but simultaneously its showing in left sidebar too. I don't want to show it ...
0
votes
1answer
57 views

List configurable options using custom extension?

I've purchased an extension called B2B Order List by Ecomwise and my aim was to create a category just visible to wholesale customers that lists relevant products and gives the user the ability to add ...
0
votes
0answers
133 views

Dataflow import via script

Can anyone please tell me How to create new Advance Dataflow Profile via script during extension installation? I asked earlier also but no response: How to Create Magento Dataflow advanced profiles ...
0
votes
3answers
242 views

How get new installed product attribute in magento (using helper) on category pages

I've installed new product attribute using my module script - mysql4-install-1.0.0.php: <?php $installer = $this; $installer->startSetup(); $setup = new ...
0
votes
1answer
32 views

Added addditional fee to sample product(price 0) not shows payment method magento 1.9.2.4

I have some sample products which are free but have some additional fee applied to total cart. If I order the sample product alone, it does not show any payment method so I can't able to choose ...
0
votes
1answer
376 views

Parse error: syntax error, unexpected '->' (T_OBJECT_OPERATOR) in Magento 1.9.2

Error is coming on product detail page in Magento 1.9.2. Error is for custom options only. <?php if ($_product->isSaleable() && $this->hasOptions()):?> <?php echo $this->...
0
votes
1answer
361 views

How can display group price greater than regular price in magento?

I have list of products in which some products have group price is greater than regular price.currently I am getting only minimum price. Please help?
0
votes
1answer
644 views

Ajax Cart Does NOT work with Full Page HTTPS (SSL)

I turned on Full Page https, so all pages load only in HTTPS. Now I realized that AJAX cart throws error window when I try to add somethign to the cart. Any ideas where to look for the cause? I can ...
0
votes
1answer
58 views

Can I continuously run cron jobs for magento if I am using windows?

What I am trying to do is to make cron jobs run automatically, for example I got more jobs, and when I hit www.mylink.com/cron.php, it executes the cron jobs once, and after that I have to press the ...
0
votes
1answer
688 views

conflict JS Jquery

I Purchased a magento theme named em everything After installing i m having some problems, 1 add to cart not working, 2 ccevenue plugin not woring in one page checkout, so i messaged the theme seller ...
0
votes
0answers
2k views

Magento 2: SMTP Email gives error “Could not open socket”

Using Magento 2 Version 2.1.0 on WAMP Windows 10 As continue with this question Magento 2: SMTP Email gives error "Invalid sender data" Now this is my code $storeScope = \Magento\...
0
votes
1answer
21 views

Strange number inside Mini Cart

I have a number appearing within each item listing of the Mini Cart: Where would this be rendered? I've looked in app\design\frontend\base\default\template\checkout\cart\sidebar\default.phtml but ...
0
votes
2answers
41 views

Access $this from PHP outside of Magento

I am playing around with the Mini Cart content from outside of Magento. This section of code uses $this: <?php foreach($cartItems as $_item): ?> <?php echo $this->getItemHtml($_item) ...
0
votes
1answer
186 views

Foreach Loop Pulling Wrong Value From Collection

I have a foreach loop that I am running over a Magento collection so I can run pull in the info for multiple patients (it's a pharmacy). However, after each iteration of the foreach loop, it returns ...
0
votes
1answer
179 views

Postdata not inserted into the updated table in mysql database in magento

I have a issue with inserting data into the Magento mysql database. I wanted to create a new column (howyouheard) in the existing database in Magento. The column is to take the values from customers ...
0
votes
1answer
473 views

AddAttributeToFilter doesn't seem to be working

For my Magento shop, I'm trying to retrieve all products that have an attribute set to yes called "uitgelicht_categorie" under the categories. The products should be shown depending on the categories. ...
0
votes
1answer
279 views

how to use command line in magento 2.1?

I have tried to run the command line script in a linux VPS with PuTTy and get this error: Magento supports PHP 5.6, 7.0.2, and 7.0.6 or later. Please read http://devdocs.magento.com/guides/v1.0/...
0
votes
1answer
23 views

Some PHP guidance re a multi store site please

I have a multi store site a retail and a wholesale site. The wholesale site requires that out of stock, cart and price not be shown whereas the retail site should display this information. I located ...
0
votes
1answer
203 views

filter_condition_callback function stopped working after using $collection

Here is my code: protected function _prepareCollection() { $collection = Mage::getResourceModel('sales/order_grid_collection') ->addFieldToSelect('entity_id') ->...
0
votes
1answer
33 views

Magento 1.9 - cycle Foreach, result blank content

I'm trying to write cycle foreach, for insert my categories in the table with 3 rows and 4 columns. The code is this: $i = 0; if (mysql_num_rows($result) > 0) { while ($row = mysql_fetch_array($...
0
votes
2answers
59 views

Which event to use in order to execute a function after a frontend order?

Which event should I use in order to execute a function after a frontend order? In other module, a colleague used but I think this is for backend orders.
0
votes
1answer
215 views

How to get price of specific sku from an order

I'm trying to get the price of a specific sku if it exists on an order, here's what my current code is: $itemCollection = $order->getItemsCollection(); foreach($itemCollection as $item) { ...
0
votes
1answer
140 views

Exeption error when adding new custom Tab to Order View page in Admin

Here is my layout: <?xml version="1.0"?> <layout> <adminhtml_sales_order_view> <reference name="sales_order_tabs"> <action method="addTab"> ...
0
votes
1answer
515 views

Configurable product page is showing price twice in magento

I am using flaton magento template. I have replaced the catalog.xml code From <reference name="product.info.options.wrapper"> <block type="catalog/product_view_type_configurable" name="...
0
votes
0answers
395 views

Magento admin login Invalid Form Key. Please refresh the page in Ubuntu

I have work with Magento 1.9.2.4 in Ubuntu OS, my one of the colleagues work with the same project in Window 7 OS,i am newly configured my project in Ubuntu OS when i login via the backend it show me ...
0
votes
1answer
229 views

Magento White Screen FrontEnd - PHP Startup: Unable to load dynamic library

I was recently trying to add a javascript gallery to my development magento site and was editing code through the "page.xml" - it wasn't working so i deleted the code out of the file. Now when i load ...
0
votes
1answer
2k views

Uncaught TypeError: Argument 1 passed to Mage_Adminhtml_Controller_Action::_addLeft() must be an instance of Mage_Core_Block_Abstract, boolean given

What does this error mean and how can I fix it? I'm sure it is related to me upgrading to php7. Thanks Error: PHP Fatal error: Uncaught TypeError: Argument 1 passed to ...
0
votes
1answer
955 views

Magento2 Check value of attribute for IF statement

I am trying to check if an attribute is set to yes then show this block. <?php if($_item->getAttributeText('free_shipping_toggle')=='1'): ?> <?php echo $this->getLayout()->...
0
votes
0answers
58 views

How to check is jQuery available for my module?

Magento as far as I know have it already loaded but jQuery functions won't work in my module. What can I do with it ? How can I make sure I have an access to it ? I would like to avoid jQuery ...
0
votes
1answer
1k views

Programmatically update the quantity of an item ordered in magento [duplicate]

I have to edit the quantity of some items programmatically in Magento. Say a customer ordered for 5 kg of Apples and 10 qantity of pens. But then he rejects 1 kg of apple and 5 pens because of say ...
0
votes
2answers
1k views

How can I get Products name from customer order in Magento

I have created custom payment gateway to redirect user to an external link where payment will be processed. This is the redirect.phtml which redirect to the external payment gateway <?php $order = ...
0
votes
1answer
321 views

How to add admin “user id” in “catalog_product_entity” table in magento

I want to check which user adding product and listing user wise products in Manage products section.
0
votes
1answer
1k views

How to disable Orders and Returns: “/sales/guest/form/”

I notice that magento 1.7 offers an option on the frontend where customers can look up their orders using email, order number and billing name. The form is usually located here: domain.com/sales/...
0
votes
1answer
2k views

Magento 1.9 REST API Callback

so I just set up my M1.9 store, and want to set up a REST API. I wanted to test it out by retrieving a list of products. I only don't know what to put in the callbackurl field, online they say the ...
0
votes
1answer
107 views

How to use action method of core module (observer.php) in my custom module controller.?

As I am new to PHP as wel MAGENTO I want to use core sitemap controller action in my own custom module. suggest me how. public function scheduledGenerateSitemaps($schedule) { $errors = ...
0
votes
3answers
636 views

Check out page redirects to shopping cart again and again

After adding items to cart when customer going to checkout, at first step of billing info, when we click continue, customer is redirected back to shopping cart and not on next step. Please help to ...
0
votes
1answer
270 views

Call Mirasvit Sphinx Search from own controller?

I am using Mirasvit Sphinx Search with good success. However, I would like to handle certain types of requests using my own controller, from which I would perform a search and process the search ...
0
votes
1answer
442 views

Overriding Core File in Magento

I am new magento and I want to override my "Data.php" file which is located at /app/code/core/Mage/Directory/Helper/Data.php I want to remove the unwanted states from DropDownList. Below is my ...
0
votes
1answer
450 views

Magento 2 works too slow on local system in development environment [duplicate]

Magento 2 works very slow on local desktop system. This affects development speed. I am using wamp server. Works fine with Magento 1. Is there anything which can make Magento 2 run faster in my local ...
0
votes
0answers
70 views

Get the number of rows in cart in Magento

I found places online that show how to get the number of items in the cart but how can I get the number of rows? For example, if there are two different items in the cart there will be two rows, if ...
0
votes
2answers
107 views

How can I wrap the description in paragraph tags? [closed]

On my product page I am getting the description like this: <?php echo $attribute_value = $_product->getResource()->getAttribute('my_description') ->getFrontend()->getValue($_product); ?...
0
votes
1answer
66 views

discount on multiple of X item

I want to give customer a discount of $5 on 3, $10 on 6, $15 on 9 and so on product of a particular category. I tried as describe in this link but no success. How can I achieve this.
0
votes
1answer
2k views

Get order data by product id Magento 1.9

i want to get all data (order_id , Bill to Name , ship to Name , BaseGrandTotal , GrandTotal ,Status ) about order with the known of product ids Here is the sample of my code $ids=array(); ...
0
votes
1answer
140 views

How to edit sales_order AdminHtml template [duplicate]

i want to edit sales_order listing view to add new column but i can not find that template to edit. i want to edit .phtml file not Block this is url that i want to edit on it http://localhost/...

1 59 60 61 62 63 66