Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hello everyone, I would like to create my own Content type, it would be youtube video which wold render itself differently on AMP page and on normal page. Can anyone please point to right direction? Thanks!
have a look at this blog post.
There is an example on how to create a custom grid editor that is ready for AMP:
Hello Daniel, thanks for your reply, I saw that one, it won't work because the image there is using fixed width and height and that's not realistic for production environment. And currently the media object isn't exposing width and height, which I want to fix also. Thus I want to create my own content type from scratch..
don't think that is possible at all. There are Media, Folder and File. Nothing you can create like CustomMedia.
I think AMP images are always the same size as they should fit for mobile devices. For images resizing have a look at ImageProcessor which comes with Umbraco. With that, you can resize images on the fly by query parameters. Of course cached so images won't get recreated on every page hit.
Maybe I misunderstand what you really need?
There is option in backoffice to create new Media Type, so I guess its not a problem. What I don't understand is the plumbing from the MediaType to the Grid and than to the Razor. If I just could add width and height to the current media being serialized to the media view, that would do it.
I'm using AMP images like this (in carousel)
Blue water Express Bali fast boat I would like to maintain the aspect ratio of the images. Now I need to add them to the Grid Content. And the youtube is also different story.
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted