Hi,
I am building a website in PHP & mySQL. It has frontend and backend capabilities. Only admin can enter the backend by means of username and password. Now if the admin wants to add other sub-admins to the website, he could do so. By this method, a sub-admin will be able to login and perform all actions that the original admin is able ...
I am working in php on ubuntu. When I use any image on web page which has denied access, there is warning on page. I want to check it before displaying and if it does not have rights to open then give it access to open. As we do in terminal command.
chmod 777 myimage.jpg
How to check this and give full access to a file in php.
Thanks...
I have an application that is looking through some files for old data. In order to make sure we don't corrupt good projects, I'm copying the files to a temporary location. Some of the directories I'm checking are source-code directories, and they have .svn folders. We use Subversion to manage our code.
Once I've searched through all of ...
Python is creating a folder in my directory every time I call this method. The method is in one of my Django applications that requires access to the server's local area.
def filepath(filename, foldername='', envar='MYAPPDIR'):
if envar is not None and envar is os.environ:
dirpath = os.environ[envar]
else:
dirp...
I'm writing a C#.NET program which uses XmlSerializer to serialize and deserialize the project the current user is working on to and from an XML file. This is working fine, but I'm trying to figure out a way to prevent two users from opening the same file off a network drive and having one user overwrite the previous user's save. I essen...
I need to intercept when the system tries to access to a file, and do something before it happens.
...
How to control access to a file in hard drive so that it can be read once only. After the first access, the file should be rendered inaccessible.
...
Answer : Implemented using Curl...
$file = "http://abc.com/data//output.txt";
$ch = curl_init($file);
$fp = @fopen("out.txt", "w");
curl_setopt($ch, CURLOPT_FILE, $fp);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_exec($ch);
curl_close($ch);
fclose($fp);
$file = "out.txt";
$fp = fopen($file, "r");
I am trying to parse data from a pipe-de...
I'm working on a site that allows users to purchase digital content and have implemented a method that attempts to serve secure downloads.
I'm using CodeIgniter to force downloads like this:
$file = file_get_contents($path);
force_download("my_file_name.zip", $file);
Of course, I make sure the user has access to the file using a dat...
Hi all,
I need to download an image from some URL to my server. However, my server's config disallowed me to do it this way:
getimagesize( $file );
Because, it generate error:
Warning: getimagesize() [function.getimagesize]: URL file-access is disabled in the server configuration in somefile.php on line 10
So, is there another wa...
I'm writing a portal in PHP that allows users to upload DICOM images, and allow users of the same group to view those DICOM images through a Java Applet. The html code to display images through the viewer looks like this:
<APPLET archive=radscaper.jar codebase=./ code=com.divinev.radscaper.Main.class width=100% height=100%>
<PARAM NAME=...
Hello,
I have an application that allows multiple users to access 1 xml file. The problem is that when all the users save at once the other changes by other users does not get saved. How do I detect if the file is in user in groovy?
Thanks!
...
By default you cannot access a file that is uploaded until it has been fully transferred to the server.
What is the best way to get round this and be able to access the 'byte stream' as the file upload is in progress?
...
What entries in a web.config could allow certain files to become publicly accessible after a certain date and time? Specifically, we have these files starting with AB_.jpg where the _ could be anything. We put them in a folder on April 27th for example, but they shouldn't be accessible until April 30th at 11:59:59 PM.
I think the web....
Hi everyone!
I need in a iPhone app to access files that the app is build with(.plist etc). There's an hardcoded way to do this:
NSString *appDir = [[[NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES)
objectAtIndex:0]
stringByDeletingLastPathComponent]
...
I am using wamp on Win XP SP3 and creating a Joomla template with changeable parameters.
initially the message is
The parameter file \templates\ssc_2010\params.ini is
writable!
once I make changes everything works as expected, except now i get the message:
The parameter file \templates\ssc_2010\params.ini is
unwritable!
...
I'm trying to write a simple program that will backup my flash drive. I want it to work automatically and silently in the background, and I also want it to be as quick as possible. The thing is, resetting all the access times is useless to me, and something I want to avoid. I know I can read the access times and set them back, but I bet ...
Lets say I have some pdf files stored on my server and I only want to allow a person who's paid have access to download a particular pdf.
So for an example, let's say I have a bunch of e-books. The only way a user would be able to download e-book A is if his account contains the right credentials for that particular book.
What's the b...
Hi folks,
imagine i wish to create (or overwrite) the following file :- C:\Temp\Bar\Foo\Test.txt
Using the File.Create(..) method, this can do it.
BUT, if i don't have either one of the following folders (from that example path, above)
Temp
Bar
Foo
then i get an DirectoryNotFoundException thrown.
So .. given a path, how can we re...
First of all, here's the full source code:
http://pastebin.com/5teGNrPC
I'm getting a weird COBOL Error, and I couldn't find what it means.
It says Open Error (see the following screenshot:
)
(full size at http://img251.imageshack.us/img251/623/screenshotyj.png )
It doesn't occur if I first use "new file", and add a record after that...