Custom fields data can't be saved

  • Posts: 252
  • Thank you received: 1
9 years 3 months ago #243036

-- HikaShop version -- : HikaShop Business 2.6.3,
-- Joomla version -- : 3.5
-- PHP version -- : 5.12.12

Hi,
I new a product custom field for user to put their video clip from youtube, the input format is like :
<iframe width="560" height="315" src=" www.youtube.com/embed/fvEZUbzqqyM " frameborder="0" allowfullscreen></iframe>

I have two questions here :
1. Should I set the input type as text or WYSIWYG ?
2. Currently I set it to be text, but after I save the input, and reopen the product, It just didn't have into the field, no matter I use the front end or back end product edition page.
3. I will show the result into the show_tabular, and I have added a video tag, but I don't know what attribute in $this->fields->vedio that content the HTML code maintained above. ?
Thanks

Best Regards

Please Log in or Create an account to join the conversation.

  • Posts: 252
  • Thank you received: 1
9 years 3 months ago #243038

Sorry, I forgot to attache the screenshot.
As you can see, I have set 2 custom fields, the first one is a radio button type, the data was saved, and the second one is the video one, it showed no data.


Best Regards

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 252
  • Thank you received: 1
9 years 3 months ago #243063

Hi, I just saw the data should be saved in
element->video,
But I still have problem save data into this custom field fro ether front end or backend

Thanks
Best Regards

Please Log in or Create an account to join the conversation.

  • Posts: 84313
  • Thank you received: 13702
  • MODERATOR
9 years 3 months ago #243062

Hi,

1. It should be "text" or "textarea". Otherwise, your WYSIWYG editor might remove the iframe for security reasons.

2. Make sure that the "input validation" setting of the custom field is turned off. Otherwise, the iframe HTML code will be removed automatically.

3. It's easy to do:
<?php echo $this->element->vedio; ?>

Please Log in or Create an account to join the conversation.

Time to create page: 0.060 seconds
Powered by Kunena Forum