Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#61 2011-11-13 21:11:51

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,446
Website GitHub

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

robhert wrote:

Seems like smd_remote_file is not working with TXP 4.4.1

Ah yes, I get a javascript ‘unterminated literal’ error. It seems that the line of code in the core that automatically injects the txp_token into the form is adding itself as a separate ‘line’ so jQuery thinks the form is not finished when it encounters the newline, and throws a wobbly. I’m not sure of how to work around it in this version.

The sort of good news is that in the next version — never released, because development stalled — I took a completely different approach, so the part that draws the upload box does actually work in 4.4.1. But since I never finished the plugin there are all sorts of other parts in a half-finished state so the plugin is unusable as it is right now.

Is it urgent that you get this working right away? If so I could perhaps squeeze some time to look into either releasing the current revamped v0.50, or try and fix the old one. If you can wait a bit I might be able to do things better. What are you trying to do with the plugin? Is there any way we can use something else to achieve what you want to do?


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Online

#62 2011-11-16 03:09:59

georgeM
Member
From: Toronto, Canada
Registered: 2006-02-27
Posts: 43
Website

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

Hi Stef,

I could actually use a working version of this plugin for TXP v4.4.1 as well. I am trying to build a site which manages downloads and supports mirroring (specifically custom Android ROM downloads), and it would be great if this was working as I am now based on 4.4.1.

Anyways, needless to say sooner would be better, but it’s no particular rush. I am just more than glad you’ve taken the time to develop such a great plugin!

All the best, and thanks again,

- George

Offline

#63 2011-11-25 21:48:08

georgeM
Member
From: Toronto, Canada
Registered: 2006-02-27
Posts: 43
Website

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

I don’t mean to be a persistent ‘bug’, but can we get an idea of your thoughts on adapting/updating this plugin for TXP 4.4.1 Stef? It’s very powerful, and I need to implement it in a project, particularly for the ‘load-balancing/mirror-site’ benefits.

Again, not trying to be rude here, but just hoping to get your thoughts/timeline so I can better evaluate what I’m going to do.

Thanks!

Offline

#64 2011-11-26 21:11:49

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,446
Website GitHub

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

georgeM wrote:

can we get an idea of your thoughts on adapting/updating this plugin for TXP 4.4.1

Sure (sorry not to answer earlier btw). I could. I probably should. But I don’t know if I will any time soon as there are other plugins that need attention for my current client.

However, if you really need remote file access and something like smd_access_keys doesn’t do it for you, then I could try and squeeze in some face time with this plugin. Honestly can’t remember what state I left it in when I last touched it a few years ago. Might be a total mess or it might just need a few tweaks to at least get it limping along for your needs, albeit if it’s not a full release.

Part of the reason for sidelining this plugin was that I was intending to use it to offer secure downloads (non-web-accessible) as well as remote ones. Then things like smd_access_keys and smd_ipn stole the limelight and the need for this functionality diminished somewhat. If the secure part doesn’t interest you then maybe I can comment out that part and see if it’ll run. Could you perhaps let me know which tags/functionality you are thinking of using so I can gauge where I need to focus efforts and if it’s viable to do so in the short term? Thanks.

Last edited by Bloke (2011-11-26 21:13:24)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Online

#65 2011-12-01 16:27:12

georgeM
Member
From: Toronto, Canada
Registered: 2006-02-27
Posts: 43
Website

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

Bloke wrote:

Sure (sorry not to answer earlier btw). I could. I probably should. But I don’t know if I will any time soon as there are other plugins that need attention for my current client.

However, if you really need remote file access and something like smd_access_keys doesn’t do it for you, then I could try and squeeze in some face time with this plugin. Honestly can’t remember what state I left it in when I last touched it a few years ago. Might be a total mess or it might just need a few tweaks to at least get it limping along for your needs, albeit if it’s not a full release.

Part of the reason for sidelining this plugin was that I was intending to use it to offer secure downloads (non-web-accessible) as well as remote ones. Then things like smd_access_keys and smd_ipn stole the limelight and the need for this functionality diminished somewhat. If the secure part doesn’t interest you then maybe I can comment out that part and see if it’ll run. Could you perhaps let me know which tags/functionality you are thinking of using so I can gauge where I need to focus efforts and if it’s viable to do so in the short term? Thanks.

