Hello,
I have noticed that the html editor won't let us add a simple Youtube embed or iframe code, any idea how to go around this problem please? I do not want to upload videos to the server, it takes too long and also can breach the copyright of the video maker if not used in Youtube itself.
Regards,
Ben
How to add an iframe or Youtube embed code ?
Re: How to add an iframe or Youtube embed code ?
Hi Ben, if the field where you want to embed youtube video would always be used for this purpose in all records, you could follow the procedure in this article: http://bigprof.com/appgini/tips-and-tut ... ypal-links ... the article describes integrating Paypal links as iframes, but it would work for youtube as well by changing the iframe code to that for youtube.
AppGini plugins to add more power to your apps:
- DataTalk is an innovative AppGini plugin based on ChatGPT that allows you to interact with your AppGini database using natural language questions, without writing any SQL. Check the demo video
- Mass Update plugin: Update multiple records at once and improve your workflow efficiency.
- Check our other plugins and get a generous discount of up to 30% when buying 2 or more plugins.
Re: How to add an iframe or Youtube embed code ?
Thanks for the reply.
One little thing I do not understand in the tutorial, is seems that we have to hardcode the file but will our records not be erased each time we add a new row in the table?
Thank you,
Ben
One little thing I do not understand in the tutorial, is seems that we have to hardcode the file but will our records not be erased each time we add a new row in the table?
Thank you,
Ben
Re: How to add an iframe or Youtube embed code ?
Umm .. you'll have to hard-code the file indeed .. but that won't get overwritten on adding new records: records are stored in the database, and this file is a template file on the server storage ... Unless I misunderstood your question.
AppGini plugins to add more power to your apps:
- DataTalk is an innovative AppGini plugin based on ChatGPT that allows you to interact with your AppGini database using natural language questions, without writing any SQL. Check the demo video
- Mass Update plugin: Update multiple records at once and improve your workflow efficiency.
- Check our other plugins and get a generous discount of up to 30% when buying 2 or more plugins.
Re: How to add an iframe or Youtube embed code ?
Thank you for the reply Ahmad,
Ben
Ben
Re: How to add an iframe or Youtube embed code ?
Another option works if you are just using your AG code for managing database content, but actually displaying the database content on your web site. (In other words, AG is not your whole web site.)
Add the YouTube code as normal in the AG form as normal. It will convert certain characters into codes. In the output on your web page, convert the codes back into characters.
My concerns are:
1. What kind of security issues could this cause?
2. Are there ways to address those security issues?
Add the YouTube code as normal in the AG form as normal. It will convert certain characters into codes. In the output on your web page, convert the codes back into characters.
Code: Select all
$pattern = array();
$pattern[0] = '/</';
$pattern[1] = '/>/';
$replacement = array();
$replacement[0] = '<';
$replacement[1] = '>';
$video = preg_replace($pattern, $replacement, $youtube_fieldcontents);
1. What kind of security issues could this cause?
2. Are there ways to address those security issues?