hello friends,
i want to know if "file_exists" function works on server or not??? i am giving image link path and checking it thru file_exists.but it is alwaz going on else part .is there any substitute of this function which works fine on server??
about file_exists
Moderator: General Moderators
- Kieran Huggins
- DevNet Master
- Posts: 3635
- Joined: Wed Dec 06, 2006 4:14 pm
- Location: Toronto, Canada
- Contact:
Re: about file_exists
Dollars to doughnuts it's a path issue. Try prepending $_SERVER['DOCUMENT_ROOT'] to the front of your path.
Re: about file_exists
Also check to make sure you have read access to that file. Try doing "is_readable('/path/to/your/image/')" to see if you have access to the directory that the image is under.