473,769 Members | 2,599 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

file rights are wrong after move_uploaded_f ile

Hello,

my problem is as follows,

I have a web page where user can upload pictures to unix server from
his own computer. Pictures are uploaded fine, but the rights of those
files are not correct for further processing. Php code page that
downloads pictures modifies this picturecatalog -page, that shows
those pictures. Hmm, I want it to show. Everything else is ok and
working but picture rights do not allow pictures to be viewed. I
manually gave proper rights and catalogpage was ok. Rights after
transfer are owner read, write.

Can i change file rights using php, is move_uploaded_f ile settings
wrong/missing? Manual rights modification is out of question, because
automation is whats this is all about.
Jul 17 '05 #1
1 2707
PeterFI wrote:

Can i change file rights using php, is move_uploaded_f ile settings
wrong/missing? Manual rights modification is out of question, because
automation is whats this is all about.


chmod()

Shawn
--
Shawn Wilson
sh***@glassgian t.com
http://www.glassgiant.com
Jul 17 '05 #2

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

Similar topics

4
6753
by: Tim218 | last post by:
Hi Everyone This is my first day with PHP and, not surprisingly, I've run into a problem :-) I want to allow file uploads to the server without exposing the non-technical end-users to FTP settings, file naming protocols, etc. I've found the following from http://www.zend.com/manual/features.file-upload.php ....
3
7096
by: Amy Kimber | last post by:
Hello, I have a file upload page, and I've had it working fine, it was beautiful :-) Anyway, the powers that be moved hosts... and it doesn't work now. The file name is correct, the directory where it's going on the server is correct (checked through prints etc.). I've changed the dir to 777 (is that right?) and this is what I get on the print_r($_FILES); line:
1
1953
by: Kareem Badr | last post by:
I was having permission problems, so I'm using a test file to make sure uploading works. upload.php successfully uploads a file to the images/bookcovers dir: <html> <form method="post" enctype="multipart/form-data" action="upload.php"> <input type="file" name="userfile"> <input type="submit" value="submit"> <input type="text" name="eh" value='meh&lt;'>
8
3491
by: mpar612 | last post by:
Hello, I am a newbie to PHP, MySQL. I am trying to create a basic file upload form. I want to get that working and then I want to integrate that into a form that will rename the file and save it to a directory and store the path to the file in the db, in addition to storing other text from other fields in the form. Then I will get that path using PHP to display the image file in a browser. First things first, I'm having difficulty...
4
10550
by: Tony B | last post by:
I've moved an existing site (which I didn't write) from a apache/php/mysql host under windows to a linux apache/php/mysql host. I've sorted out most problems except one. There is an upload function on the site, which uploads files via POST to temp folder and then moves it into a folder on the host using php function move_uploaded_file. Under windows this works fine but on the linux host the uploaded file is created with 600 permissions so...
1
1841
wadro21
by: wadro21 | last post by:
i am trying to write a php uploader for a site and keep getting this error: Warning: move_uploaded_file(uploads61877494_tp.jpg) : failed to open stream: Permission denied in /home/mysite/public_html/login/upload.php on line 5 Warning: move_uploaded_file() : Unable to move '/tmp/phpKlOJBh' to 'uploads61877494_tp.jpg' in /home/mysite/public_html/login/upload.php on line 5 I can run it fine on my local machine but when i upload it to the...
6
2712
by: Milan Krejci | last post by:
while(list($key,$value) = each($_FILES)) { if(!empty($value)){ $filename = $value; $add = "upimg/$filename"; echo $_FILES; $error=copy($_FILES, $add); if (!$error) $progressUploadingPhotos=false; $error=chmod($add,0777); if (!$error) $progressUploadingPhotos=false;
2
1441
by: ogo796 | last post by:
hi friends i am having a problem with creating folder within a directory. $Tdate = date('dFY'); // first directory. $_POST)) { mkdir($Tdir."/".$Tdate."/".$_POST); echo"the directory ".$Tdir."/".$Tdate."/".$_POST." has been created <br/>"; if(move_uploaded_file($_FILES,$destfile))
5
6814
by: kailashchandra | last post by:
I am trying to upload a file in php,but it gives me error msg please Help me? My Code is like below:- i have one php file named upload.php and i have another html file named upload.html and inside html i am calling php file upload.php:- <?php
0
9589
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
10212
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...
0
10047
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9863
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...
1
7410
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5304
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
5447
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3563
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2815
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.