rejetto forum

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - LeoNeeson

Pages: 1 2 3 ... 54
HTML & templates / Re: How to do a URL rewrite using macros?
« on: Today at 06:02:45 AM »
Hi, how to run some html script when clicking on some file instead of handled by the browser itself ?
I mean, the default is: When I put MIME n click on a .mp4 file, then browser will open the file only in the browser.
I need to run .mp4 with subtitle support, but it's not a good idea to put index.html in every folder to do that.
I think maybe something can be done in template file so I can put html codes in there to handle .mp4 files.
Im using 2.4rc7. Thanks before.
Hi!, this is complex stuff...

Option A) You need to write a macro to do a 'URL rewrite' (search on the forum about [+request]), but only if end-users are accessing the MP4 directly (this is not the most common situation), but in that case...

For example, you could have these files:
Code: [Select]

So, every time a .mp4 is requested, using a macro HFS could rewrite the URL to deliver the player HTML with the MP4 file attached on the URL, like this:




Option B) But in case end-users are accessing MP4 files from a file listing, then is much easier, since you only need to modify your template and have some HTML knowledge. You only need to have a single 'player.html' with a JavaScript that 'reads' the video from the URL (search on Google about 'read the URL parameters with JavaScript').

If you could share the minimal HTML code of your video player (player.html), that you used to play .mp4 "with subtitle support" on the browser, then we could think a solution to convert it to some macro (I don't promise anything, since it depends on the complexity of the code). As reference only (and out of curiosity), you could comment what library are you using to play subtitles, perhaps MP4Box.js?). By the way, I don't have any small MP4 with subtitles embedded to make some tests, so, don't expect too much help from me.

» Important detail: latest HFS v2.4 RC7 could PROBABLY have some macros broken, since I've already reported here, so even if you have the correct macro, it could not work (unless you find which older version have this working). Sadly, I didn't have the time to find out a solution to this, neither the reason of why it doesn't work.

That's all I can help for now, I hope it helps! :)


PS: You could edit the title to 'How to do a URL rewrite using macros?' to get more attention to your request.

HTML & templates / Re: question
« on: March 25, 2023, 11:38:06 PM »
i cant rename file to index.html but i can download and upload it as index.html lol
"Just live with it" ;) (until it's fixed, possibly never). Thanks for the report, anyway. You can edit the template and remove the protection check, but it's not recommended (since it requires you to have knowledge to not break the template).

Wait a minute... :o I hear Rejetto's footsteps approaching coming here, possibly to suggest you to try the brand-new HFS v3, which you already know: is 100x much better (and 10x more bloated too, but sadly I can't run it on my WinXP to test it). So, I better leave you now before he comes.
See you next time, bye...

HFS ~ HTTP File Server / Re: Ask how to Logout
« on: March 24, 2023, 09:06:26 AM »
i don't remember if 2.4 offers logout, maybe yes.
Mmmm, yes, maybe, perhaps, probably... 🤔

(Sorry, it was an easy joke)

HTML & templates / Re: question
« on: March 16, 2023, 08:35:35 PM »
do you know how i could allow uploading html files?
Sorry, I was busy, and I couldn't answer...

It's easy, follow these steps: ;)

1) Right-click on the folder you allow uploads, and choose 'Properties...'

2) Go to 'File masks' tab, and on 'Upload filter mask' write this:

(for allowing any type of file)


(for HTML files only)
(this only allows: .htm and .html files)

If you need to allow several types, you can separate using ;

For example (more examples):

(this only allows: .htm, .html, .jpg, .jpeg, .txt and .rar files)

