examplens
Legendary
Online
Activity: 3920
Merit: 4438
Trêvoid █ No KYC-AML Crypto Swaps
|
What does "Proxied" do in Cloudflare? I currently can't access the URL, while the IP shows Apache's default page. I think you should turn that off.
Probably "proxied" should be turned off in this case. it includes cloudflare protection and caching, currently, it's just an unnecessary extra loop. LoyceV, you should create a virtual host and folder on your side. something like (for Apache) <VirtualHost *:80> ServerName proxyimages.bitcoindata.science DocumentRoot /var/www/proxyimages </VirtualHost> also, don't forget to restart Apache to accept the change edit: add any file in that folder, so you can test it.
|
|
|
|
LoyceV
Legendary
Offline
Activity: 3948
Merit: 21198
Thick-Skinned Gang Leader and Golden Feather 2021
|
 |
January 11, 2025, 06:10:01 PM |
|
I think everything is ready on my end. It'll update hourly, at 20 minutes past the hour. Image directory: proxyimages.bitcoindata.science/Pmalek. It's not working yet, but I expect it to work once Cloudflare stops trying to proxy this link. @Pmalek: I didn't build in any error checking. If something fails, let me know. If anyone else wants this proxy-feature, let me know. I can easily add more users.
|
¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
|
|
|
examplens
Legendary
Online
Activity: 3920
Merit: 4438
Trêvoid █ No KYC-AML Crypto Swaps
|
 |
January 11, 2025, 06:21:30 PM |
|
@Pmalek: I didn't build in any error checking. If something fails, let me know.
Pmalek, also if you don't have a problem, move the current version of your thread somewhere, archive or something. I want to test it with my hosting to fix this problem so that it can be functional without an additional proxy. I had a bit of a busy period last time, I didn't have time to devote myself more to this matter.
|
|
|
|
LoyceV
Legendary
Offline
Activity: 3948
Merit: 21198
Thick-Skinned Gang Leader and Golden Feather 2021
|
 |
January 11, 2025, 06:29:25 PM |
|
|
¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
|
|
|
examplens
Legendary
Online
Activity: 3920
Merit: 4438
Trêvoid █ No KYC-AML Crypto Swaps
|
 |
January 11, 2025, 06:34:21 PM |
|
How's this for testing? ... (Those are all the image links Pmalek sent me, without the rest of his topic)
I can't risk a ban for plagiarism 
|
|
|
|
Pmalek
Legendary
Offline
Activity: 3402
Merit: 8980
|
 |
January 11, 2025, 06:43:38 PM |
|
Pmalek, also if you don't have a problem, move the current version of your thread somewhere, archive or something. I want to test it with my hosting to fix this problem so that it can be functional without an additional proxy. I had a bit of a busy period last time, I didn't have time to devote myself more to this matter. Sorry I didn't understand why you need me to move my thread to perform your tests. Do you want to post in it but don't want to do it where it is now so the staff won't consider it spam? Feel free to take anything from the OP you might find useful and post it on the achieve board. Can the links that LoyceV posted help you?
|
|
|
|
bitmover (OP)
Legendary
Offline
Activity: 2940
Merit: 7282
Trêvoid █ No KYC-AML Crypto Swaps
|
 |
January 11, 2025, 08:47:19 PM |
|
I think everything is ready on my end. It'll update hourly, at 20 minutes past the hour. Image directory: proxyimages.bitcoindata.science/Pmalek. It's not working yet, but I expect it to work once Cloudflare stops trying to proxy this link. @Pmalek: I didn't build in any error checking. If something fails, let me know. If anyone else wants this proxy-feature, let me know. I can easily add more users. I removed the proxy in cloudflare settings  But I still see server down status in this page. https://proxyimages.bitcoindata.science/Pmalek
|
|
|
|
LoyceV
Legendary
Offline
Activity: 3948
Merit: 21198
Thick-Skinned Gang Leader and Golden Feather 2021
|
|
¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
|
|
|
joker_josue
Legendary
Offline
Activity: 2296
Merit: 6609
**In BTC since 2013**
|
 |
