News:

Looking for documentation? Take a look on our wiki

Main Menu

Virtuemart clean HTML?

Started by Artemi0, April 03, 2015, 10:04:09 AM

Previous topic - Next topic

Artemi0

Hello !:
Use Virtuemart 2.9.9e, preinstalled with a workforce of CMSMART "Printing Company Template" Joomla! 3.4.1 Stable

Everything works perfect, but ...

After adding a position in product template (using an override....)


<?php if (!empty($this->product->customfieldsSorted['my-position'])) {
       
$this->position='my-position';
       echo 
$this->loadTemplate('customfields');
    }
    
?>


and assign that position a custom field type "Editor" in the product description text that I write is shown, but as plain text without formatting or pictures ....

I have found that neither Joomla or configuration editor (JCE in this case) are the "guilty" cleaning code i've tried other wysiwyg editors and always happens the same, only shows the raw text.

The forum can not find anyone with this problem ... Any ideas?

Excuse my english and thanks for your great work!

balai

I think the editor is displayed only in the backend. This is how it is designed to work.

If you want to have a user input, try the "Customer Text Input" plugin. It does not have an editor but you can give one with some modifications to that plugins output.


Artemi0

No, i don't want to show an text field with editor to buyers.

I want to add an extended description, especific times to delivery, etc,  in product details.

He is now working,  when write some text whit editor wysiwyg that is shown in assigned position of the template,  but is a raw text, no HTML code (no images, no H3 tags, etc...)


I don't know if it is well explained, my English is very limited... thanks for your time.

balai

aha
I suppose the text you are entering is somehow filtered/sanitized
Don't know if this happens when it is saved (input) or in the output.
You can have a look at the table virtuemart_product_customfields to see how this custom field is saved

GJC Web Design

Virtuemart 2.9.9e is/was a pre release development version... you should be on 3.0.6.4
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

Artemi0

Hi!

First , let me thank you for your time

Balai
QuoteI suppose the text you are entering is somehow filtered/sanitized
Don't know if this happens when it is saved (input) or in the output.
You can have a look at the table virtuemart_product_customfields to see how this custom field is saved

Yes, the problem its the sanitation in VM. This happens when saved. The table svirtuemart_product_customfields hows the text stored in plain text. If change this whit codified text, directly in phpMyAdmin, it show at frontend Ok,

Some idea to solve this?


Quote from: GJC Web Design on April 03, 2015, 11:21:58 AM
Virtuemart 2.9.9e is/was a pre release development version... you should be on 3.0.6.4

GJC  you're right and it would be safer, but I bought a package {Joomla (updated)+ VM(2.9.9e)+ Template (Printing VM by CMSMART, customized) } with some custom extensions and i can't update whitout damaging others components and functions...

I´m waiting reply developer to know when they make an update, but I think this is more urgent for me than for them.

Some idea?


David Kan

Hello

We are the developer

For sure, we need to know which one you choose to display (on the front-end):

1. http://gyazo.com/d3fc2d232cef20ee603f39a03bac93d7
2. http://gyazo.com/28d9c02780299c837eeba3cf832286f1