473,800 Members | 2,722 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Guide for this error..

Hi guice,
I have designed a php search page..When I entered the search term

it shows me the follwing error..

Warning: fopen(files/admin.jpg) [function.fopen]: failed to open
stream: Permission denied in C:\Inetpub\vhos ts\iswaryammatr imony.com
\httpdocs\searc h result.php on line 206
file error
Somebody told me that the file must be allowed to read by server
administrator..
Pls Guide me..Thanks in advance..

Imai from Sky
www.adobians.com

Nov 12 '07 #1
4 1240
sk*****@gmail.c om wrote:
Hi guice,
I have designed a php search page..When I entered the search term

it shows me the follwing error..

Warning: fopen(files/admin.jpg) [function.fopen]: failed to open
stream: Permission denied in C:\Inetpub\vhos ts\iswaryammatr imony.com
\httpdocs\searc h result.php on line 206
file error
Somebody told me that the file must be allowed to read by server
administrator..
That was good advice.
PHP cannot open a file because the user that runs PHP doesn't have the
right permissions on that file.

Solution?
1) Find out who runs as PHP
- probably IUSR_<machinena meon IIS/Windows.
- probably nobody, or apache, or www-data on Apache/*nix

2) Give read and/or write permission for this user on the file in question.

Regards,
Erwin Moller
Pls Guide me..Thanks in advance..

Imai from Sky
www.adobians.com
Nov 12 '07 #2

<sk*****@gmail. comwrote in message
news:11******** **************@ t8g2000prg.goog legroups.com...
Hi guice,
I have designed a php search page..When I entered the search term

it shows me the follwing error..

Warning: fopen(files/admin.jpg) [function.fopen]: failed to open
stream: Permission denied in C:\Inetpub\vhos ts\iswaryammatr imony.com
\httpdocs\searc h result.php on line 206
file error
Somebody told me that the file must be allowed to read by server
administrator..
Pls Guide me..Thanks in advance..
the error is clear. you need to set permissions on your
vhosts\iswaryam matrimony.com\h ttpdocs\ directory such that apache has at
least read permissions. i assume you're running apache here. if iis, you
need to set that directory up as a virtual web server. google how to do
either.

on another note, you need to watch your nomanclature. though php will handle
backslashed paths, it is easier to write them without error using forward
slashes...i.e. c:/inetput/vhosts/

also, more problems will arise for not only you, but your end users if you
place spaces in your script names, i.e. 'search result.php'. bad, bad, bad
idea. i won't get into that much more here other than to state it as such -
a bad idea.
Nov 12 '07 #3
Sir,

I m using Apache web server..with plesk control panell.. I have
checked the preference..all are checked to read and also write too.
Thanks ...

Nov 12 '07 #4

<sk*****@gmail. comwrote in message
news:11******** **************@ z24g2000prh.goo glegroups.com.. .
Sir,

I m using Apache web server..with plesk control panell.. I have
checked the preference..all are checked to read and also write too.
Thanks ...

it's NOTHING to do with plesk or anything else. you have to tell your
*operating system* that it is ok for *apache* to access the directory.
Nov 12 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

21
4033
by: Christian Seberino | last post by:
Linux kernel style guide, Guido's C style guide and (I believe) old K&R style recommends 8 SPACES for indent. I finally got convinced of wisdom of 8 space indentation. Guido also likes 8 space indentation FOR C CODE. Why style guide (PEP-8) for Python says 4 space indents??? Is breaking rule to use 8 space indents everywhere
4
1654
by: Louise Woodward | last post by:
I am looking for some beginner guide for someone to learn asp - tutorials, examples etc Thanks -- Louise Woodward Opal Telecom Application Team Irlam
2
1548
by: Foobarius Frobinium | last post by:
http://thelinuxlink.net/~fingolfin/pointer-guide/ I've made a lot of corrections, and put in more new stuff. I have malloc and pointers to struct's and maybe a few more things and I'm done. Examine it and tell me what you think.
48
2405
by: Foobarius Frobinium | last post by:
http://thelinuxlink.net/~fingolfin/pointer-guide Tell me what you think...
0
1175
by: Kapil Shah | last post by:
Hi Guys, I have created a console multithreaded client server application where many client connects to the server.I am adding the clientID and Socket to the hash table. I have added a timer to the server which fires every 30 seconds and asks the client whether the client is connected… However when I connect two clients say (kshah,sck1) (mkshah,sck2) and then close the connection for kshah and then remove kshah with sck1
2
5073
by: phoover.eml | last post by:
Does anyone know how to get a copy of the "Annotated Solution Guide" for Bruce Eckel's "Thinking in C++" ebook? I have tried to order it from the mindview.net web page. However, I get an error messge from their authorization server saying: The following errors have occurred. (97) This transaction cannot be accepted. Thanks!
2
1553
by: Fishmonger | last post by:
Hi Guys, I'm looking for a good C++ compiler that will work well with The Complete Idiot's Guide to C++.I've tried DEV and Microsoft Visual C++ express.They all come up with "iostream "error.If you can give me a link I will be happy . Thanks Errol
3
2508
by: phanimadhav | last post by:
Hi, i am working on the coding part which is based on jsp/html.As im fresher i am facing some problems with the code.so,can u please guide me..This is the error which i ve got...please have a look.... org.apache.jasper.JasperException: /jsp/DeleteUserDetail.jsp(103,0) The end tag "&lt;/html:html" is unbalanced code follows.. <%@ taglib uri="/WEB-INF/struts-html" prefix="html" %> <%@ taglib uri="/WEB-INF/struts-logic" prefix="logic"...
3
3054
by: madankarmukta | last post by:
Hi All, I am facing one problem while implementing the connectivity with the sybase server. When I am trying to open the AseConnection object the error popped up is "Client unable to establish a connection". I tried to ping the Data source x.x.x.x and found that it is active. Am I missing something ? Please help. Thanks!
0
9691
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10507
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10255
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10036
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9092
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5473
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5607
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4150
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3765
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.