I am a freshman using ruby-on-rails, I want to build a website that provides users tutor videos. The problem is how can I upload a video or document on my webpage using ruby-on rails, my strategy is to save a link for that video or document in the data base so when I open a page contains a video or document it will upload automatically.
I am using Postgresql 9.3
Thanks.
Tyry using paperclip gem
It will be easier, you can look into this link
https://devcenter.heroku.com/articles/paperclip-s3
Related
I like to write an api that accept from the user a video via a post command. Any body can let me know how can I use Flask-Uploads for extensions mp4 or other video extensions?
The version of Flask-Uploaded on PyPi is broken since February 2020.
You can use the drop in replacement: https://pypi.org/project/Flask-Reuploaded/
When you want a file extension, which is not contained in a pre-defined set, you just can create your own one.
e.g.
VIDEOS = tuple("mp4 mov")
and then configure Flask-Reuploaded as described in the documentation, i.e
videos = UploadSet('videos', VIDEOS)
If you do not want to use Flask-Reuploaded, there is a very good blog post by Miguel Grinberg explaining all the details - without using an upload extension:
https://blog.miguelgrinberg.com/post/handling-file-uploads-with-flask
Deployed a blog on Heroku. I upload the picture to the record through the admin panel on Dropbox via django-storages. The picture appears in the Dropbox application, but I don’t understand how to load the link to it. How to embed Dropbox pictures? You can advise other ways. While the idea is only to manually link links to the database ...
How can I create a video and photo uploading feature on my website using Python and Django?
I have using forms,models(file_field) and yet it doesn't render to the front_end
If you're using ImageField to upload to the server, make sure you have pillow installed. Your python may just be looking at a wrong path to search for your files. Secondly, you might want to consider your markup code, and make sure that there is space for your video to be uploaded. ie) , etc..
I'm trying to download a videofile from contentful. After getting asset id how can i proceed to download the content from CONTENTFUL using that asset id ?
Edit: I am not asking for exact code. Just need the steps to proceed. Or any link. The docs confused me.
What you do is you use the asset id to fetch the asset from Contentful. The asset then contains the actual url to your binary video file.
Like this:
client.asset('<asset_id>').url()
We have migrated brightcove from one environment to another by taking items related to brightcove from the existing environment and moving files manually.
However in the new environment brightcove seem to be working(I tested brightcove import/export/cleanup by adding those buttons to MyToolbar as shown in screenshot 2) except for the below issue.
Issue: ”Media Framework tab is not visible in the ribbon”
Screenshot 1
ScreenShot 2
Can you help me on this? Any idea on how to enable that tab?
Package Details are as below:
Sitecore Media Framework rev. 130924.zip
Items in the above package:
core\sitecore\content\Applications\Content Editor\Menues\Media Framework
core\sitecore/content/Applications/Content Editor/Ribbons/Chunks/Media Framework
core/sitecore/content/Applications/Content Editor/Ribbons/Strips/Media Framework
core/sitecore/content/Applications/Media/MediaFramework
core/sitecore/content/Applications/WebEdit/Custom Experience Buttons/Embed Media
core/sitecore/layout/Layouts/Media/EmbedMedia
core/sitecore/layout/Layouts/Media/Uploader
core//sitecore/system/Field types/MediaFramework
core/sitecore/system/Settings/Html Editor Profiles/Rich Text Default/Toolbar 1/Embed Link
core/sitecore/system/Settings/Html Editor Profiles/Rich Text Default/Toolbar 1/Embed Media
core/sitecore/system/Settings/Html Editor Profiles/Rich Text Full/Toolbar 1/Embed Media
core/sitecore/system/Settings/Html Editor Profiles/Rich Text Full/Toolbar 1/Embed Link
master/sitecore/layout/Placeholder Settings/embedMedia
master/sitecore/layout/Sublayouts/Media Framework
master/sitecore/media library/Media Framework
master/sitecore/system/Modules/Media Framework
master/sitecore/system/Settings/Analytics/Page Events/Media Framework
master/sitecore/system/Settings/Analytics/Reports/Reports/Media Framework
master/sitecore/system/Settings/Analytics/Reports SQL Queries/Most Completed Videos
master/sitecore/system/Settings/Analytics/Reports SQL Queries/Most Popular Videos Started But Not Completed
master/sitecore/system/Settings/Analytics/Reports SQL Queries/Most Started Videos
master/sitecore/system/Settings/Buckets/Settings/Quick Actions/Media Preview
master/sitecore/system/Settings/Rules/Command Rules/Actions/Set Command State
master/sitecore/system/Settings/Rules/Command Rules/Command State Rules
master/sitecore/system/Settings/Rules/Command Rules/Rules
master/sitecore/system/Settings/Rules/Common/Conditions/Media Framework
master/sitecore/system/Settings/Rules/Item Saved/Rules/Clear Media Framework Rules Cache
master/sitecore/system/Settings/Rules/MediaFramework
master/sitecore/system/Settings/Validation Rules/Field Rules/Media Framework
master/sitecore/templates/Branches/Media Framework
master/sitecore/templates/MediaFramework
master/sitecore/templates/System/Rules/CommandStateRule
Sitecore Media Framework Brightcove rev. 130924.zip
Items in the above package:
core/sitecore/content/Applications/Content Editor/Menues/Media Framework
core/sitecore/content/Applications/Content Editor/Ribbons/Chunks/Media Framework
master/sitecore/system/Modules/Media Framework
master/sitecore/system/Settings/Rules/Command Rules/Rules
master/sitecore/system/Settings/Rules/Insert Options/Rules/MediaFramework Brightcove
master/sitecore/templates/Branches/Media Framework
Thanks,
Suhas
You missed the /sitecore/content/Applications/Content Editor/Ribbons/Ribbons/Default/Media Framework item.
Use AccessViewer and see which role is denying read access to "/sitecore/content/Applications/Content Editor/Ribbons/Ribbons/Default/Media Framework" and "/sitecore/content/Applications/Content Editor/Ribbons/Chunks/Media Framework" items in core DB.
I found read access to "/sitecore/content/Applications/Content Editor/Ribbons/Chunks/Media Framework" is denied for "Sitecore client users" role, assigning read access to Media Framework chunk item and its descends fixed the issue.
Sorry to give an almost link-only-answer, but Maras is right. You haven't migrated the Sitecore user interface customisations, tools and commands across. These all live in the "core" database.
Mark Stiles has a blogpost that describes the Brightcove files and items in detail, here: http://www.markstiles.net/Blog/2011/03/16/brightcove-in-sitecore.aspx
Look for this section "Inside Sitecore itself there are also a good number of items that you should know about. First in the core are the content editor tabs. These are pretty essential to giving the end user a good UI to work with when they want to view a preview a video in a player or edit an item or even add images to a video. I'll go more into what those look like further into the article."