[Skip to main content](#vessel-content)

#   How would I have Custom fields containing HTML

##

- **[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")**
- [![davcraiguk's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1706-davcraiguk "View davcraiguk's Profile") Topic Author
- [ Offline](/forum/user/1706-davcraiguk)

Less More

- Posts: 34
- Thank you received: 0
-
-

15 years 6 months ago [\#14197](#14197) by [davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")  *[How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14197 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")* was created by *[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")*

I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.

Better still can a custom field be a text editor entry i.e JCE?

---

David Craig
Hikashop 1.5.0 Business edition
[ www.charitycanvasprints.com](http://www.charitycanvasprints.com)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")**
- [![davcraiguk's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1706-davcraiguk "View davcraiguk's Profile") Topic Author
- [ Offline](/forum/user/1706-davcraiguk)

Less More

- Posts: 34
- Thank you received: 0
-
-

15 years 6 months ago [\#14200](#14200) by [davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")  Replied by *[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")* on topic *[Re: How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14200 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")*

Sorry wrong sub forum, I meant to post it in 'How To?' Can you please move it or delete it and I will re-enter it?

---

David Craig
Hikashop 1.5.0 Business edition
[ www.charitycanvasprints.com](http://www.charitycanvasprints.com)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86315
- Thank you received: 14276
-
-

15 years 6 months ago [\#14203](#14203) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14203 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")*

What kind of custom field field are you using and where do you have your HTML cut . On the front end or the back end ?
Which version of HikaShop are you using ?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")**
- [![davcraiguk's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1706-davcraiguk "View davcraiguk's Profile") Topic Author
- [ Offline](/forum/user/1706-davcraiguk)

Less More

- Posts: 34
- Thank you received: 0
-
-

15 years 6 months ago [\#14208](#14208) by [davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")  Replied by *[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")* on topic *[Re: How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14208 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")*

Tried using Text and Text Area Custom Field types

Purpose is to enter it in a custom field the products back-end page and display in the frontend. (Its a piece of HTML to display CC licence info and links to the licience and the author)

Version 1.4.8 business

---

David Craig
Hikashop 1.5.0 Business edition
[ www.charitycanvasprints.com](http://www.charitycanvasprints.com)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86315
- Thank you received: 14276
-
-

15 years 6 months ago [\#14210](#14210) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14210 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")*

Before version 1.4.9 you could not insert HTML in custom fields. You should get the 1.4.9 version and install in over your current version to be able to do that.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")**
- [![davcraiguk's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1706-davcraiguk "View davcraiguk's Profile") Topic Author
- [ Offline](/forum/user/1706-davcraiguk)

Less More

- Posts: 34
- Thank you received: 0
-
-

15 years 6 months ago [\#14217](#14217) by [davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")  Replied by *[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")* on topic *[Re: How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14217 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")*

The back-end told me the 1.4.8 was the current stable version. I then went to your site and my order and downloaded and installed the latest, which was 1.4.9 even tho the software itself showed 1.4.8 was the current version.

I deleted my previous custom fields and created new ones.

It does not interpret single quotes correctly. If I have all double quotes in the HTML code then it is fine.

Another limit is that it only allows for VARCHAR i.e. 255 characters, very small for any HTML snipit

---

David Craig
Hikashop 1.5.0 Business edition
[ www.charitycanvasprints.com](http://www.charitycanvasprints.com)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")**
- [![davcraiguk's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1706-davcraiguk "View davcraiguk's Profile") Topic Author
- [ Offline](/forum/user/1706-davcraiguk)

Less More

- Posts: 34
- Thank you received: 0
-
-

15 years 6 months ago [\#14218](#14218) by [davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")  Replied by *[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")* on topic *[Re: How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14218 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")*

Example of single quotes not being written out correctly.

Code as entered: Code:

&lt;a href='http://creativecommons.org/licenses/by/2.0/' target='_blank'&gt;&lt;img src='http://i.creativecommons.org/l/by/2.0/80x15.png' alt='Creative Commons Attribution 2.0 Generic License' title='Creative Commons Attribution 2.0 Generic License' border='0' align='left'&gt;&lt;/a&gt;

After a save the code looks like this: Code:

&lt;a href="http://creativecommons.org/licenses/by/2.0/" target="_blank"&gt;&lt;img src="http://i.creativecommons.org/l/by/2.0/80x15.png" alt="'Creative" Commons="Commons" Attribution="Attribution" 2.0="2.0" Generic="Generic" License'="License'" title="'Creative" Commons="Commons" Attribution="Attribution" 2.0="2.0" Generic="Generic" License'="License'" border="0" align="left" /&gt;&lt;/a&gt;

I manually increased the field size VARCHAR custom field in the Db table and the code seems to handle the bigger size OK.

---

David Craig
Hikashop 1.5.0 Business edition
[ www.charitycanvasprints.com](http://www.charitycanvasprints.com)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86315
- Thank you received: 14276
-
-

15 years 6 months ago [\#14231](#14231) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14231 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")*

In next version, we will change the creation of custom fields to have them as TEXT field instead of VARCHAR. That will allow more than 255 characters.

For the quotes in the HMTL, that's normal. When you add HTML in a custom field, the code is checked for XSS threats so that no one on your website will be able to mess with them. We use the filtering library of joomla for that and it has that behavior when checking the HTML.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")**
- [![davcraiguk's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1706-davcraiguk "View davcraiguk's Profile") Topic Author
- [ Offline](/forum/user/1706-davcraiguk)

Less More

- Posts: 34
- Thank you received: 0
-
-

15 years 6 months ago [\#14235](#14235) by [davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")  Replied by *[davcraiguk](/forum/user/1706-davcraiguk "View davcraiguk's Profile")* on topic *[Re: How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14235 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")*

Thanks for that.
When doing your code change it would be good that if no custom fields were filled in for a particular product that the 'Specification' heading would also not show.

Sorry for posting in the wrong sub-forum as its not really a bug

---

David Craig
Hikashop 1.5.0 Business edition
[ www.charitycanvasprints.com](http://www.charitycanvasprints.com)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86315
- Thank you received: 14276
-
-

15 years 6 months ago [\#14248](#14248) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: How would I have Custom fields containing HTML](/forum/3-bug-report/14197-how-would-i-have-custom-fields-containing-html#14248 "I tried this and single quotes get a double quote put in front of it and truncates my code (a fairly long 'a href' entry). I tried text and text area types.  Better still can a custom field be a text editor entry i.e JCE?")*

We'll look at doing that.

Don't worry. We have a lot of users posting bug reports which aren't ![:)](/media/kunena/emoticons/8.png ":)")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMtYnVnLXJlcG9ydC8xNDE5Ny1ob3ctd291bGQtaS1oYXZlLWN1c3RvbS1maWVsZHMtY29udGFpbmluZy1odG1sP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop- Install &amp; Update- Product &amp; Category Display- Content Creation- Sales and Orders- - Orders management- - Reports &amp; Statistics- Customers- Checkout- Payment Methods- Shipping Methods- Import &amp; Export (CSV, XLS…)- Specific Features- - Affilation- - Taxes- - Wishlist- - Vote- - Carousel &amp; Slider- - Mass Actions- - Filters &amp; Search- - Discount &amp; Coupon- - Feature Request- Integrations- Showcase- General Talk about HikaShop- Development- - HikaShop 3.0 Beta- Translation- Commercial Jobs HikaShop Components- HikaMarket- - Market: Feature requests- - Market: How to?- - Market: Bug Report- HikaSerial- - General talk about HikaSerial- - Serial: Bug Report- - Serial: How to?- - Support en Français de HikaSerial (French Support)- - HikaSubscription- HikaAuction- - Auction: Feature requests- - Auction: How to?- - Auction: Bug report Hikashop around the world- Support en Français (French Support)- Russian- - FAQ. Курс выживания с Hikashop. Частые вопросы и о- - Расширения Hikashop- - Наши сайты на Hikashop- 日本語版サポート(Japanese Support)- Thai- German Archives- Bug Report- How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.134 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)

[](#top)
