so i am creating a website that would load images based on users
these images used to load just fine until last night
then it just happned one of them was loading and the other was not and now none of those images load i have deleted the old images and re uploaded new ones after they could not load any more but still no luck .
any help or advice would be appriciated
this is the website link : mcurse.rf.gd
a test user that i have created would be :
studentcode : ES01001
password : omed94
again thanks in advance and excuse my bad spelling
Edit : this could be due to the folder selection in my results page which has to come back a few folders up and go in a few diffretn folders to access the images ,
i cant find a way to find the root path so lets say for css connection instead of href = “css/index.css” i would do href = “root/path/to/folder/” also never as in mysite.com/path/to/folder since i redirect that to index to prevent access to the images without proper login information, thanks in advance
Edit #2:
so after clearing the .htaccess file and pasting the excact same code right back into it now it loads all the images in pc mode
but only 1 of them in mobile version i got a feeling it has to do with the .htaccess code but this is really confusing as after clearing saving and then pasting the old code back into it why would it reload the images this time
Edit #3:
I think this time inhave messed up.
So i just made a vital folder of my site into 000 CHMOD and niw i cant chamge it back nor do anything to it.
After searching the forums think only admins can help with that . Big off
Edit #4:
sorry to edit this alot i dont want to spam responses or spam new posts for each new issue i encounter regarding same website and generally trying to fix one issue in all of them
so infinityfree has directory privacy if i have lock those said directorys but when i try to access them thru mysite.com/path/to/passwrodprotectedfolder
i still can open them no problem and it does not ask for a user name password (created in protection proccess not the students code/pass) what am i missing here and should this be fixed will it be a fix for locking people out of that vital folder
edit #5:
yet another edit , this time i want to know if there is a way to do what iam looking for via htaccess deny all attempts to access a folder except from a php page. it seems this can be done with deny from all except certain ip, however when i try that for deny from all except local ip it does not work
Hi that is done intentionaly so peopel whom are not valid like another test user
ES02001
armand2000
So they cant access thier images untill they become valid
However this is not the cause iam sure of it since after that change it used to work fine
And agian today one of the images show but another 2 does not
Thanks for your replay any further help is appriciated
Hello and thank you for your information.
Thing is the images are searched and posted depending on the users login code.
So if the user is say ES01001 it will search the images section of the website and bring back any image containing ES01001 in its name and ending with jpg
However i believe the proccess between htnl and php turns this capitali Code into a small code es01001
While this does give me an idea but iam pretty sure this is not the cause since even before same website worked fine and rn iam visiting it in mobile and it works for one of the images but not the rest and all of the images use capital letters in thier names
Did not know how to edit the original post sorry i have to add this in reply section so as stated above now it loads 1 out of 3 images in mobile and 0 out of 3 in computer
I think it is due to your code or how your code will work, or how you setup your code. Cause when I try to open the three images by a new tab, it will redirect me again into the main page or login page. I’m using a mobile phone and the 3 images are not working.
Thanks in advance for trying to help.
This is intentional in .htaccess so i can stop users to access the folders directory and get access to all the photos .
I want images only load in result.inc.php
Which in my case now one out of 3 images load and the others dont on my mobile but on my computer none of which load i will try to undonthe last changes but this is an odd case to me as 8 havent touched any code related to the images and the issue came out of nowhere
The .htaccess rules you set are effectively blocking all image requests. If you could see the images before, that’s likely because they were cached on your own computer. I don’t see how these rules could ever allow anyone to view any image.
If you don’t want anyone to access the images directly, you could proxy the images through a PHP script. You can use a PHP script as the image source, and have the PHP script read the file from the folder and send it to the visitor. This is the only truly secure way to only allow specific people to see specific images.
However, please note that doing this does increase CPU and Entry Process usage for your account, which may cause your account to hit the daily resource limits quite quickly. So please use this sparingly.
Thanks in advance admin
Beleive it or not after clearing cache on diffrent browser and messing with .htaccess file i found out what you stated above and loged on to edit my og post.
I have also read adding an index.html or index.php works semilar so people cant access the directory and i just could add a header redirecting people who try to access to that folder back ot login page. However since the images are based on student codes and every student knows the code of themself everyone can access thier images by passing login and valid filters.
I will look into your solution and try it but as you said the daily limit will be an issue since iam using this for student cards and for about a week every year this site will be loaded with visiters and this will be an issue. If i may ask what is the daily limit is it per visitor or per proccessing unit
If i my ask again iam having a bad time understanding the sulotion you offerd and am at early days of my php programing can you please give an short example or send me to a topic regarding that solution
Thanks