I guess this also answer this question (since it's the same question)


HTML & templates / Re: question
« on: March 11, 2023, 07:46:45 PM »
is it possible to edit the baked in html or icon files of hfs?
Yes, it's possible (this was answered on the FAQ, but requires being competent in HTML to not break things). This was answered several times on the forum. :)

router & port problems / Re: port forwarding and hosting
« on: March 11, 2023, 07:40:24 PM »
is it possible to host a hfs server with an ipv6 public ip adress...
Yes, it's possible (IPv6 is supported on both: HFS v2.4 and HFS 3) it possible to port forward on a mobile network
This is a very broad question (hard to answer question). Some mobile network operators use NAT, so the address you see is not directly pointing back to your device, while others block inbound port forwarding. It also depends on the device you use to connect to the mobile network (it's not the same thing using an Android or iPhone, than some 4G LTE USD dongle). Even if you say what device you use, your mileage may vary. If you have some networking knowledge, in case your mobile ISP blocks port forwarding, what you probably need is a reverse tunnel (it can be done doing a reverse SSH, and for that you need to rent a VPS). You could follow THIS guide if you are skilled with Linux. That's all I can help (covering all the details, gets too technical). Hope this helps. :)

Bug reports / Re: How to delete files.
« on: February 09, 2023, 04:15:25 PM »
Doing this stuff is very consuming, sometimes painful.
I fully understand you, now more than ever. :-[ These days (and the last two months) I barely had time to live: I'm on a rush all day, with almost no time to rest or take a break, and the worst thing: it's not for getting rich, but to maintain a minimum quality of life (to cover all the basic things). I'm taking high debt with the banks, and this is no good. Check this nice graph to understand and see how Argentina is, here (with his related article), and it is not an exaggeration. The only way to survive here is working for a multinational enterprise company (having a good salary), or to have a very well established business (chance that no everyone has). In the medium to long-term, I plan to go to another country (some neighboring country), but it's not an easy task (since the pandemic delayed everything and inflation is getting worse year after year). Don't get me wrong, I love living here (it's a beautiful country), but the economy since a long time is a curse.

there's no need to be "intentional".
The Occam's razor principle was the perfect explanation (with the new HFS v3 you seek to 'simplify' the task of maintaining and bug-fixing, rather than waste time you don't have on v2). This principle covers the 'rule of simplicity' and also gives the idea that 'the simplest explanation is usually the best one'. Sorry for my previous message (it wasn't with malicious intent). Neither was a criticism towards you, but rather a message to the rest of users that expect overnight 'bug-fixing' of HFS v2's issues, ...and with your absence for many months, the sailors began to invent stories, LOL. ;D

i'm just commenting to let you know what I think, i'm not angry or sad
That speaks well of you. :) This forum helps me ‘disconnect’ from the problems of my daily life, and I truly appreciate it (thank you for having it online).

Bug reports / Re: Hfs.exe - Maulware via PUP
« on: February 06, 2023, 09:10:36 PM »
Hi, if you have it downloaded from a ‘trusted source’ (from here or here), you can rest assured it is a ‘false positive’. About the digital signature, ‘code signing’ is expensive (not free, even for open source projects).

Programmers corner / Re: Only one thing that wasn't released about HFS...
« on: January 05, 2023, 07:42:55 PM »
Thanks for the file! (I will try it on my spare time)

I had to remove from the source the part related to antiflood because it is bound to my database
That's fine (it's fair and understandable), and it's not quite important since it's unrelated to HFS (there are plenty PHP antiflood scripts on Google).

you have my email address, next time send me the link to your post if you want to catch my attention.
Yeah, but I didn't want to bother you (I'll keep it in mind for next time)

Grazie mille! :D

Beta / Re: 2.4 template-making guide
« on: December 28, 2022, 10:12:15 PM »
2.4 beta 2 - The option.newfolder=0 works fine
2.4 beta 3 - The option.newfolder=0 is ignored, "new folder" does not turn off
Thank you, I will check the source code this weekend, and try to fill a bug report on the next days. My free spare time is limited, so don't expect this to be fixed soon (and also, Rejetto is not actively working on v2.x branch). That said, your report is very appreciated.

