We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Rackspace Cloud Files Fieldtype for EE2.0

Development and Programming

Christopher Imrie's avatar
Christopher Imrie
57 posts
16 years ago
Christopher Imrie's avatar Christopher Imrie

I’ve created a Rackspace Cloud Files EE2.0 fieldtype for a recent project and I was considering releasing it as a fieldtype. However, before I go down the route of refactoring the code and writing up documentation, I wanted to get a judge of as to whether anyone would find this useful.

I know Amazon S3 is pretty popular, but I just dont know how many Rackspace Cloud Files users there out there, and whether there is demand for this fieldtype.

Attached is a screenshot of it on the publish page.

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen

Hi Christopher,

You beat me to it as I was going to ask you about it in your post about the Apple Store as to what exactly it is. I currently have the S3 extension but what I’d really love to see is something like that but just for straight FTP on the server you are on so that you can get to anywhere you like. Ultimately what I’d really really like is one whereby you set the folders as per normal in the File Upload Preferences and then you could perhaps have two multi-list items which would allow you to choose member groups in them.

One multi-list being member groups that are allowed to view up the folder hierarchy and then a list for groups that are only allowed to see from that folder onward. In fact thinking about it this would probably be better with just the one multi-list and you just choose the groups that you want to be able to go up the folder tree and then all other member groups would only be allowed down the tree.

Do you think anything like that would be possible?

Best wishes,

Mark

P.S. I don’t see in the image above but are you able to upload files from that fieldtype?

       
Christopher Imrie's avatar
Christopher Imrie
57 posts
16 years ago
Christopher Imrie's avatar Christopher Imrie

Yeah, that’s not a bad idea. I dont foresee any problem with creating a fieldtype like that, and I am sure it would be pretty useful for some situations. Since I’ve got the front end working, I should be able to add FTP support.

Also setting top level directories according to member groups should be pretty simple too. I would probably also add the ability to select a specific folder on an individual fieldtype level.

As for uploading, this already works on the fieldtype as it stands, but it would require the most work in order to make sure it is stable since it requires uploading to your server first before then being sent on to Rackspace Cloud Files (or indeed FTP). The delay caused by the second file transfer step to the final destination means there needs to be a front end visual indication that this is occuring.

I’ll have a play around over the next few days, and see what I come up with.

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen
I’ll have a play around over the next few days, and see what I come up with.

Would love to see whatever you come up with as I’m sure this one would be absolutely fantastic. Just wondering as well do you think this would be difficult to port back to the 1.6.x branch?

Best wishes,

Mark

       
Christopher Imrie's avatar
Christopher Imrie
57 posts
16 years ago
Christopher Imrie's avatar Christopher Imrie

The core functionality of the FTP and Cloud Files should be ok to backport, but it might not be as elegant as EE2.0 since it handles fieldtype javascript much better than 1.6.x.

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen
The core functionality of the FTP and Cloud Files should be ok to backport, but it might not be as elegant as EE2.0 since it handles fieldtype javascript much better than 1.6.x.

Ah right. Just thought it might be nice in 1.6.x as well but I’m just really looking forward to what you come up with. The most I’ve ever been able to make is plugins and the odd extension or two. Modules and FieldFrame extensions are WAY over my head at the moment and I never seem to get the time to learn any more so that I can make them myself which is a pain.

Best wishes,

Mark

       
Christopher Imrie's avatar
Christopher Imrie
57 posts
16 years ago
Christopher Imrie's avatar Christopher Imrie

Here is a sneak peak at this fieldtype action, with added support for FTP and S3. You can switch between the various remote locations whilst in the Publish form by clicking on the tabs. At the moment you can restrict which remote locations are shown at the field level, so if you only want to show one remote location, you can(the tabs disappear if you do).

I’ve built it to be modular, so its pretty easy to add remote file methods. Directory browsing works, refresh as well as switching between the remote locations (all via Ajax), but it still needs a fair bit of work to be robust (couple of js errors creeping about at the moment)

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen

Wowzers!!!

That looks absolutely stunning! Well done on that one, that is some seriously fantastic work.

Would love to be able to test it at some point if you’re willing?

Best wishes,

Mark

       
Christopher Imrie's avatar
Christopher Imrie
57 posts
16 years ago
Christopher Imrie's avatar Christopher Imrie

Cheers Mark. Yeah, I had a good crack at this over the weekend, and it works pretty good, with tags rendering correctly in templates as full url’s, regardless of the connection method. But there is one glaring problem with it at the moment, and thats the fact that the Ajax requests are unsecured, and the configuration settings (username, password) are sent with each request. Not ideal.

Reason I was doing it this way is since I wanted to see if I could keep it a just a fieldtype with modular extensions. Now that I can see the bigger picture I need to setup a module interface so that i have a secure endpoint for each Ajax request. This will also let me centrally manage caching for all the different connection methods, which is definitely needed for Rackspace Cloud Files & S3 since they charge you for simply reading data.

When I cobble something together with the above features in place, I’ll do some Beta testing and send you the files since two heads are better than one.

Progress is going to have to halt for a few days though, since I have to focus on client work, but will have another crack at it when I can.

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen
When I cobble something together with the above features in place, I’ll do some Beta testing and send you the files since two heads are better than one. Progress is going to have to halt for a few days though, since I have to focus on client work, but will have another crack at it when I can.

Sounds fantastic. Can’t wait to take a look at this one. Whenever you can send over anything for me to look at is fine, just very kind of you to do so.

Best wishes,

Mark

       
trif3cta's avatar
trif3cta
148 posts
16 years ago
trif3cta's avatar trif3cta

+1

I’d be very interested and I’m sure there are others.

       
Christopher Imrie's avatar
Christopher Imrie
57 posts
16 years ago
Christopher Imrie's avatar Christopher Imrie

Just a small update to say that work is progressing on this fieldtype.

All AJAX requests are now secured via passing the session XID. Currently converting each remote connection method to have its ajax request sent through a central gateway to reduce redundancy.

Will update again in a few days.

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen
Just a small update to say that work is progressing on this fieldtype. All AJAX requests are now secured via passing the session XID. Currently converting each remote connection method to have its ajax request sent through a central gateway to reduce redundancy. Will update again in a few days.

Sounds great. Can’t wait to see what you’ve done with this one.

Best wishes,

Mark

       
Mark Croxton's avatar
Mark Croxton
319 posts
16 years ago
Mark Croxton's avatar Mark Croxton

This looks amazing - really great work! I would also love to beta test for you 😊

       
lincolnpixel's avatar
lincolnpixel
83 posts
16 years ago
lincolnpixel's avatar lincolnpixel

Hi,

I’d be very interested 2!

       
1 2 3

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.