Sha256: bdf5b1169cde2b818c3cb3989cd0fe4fb5ed9e1e2a6f6b70e28ba766bbb65739

Contents?: true

Size: 1.64 KB

Versions: 18

Compression:

Stored size: 1.64 KB

Contents

=begin
<script type="text/javascript">
<% session_key_name = Rails.application.config.session_options[:key] %>

// Default options
$(function() {
	var uploader = new plupload.Uploader({
    runtimes: 'html5,flash',
		//url: '<%= photos_path %>',
		//container : 'container',
		browse_button : 'applicious_uploader',
		max_file_size : '10mb',
		flash_swf_url : '<%= asset_path("plupload.flash.swf") %>',
		
		multipart: true,
    multipart_params: {
      '_http_accept': 'application/javascript',
      'authenticity_token' : '<%= form_authenticity_token %>',
      '<%= session_key_name %>' : encodeURIComponent('<%= u cookies[session_key_name] %>')
    },

		filters : [
			//{title : "Zip files", extensions : "zip"},
			{title : "Image files", extensions : "jpeg,jpg,gif,png"},
		],
		
		//resize : {width : 320, height : 240, quality : 90},
		    
		filters : [
			{title : "Image files", extensions : "jpg,gif,png"},
			{title : "Zip files", extensions : "zip"}
		],
	});
	
	uploader.bind('FilesAdded', function(up, files) {
		$.each(files, function(i, file) {
			$('#filelist').append(
				'<div id="' + file.id + '">' +
				file.name + ' (' + plupload.formatSize(file.size) + ') <b></b>' +
			'</div>');
		});

		up.refresh(); // Reposition Flash/Silverlight
	});


	uploader.bind('UploadProgress', function(up, file) {
		AP.log( up, file );
	});

	uploader.bind('Error', function(up, err) {
		AP.log( up, err );
		up.refresh(); // Reposition Flash/Silverlight
	});

	uploader.bind('FileUploaded', function(up, file) {
		AP.log( up, file );
	});

	uploader.init();

	$('#uploadfiles').click(function(e) {
		uploader.start();
		e.preventDefault();
	});

});
</script>
=end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
applicious_utils-0.1.47 lib/generators/templates/session_store.rb
applicious_utils-0.1.45 lib/generators/templates/session_store.rb
applicious_utils-0.1.43 lib/generators/templates/session_store.rb
applicious_utils-0.1.41 lib/generators/templates/session_store.rb
applicious_utils-0.1.40 lib/generators/templates/session_store.rb
applicious_utils-0.1.39 lib/generators/templates/session_store.rb
applicious_utils-0.1.38 lib/generators/templates/session_store.rb
applicious_utils-0.1.37 lib/generators/templates/session_store.rb
applicious_utils-0.1.36 lib/generators/templates/session_store.rb
applicious_utils-0.1.35 lib/generators/templates/session_store.rb
applicious_utils-0.1.34 lib/generators/templates/session_store.rb
applicious_utils-0.1.33 lib/generators/templates/session_store.rb
applicious_utils-0.1.32 lib/generators/templates/session_store.rb
applicious_utils-0.1.31 lib/generators/templates/session_store.rb
applicious_utils-0.1.30 lib/generators/templates/session_store.rb
applicious_utils-0.1.29 lib/generators/applicious_utils/templates/session_store.rb
applicious_utils-0.1.28 lib/generators/applicious_utils/templates/session_store.rb
applicious_utils-0.1.27 lib/generators/templates/session_store.rb