» EDIT: I've found the problematic commit where this bug was introduced, HERE. We still need to analyze how to keep the improvements, but fix this issue. Please be patient, until we find a solution.

Beta / Re: 2.4 template-making guide
« on: December 28, 2022, 12:58:15 AM »
But why is option.newfolder=0 not working?

HFS 2.4.0 RC7 build #319
The best way to 'catch' where this error was introduced, is to test each build backwards. First, my recommendation is making a backup of your config files .ini and .vfs, and then start testing builds: RC6, RC5, RC4, RC3, etc. until you find the working version. This way it is much easier to find where the bug is.

Everything else / Best DynDNS alternative:
« on: November 22, 2022, 08:46:34 AM »
Many users of HFS have asked in the past (on this forum), what is the best alternative to DynDNS, and from my own experience, nothing beats
(and this is NOT an advertisement, since I'm not getting paid for commenting this).

His owner (Joshua Anderson) is very friendly, and his services are trustworthy (he has more than 20 years of experience, working online since 2001). You can use it for free or by paying only $5 USD/monthly ($60/yr). Although I'm not a Premium member of them (since I currently can't afford it), I highly recommend it to anyone here, and I can't say enough good things about this service.

You can use your own domain (to delegate your DNS to them) and start using it to self-host content (for example, using HFS as server); or by choosing a subdomain from any of their 41,950 domains, which half of them, are only available if you are a paid customer (by getting a Premium Membership). But if your budget is tight, you can use a subdomain, and start using it for free, for as long as you want.

If you need any help to configure and use it with HFS, just leave a message here, and I will try my best to help you. :)


Bug reports / There was a message here yesterday...
« on: November 17, 2022, 03:55:25 AM »
» Edit: there was a message here, only valid for yesterday: November 17, 2022 (but it seems he has forgotten about us: his loyal community of users ). By the way, my message now it's being replaced with the following image (as a meme). From my point of view, this is how it looks for the average user of HFS v2...

Versione italiana per lui (English version for the rest, here)

...I don't want to sound dramatic, but when HFS v3 started flying high (and when v2.4 stalled with an ‘RC’ version, without ever seeing a final stable version), from that moment I began to worry. The difference with my comparison, is that this was intentional (in favor of the new v3.x), and not something accidental, since the ‘captain’ got tired of supporting the old v2.x branch. But don't worry, HFS v2.x is unsinkable .

Sorry, I had to say it.- 8) ;D ::)

HFS ~ HTTP File Server / Re: Rejetto HFS file server alternative?
« on: November 15, 2022, 04:30:53 AM »
madmax leo my man
Fysack! it's been a long time since your visit on the forum. I'm wondering how are you (I hope you are doing well). HFS v2 needs your fixes! ...and this forum some more action.

Programmers corner / Re: Macros matching only a Content-Type
« on: November 12, 2022, 02:56:04 AM »
I've also tried this (without success, since it doesn't work as expected):

Code: [Select]
{.add header|Expires: 0|if=

Neither this works...

Code: [Select]
          {.add to log|Web site served 2.}
  {.add header|Expires: 2.}

This is puzzling, but after many crazy tests, I think we got a bug...

See, this example SEEMS to working (but it's working bad, see at the end):

Code: [Select]
{.disconnection reason|It seems to work since all UA have Mozilla|if=

But this another example should NOT work (since 'Content-Type' can never be 'Mozilla'):

Code: [Select]
{.disconnection reason|Whoa there, something is wrong here|if=

And another crazy example...

Code: [Select]
{.disconnection reason|It should work since there is no mysterious browser|if=

» Result: Something weird is happening here (or I'm doing all wrong)... :o

*** Since I already know Rejetto is not actively working on v2.4x (and I don't expect him to do it), I'm open to receive the modifications needed in the source code to fix this (since I can compile HFS by myself). ***

Pages: 1 2 3 ... 54