Heya Stef! My apologies also for not getting back to this thread with a response earlier. I completely understand your time constraints, and I must tell you that while I could have used a new version, it’s not critical. I do NOT want to impede upon your other duties with other plugins.

I will surely take a look at smd_access_keys and smd_ipn to see if I can adapt them to suit my needs. The ‘secure’ downloads do not concern me as a side point, as I would be using them for public accessible downloads. Anyways, I will take a look at your other plugins and post any responses if need be.

Again, I want to thank you immensely for your dedication to your work and TXP in general. You are truly top notch!! ;)

Cheers!

Offline

#66 2012-10-02 01:41:07

maniqui
Member
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 3,070
Website

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

A quick fix I’ve had to apply on some server:

   $tmp = tempnam("/tmp", "smd_");
   $handle = fopen($tmp, "w");
   fwrite($handle, $url.n);
   fclose($handle);
   rename($tmp, $dest_filepath);
+  chmod($dest_filepath, 0644);

This will set the proper permissions on the created .link file.
On the website I’ve applied this fix, the server was setting 600 as default permissions for files created using smd_remote_file, and thus, later, smd_remote_file would time out when trying to read the file for getting the remote URL.
BTW, I’ve my doubts regarding how this partiular server was configured, in the sense that I think they were some suboptimal/unsecure settings for folders/files permissions.


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

#67 2012-10-10 14:51:16

sacripant
Plugin Author
From: Rhône — France
Registered: 2008-06-01
Posts: 479
Website

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

Hello Steph,

This plugin is compatible Txp 4.5.x ?
After installing and activate plugin, no new form is added to the tab “files”.

Thanks

Offline

#68 2012-10-10 14:58:12

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,446
Website GitHub

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

sacripant wrote:

This plugin is compatible Txp 4.5.x ?

Probably not. But it has undergone a major revision since last seen here. let me have a play with it to get it working on 4.5 and I’ll post here when it’s available.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Online

#69 2012-10-10 23:06:13

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,446
Website GitHub

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

Please try out the beta smd_remote_file v0.50 which is for 4.5.x only.

Not only does it bring remote file capabilities as before, it allows you to tuck files away in a secure non-webroot location and/or offer hidden and pending files for download to privileged users. This gives you some pretty neat workflow options. The prefs can be configured to enable or disable the parts you require.

There are a few niggly little things to sort out — mainly visual (like the fact the upload doesn’t give a success message) — but I’ll probably figure those out before final release. If anyone notices any warnings or errors, please report them here along with the steps you took that led to the problem and I’ll take a look.

Enjoy!


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Online

#70 2012-10-11 15:21:42

sacripant
Plugin Author
From: Rhône — France
Registered: 2008-06-01
Posts: 479
Website

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

Wouaw cool, thanks Steph
I return with a feedback in a few days.

Offline

#71 2013-01-16 12:10:32

sacripant
Plugin Author
From: Rhône — France
Registered: 2008-06-01
Posts: 479
Website

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

Some feedbacks about smd_remote_file 0.5 :

  • When you upload a file via url field you don’t go automatically to the file details/modify page. We stays on the same page.
  • No creation date is inserted in the database. I need to check on “Publish Now” checkbox to insert date.
  • file link smd_file_download_link seem not work :
    if I’m downloded a file name one.zip, smd_file_download_link return site_url/file_download/ID/one.zip and Textpattern display a 404 error context.

Regards

Offline

#72 2014-05-05 01:32:18

nardo
Member
From: tuvalahiti
Registered: 2004-04-22
Posts: 743

Re: smd_remote_file: Manage remote URL downloads via TXP's Files tab

On Txp 4.5.2 – using the ‘files’ form with smd_file_download_link – and calling a public remote URL … getting the same issue as sacripant with the URLs constructed site_url/file_download/ID/my_remote_file_name

Offline

Board footer

Powered by FluxBB