January 11, 2025, 10:51:40 PM |
|
What does "Proxied" do in Cloudflare? I currently can't access the URL, while the IP shows Apache's default page. I think you should turn that off.
"Proxied" makes this address pass through the Cloudflare server to reach the website visitor. If you disable this, this address goes directly to the visitor without going through Cloudflare's servers. Basically, disabling this is the same as not having Cloudflare. Maybe in this case, this is not necessary. EDIT: I posted it, and didn't even realize the conversation had continued. Sorry. LoyceV really seems like the result was very positive.
|
|
|
|
Pmalek
Legendary
Offline
Activity: 3402
Merit: 8980
|
 |
January 12, 2025, 08:08:27 AM |
|
Now let's test this: ... I'd say it works, and very fast  Seems great, thanks a lot LoyceV. I will soon update the images in my thread to see how they will perform in that live environment. I don't expect that any issues will arise. Just to confirm, the fiat values get updated once every hour, right? @bitmover Thanks for your help and for assisting LoyceV in getting this up and working.
|
|
|
|
LoyceV
Legendary
Offline
Activity: 3948
Merit: 21198
Thick-Skinned Gang Leader and Golden Feather 2021
|
 |
January 12, 2025, 08:15:27 AM |
|
Just to confirm, the fiat values get updated once every hour, right? Yes: It'll update hourly, at 20 minutes past the hour. Judging by the image times, it takes 1-2 minutes to update everything.
|
¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
|
|
|
bitmover (OP)
Legendary
Offline
Activity: 2940
Merit: 7282
Trêvoid █ No KYC-AML Crypto Swaps
|
 |
January 12, 2025, 10:55:57 AM |
|
Good work LoyceV!! @bitmover Thanks for your help and for assisting LoyceV in getting this up and working.
I am happy loycev solved it! I lack free time and maybe knowledge and permissions to make the solution in my server! Your post is certainly one of the best and most useful implementations of my API, so I am happy it is working again
|
|
|
|
LoyceV
Legendary
Offline
Activity: 3948
Merit: 21198
Thick-Skinned Gang Leader and Golden Feather 2021
|
 |
January 15, 2025, 09:28:02 AM |
|
I'll post this here, since there seem to be knowledgeable people here  There was a problem with caching my images, which means they didn't update often enough on the forum. I posted Image proxy caching problem in Meta. Theymos fixed it: Since that DDoS a while ago, the imageproxy is now going through Cloudflare, which will do server-side caching if allowed by the final origin's headers, and client Cache-Control headers are (I think) always ignored now. (I haven't decided yet whether having the imageproxy behind Cloudflare is permanent.)
That pricing image doesn't send any cache-related headers at all, aside from Last-Modified. If that .htaccess file is intended for that image, then it's not working. One major issue in this case is that: 1. The image doesn't send an Expires header. 2. If an image doesn't have an Expires header, then the imageproxy sets an Expires 1 day into the future. * 3. Cloudflare then server-side-caches this for 1 day based on the Expires header, and there's no way for the client to bypass Cloudflare's cache.
* I just now changed the default Expires timeout to 10 minutes instead of 1 day, at least as long as the imageproxy is behind Cloudflare. But for live content like this, it'd be better if the origin sent headers disabling caching entirely. I don't know how to make Apache2 do the bold part. This isn't enough: I've added this to my .htaccess ( source): <filesMatch "\.(gif|png|jpg)$"> FileETag None <ifModule mod_headers.c> Header unset ETag Header set Cache-Control "max-age=0, no-cache, no-store, must-revalidate" Header set Pragma "no-cache" Header set Expires "Wed, 11 Jan 1984 05:00:00 GMT" </ifModule> </filesMatch> How do I add "no caching" headers to images?
|
¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
|
|
|
examplens
Legendary
Online
Activity: 3920
Merit: 4438
Trêvoid █ No KYC-AML Crypto Swaps
|
 |
