Skip to content

Instantly share code, notes, and snippets.

@Maharony
Maharony / Storyboard.txt
Created February 26, 2018 18:44
Story board Android App
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:orientation="vertical"
android:layout_margin="16dp"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="com.example.ekene.imageboardcloudinary.MainActivity">
@Maharony
Maharony / Gallery Data Source
Created February 28, 2018 18:39
Gallery Data Source
_index.html_
<!doctype html>
<head>
<meta charset="utf-8">
<meta name="robots" content="noindex,nofollow" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<link rel="stylesheet" type="text/css" href="//cloudydesk.com/theme/css/cleanslate.css">
<link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="//cloudydesk.com/theme/css/bootstrap-cloudinary-theme.css">
_index.html_
<body id="cl-container" style="background-color:#142335;" >
<nav class="navbar navbar-inverse clearfix">
<div class="container">
<div class="navbar-header">
<a class="navbar-brand" href="#"><img src="//res.cloudinary.com/cloudinary/image/upload/c_scale,w_200/v1/logo/for_dark_bg/cloudinary_logo_for_dark_bg.png" alt="Cloudinary"/></a>
</div>
<div id="navbar" class="navbar-collapse collapse">
<h2 class="flushtop" style="margin-left:40%">360 Product Viewer</h2>
js
window.totalFramesFromVid = 100;
function widget(){
window.cloudinary.openUploadWidget({ cloud_name: 'xxxxxxx', upload_preset: '3dImage', client_allowed_formats: ['mov','mp4','webm'], sources: ['local','camera']},
function(error, result) {
if(!result)return;
//console.log(result)
window.result=result[0];
window.vidLength = window.result.duration;
window.frameGap = (window.vidLength/window.totalFramesFromVid).toFixed(2);
js
var product1=!1;
function build(){
if(product1){
$("#canvas").find('.product1').remove();
$("#canvas").html('<div class="threesixty product1"style="text-align:center"><div class="threesixtyInner"><div class="spinner"><span>0%</span></div><ol class="threesixty_images"></ol></div></div>');
};
$('.threesixtyInner').css({ 'padding-bottom': `${ 100 / window.aspectRatio }%` });
product1 = $('.product1').ThreeSixty({
```
{
"to": "daniel@example.com",
"subject": "email subject" ,
"url": "https://my-bi-tool.com/daily_report.html",
"schedule": "0 10 * * *"
}
```