Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Editing HTML of error message
 
rzrz
Jr. Member
 
Total Posts:  24
Joined:  2013-03-05
 

I want to find the HTML for the error messages as there are extra <br> as attached in image.

TIA!

-------

edited* attached additional image showing the extra <br><br>

Image Attachments
crop.jpg1.jpg
 
Magento Community Magento Community
Magento Community
Magento Community
 
Lyonscg
Sr. Member
 
Avatar
Total Posts:  173
Joined:  2009-11-13
Chicago IL
 

That message comes from the core. I suggest (if you are able) to either use an observer to change that message or create a module that overwrites the class/method.

With that being said, unless this was already modified with one of the methods mentioned above, I doubt you’re seeing an extra break tag. It’s much more likely too much padding or margin (This is of course a complete guess). You can confirm that by using Firefox’s firebug extension or Chrome’s built in developer tools

Either way, the file location is:

app/code/core/Mage/CatalogInventory/Model/Stock/Item.php on approx. line 582 in the checkQuoteItemQty() method
Mage_CatalogInventory_Model_Stock_Item::checkQuoteItemQty()

 
Magento Community Magento Community
Magento Community
Magento Community
 
rzrz
Jr. Member
 
Total Posts:  24
Joined:  2013-03-05
 

Hi thanks but the item.php only edits the message itself, not the HTML. Messages can be edited but its the HTML <br><br> that needs to be deleted and that can’t be done on the backend.

Lyons CG - 29 March 2013 04:23 AM

That message comes from the core. I suggest (if you are able) to either use an observer to change that message or create a module that overwrites the class/method.

With that being said, unless this was already modified with one of the methods mentioned above, I doubt you’re seeing an extra break tag. It’s much more likely too much padding or margin (This is of course a complete guess). You can confirm that by using Firefox’s firebug extension or Chrome’s built in developer tools

Either way, the file location is:

app/code/core/Mage/CatalogInventory/Model/Stock/Item.php on approx. line 582 in the checkQuoteItemQty() method
Mage_CatalogInventory_Model_Stock_Item::checkQuoteItemQty()

 
Magento Community Magento Community
Magento Community
Magento Community
 
rzrz
Jr. Member
 
Total Posts:  24
Joined:  2013-03-05
 
Hadi N - 30 March 2013 07:38 AM

It would be better if you put the link of your website. So we can check it via firebug or chrome’s web developer extension.

sorry I didn’t explain clearer, i have since added a printscreen to aid understanding.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Lyonscg
Sr. Member
 
Avatar
Total Posts:  173
Joined:  2009-11-13
Chicago IL
 

If the html hasn’t been added in the core, then it’s where ever the custom html for that popup is. Turn on template path hints which should tell you which phtml file is outputting the popup html.

System -> Configuration -> Developer -> Debug -> Template Path Hints (enable)

 
Magento Community Magento Community
Magento Community
Magento Community
 
rzrz
Jr. Member
 
Total Posts:  24
Joined:  2013-03-05
 
Lyons CG - 01 April 2013 07:07 AM

If the html hasn’t been added in the core, then it’s where ever the custom html for that popup is. Turn on template path hints which should tell you which phtml file is outputting the popup html.

System -> Configuration -> Developer -> Debug -> Template Path Hints (enable)

thanks for the pointers it is good to know although it doesn’t solve the issue… I think its somewhere in the ajax notification but I couldn’t figure out where

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top