January 15, 2025, 01:16:14 PM Merited by JayJuanGee (1) |
|
This isn't enough: I've added this to my .htaccess ( source): <filesMatch "\.(gif|png|jpg)$"> FileETag None <ifModule mod_headers.c> Header unset ETag Header set Cache-Control "max-age=0, no-cache, no-store, must-revalidate" Header set Pragma "no-cache" Header set Expires "Wed, 11 Jan 1984 05:00:00 GMT" </ifModule> </filesMatch> How do I add "no caching" headers to images? I find this missed line, seems like a solution ( here) Header unset Last-Modified Prevents browsers from revalidating content based on the Last-Modified header
|
|
|
|
theymos
Administrator
Legendary
Offline
Activity: 5838
Merit: 15170
|
How do I add "no caching" headers to images?
The headers in your .htaccess file should be sufficient, but the problem is that Apache isn't actually doing what you wrote there. In eg. Firefox, go to the Network tab of Developer Tools, visit your image, and look at the response headers; Cache-Control, Pragma, and Expires are not sent. I haven't used Apache in over a decade, but I would guess that either your Apache is configured to ignore .htaccess files entirely (which is generally recommended in production environments), or the ifModule test fails.
|
1NXYoJ5xU91Jp83XfVMHwwTUyZFK64BoAD
|
|
|
joker_josue
Legendary
Offline
Activity: 2296
Merit: 6609
**In BTC since 2013**
|
 |
January 15, 2025, 08:37:36 PM |
|
Try changing these lines to: Header set Cache-Control "max-age=60, must-revalidate" Header set Expires "access plus 1 minute" Regarding theymos observation about Apache, try checking if the mod_headers module is available.
|
|
|
|
LoyceV
Legendary
Offline
Activity: 3948
Merit: 21198
Thick-Skinned Gang Leader and Golden Feather 2021
|
 |
January 16, 2025, 11:57:29 AM |
|
The headers in your .htaccess file should be sufficient, but the problem is that Apache isn't actually doing what you wrote there. In eg. Firefox, go to the Network tab of Developer Tools, visit your image, and look at the response headers; Cache-Control, Pragma, and Expires are not sent. ~ or the ifModule test fails Thanks, it looks like I missed needed this: a2enmod headers systemctl restart apache2 apachectl -M | headers Now my Response Headers look like this: Cache-Control max-age=0, no-cache, no-store, must-revalidate Expires Wed, 11 Jan 1984 05:00:00 GMT Pragma no-cache
|
¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
|
|
|
LoyceV
Legendary
Offline
Activity: 3948
Merit: 21198
Thick-Skinned Gang Leader and Golden Feather 2021
|
 |
February 23, 2025, 09:31:12 AM |
|
Is it possible to get the balance of an address 8 decimals in Bitcoin? I now get this:  All I want as output image is 0.00000001 BTC 
|
¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
|
|
|
bitmover (OP)
Legendary
Offline
Activity: 2940
Merit: 7282
Trêvoid █ No KYC-AML Crypto Swaps
|
 |
February 23, 2025, 12:14:14 PM |
|
Is it possible to get the balance of an address 8 decimals in Bitcoin? I now get this:  All I want as output image is 0.00000001 BTC  I think it is working now (I made a small change in code) But this address looks empty https://mempool.space/address/1MyMoney4uNt5afXALAZpoovJpqojEMkLPDo you know any address which has balance of 0.00000001 BTC so we can try?
|
|
|
|
LoyceV
Legendary
Offline
Activity: 3948
Merit: 21198
Thick-Skinned Gang Leader and Golden Feather 2021
|
 |
February 23, 2025, 02:43:47 PM |
|
I think it is working now (I made a small change in code) Now it doesn't show up anymore at all. But this address looks empty Correct. I meant all I want is the balance in 8 decimals.
|
¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
|
|
|
|