Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    PHP


SuperbHosting.net have generously sponsored dedicated servers to ensure a reliable and scalable dedicated hosting solution for BigResource.com.





Access/read Log Files That Are On Different Servers


I am trying to access/read log files that are on different servers (not web servers) to my scripts but don't seem to be able to access them. I get the following error:

Warning: file("IP_Addressdredrent.log") - No such file or directory in c:inetpubwwwrootAutoreportslog_processingcheck_dre_query_log.php on line 15

I am using Windows 2000 and IIS. Code:




View Complete Forum Thread with Replies

Related Forum Messages:
Read/write Access To All The Files
I recently made a php app for a company that spiders through a server and finds all files of a specified type (html, etc) and then opens the files and does specified things to them. So, the tool needs to be placed on the server and then it needs read/write access to all the files.

It works fine on my local server, but the client says that it fails (message is "failed to write to file" and then it stops). I told him to try it with ALL files and folders set to 777 just for testing purposes and he says that it's still not working. I have no idea what to suggest.

View Replies !
Email With Attachment - Annot Be Accessed. The File May Be Read-only, Or You May Be Trying To Access A Read-only Location.
It is a basic email with an attachment. The email and attachment are getting sent and received ok. When the recipient tries to open the attachment, the right application opens (eg. Excel) but then throws up an error. I am using base64 encoding. For example:

.xls file with base64 encoding:
'testing.xls' cannot be accessed. The file may be read-only, or you may be trying to access a read-only location. Or, the server the document is stored on may not be responding.

.pdf file with base64 encoding:
There was an error opening this document. The file is damaged and could not be repaired.
so the file isn't being decoded right. I have tested on Yahoo and Outlook. PHP Code:

View Replies !
MS Access + ODBC Links On Remote Servers
Has anyone ever figured out why an ODBC link, via PHP, will only connect properly if the DSN and .mdb files live on the same box as the web server? For some reason, the ODBC functions seem to ignore mapped network drives and even UNC path names. Anyone know of a PEAR module or third party class that will do the job?

View Replies !
Moving Files Accross Servers
I've got this bit of code to upload an image to a server Code:

View Replies !
How Can I Copy Two Files Between Two Remote Servers?
I have a file one file on:

www.host1.com/file1.txt

i want to copy it to

www.host2.com/file1.txt

how can i do this?

View Replies !
Downloading/Uploading Files To/From Remote FTP Servers
I have access to two FTP accounts. One has some files on it that I want to move to the other FTP account. I want to set this up to run as a cron job every day.

I'm able to login using the ftp_login function but I don't know how to actually have the script move the file from one server to the other without having to download the file to my desktop before I can upload it.

View Replies !
Implode - Read The Contents Of A File (servers) And Create A New File
I am trying to read the contents of a file (servers) and create a new file off of it with more information line by line. You will see the logic soon. I know how to do this via a script but not php.

The end result is servers2 should have (ssh root@$count 'echo $user|passwd --stdin root' ; done). The variable $count is the list of servers in the (servers) file, so it will have the line above for each server name. Code:

View Replies !
Read Entries From DNS Servers And Ping The Entries
i need to build a script that will let the website i'm currently building to read entries from DNS servers and ping the entries to see if they're alive. the problem is i have no idea how to 'read the DNS entries'.

View Replies !
I Am Trying To Read Access Log File
My access log file is has more then 8 lakhs lines. I am trying to read the log file and populate the data in database. But due to long file I am not able to read the file after certain time. It is showing an error: Code:

View Replies !
Read & Full Access
We have a login page that we have people login to access information. We want to be able to deny access to a certain link depending on what password they enter.

the login informatin is pulled from the DEALER_NUM and PASSWORD field in the table. I have created a field called PASSWORD2 which is what we will be using for the special access if thats what you want to call it. Code:

View Replies !
Restricting File Read Access To Users But Not Server
I`d like to know if it is possible to place a products.dat file on my website, yet restrict users so that they cannot see or d/l the file, but they can access it through a php file which is run by the web server which has the only access to the products file when browsing.

Does this make sense?, its basically client server, but since my php knowledge isnt great yet, Im not sure if this is easy or not?

View Replies !
Read Data From MS Access Into MySQL In Real-time
I am currently working on a project that involves reading information from a inventory system into Access via ODBC and display the info on the web site using MySQL.

I would like to create a live link between the MS Access(local) and MySQL (remote) whenever the inventory system is updated MySQL will be updated as well.

I know that MyODBC will let me do the opposite of what I would like to accomplish by reading data in MySQL into Access. Is it possible to do the reverse way.

View Replies !
How To Read Tar.gz Files From Php
I need to deflate a tar.gz file, using php, and i have no shell access,
please, im using php 4.3.11 on a iis 5.0 (i know, i sucks).

View Replies !
Read All Files
I am trying to chmod all my images in one dir. but I cannot get it to work...How do I code the first part so it reads all my files I have in the dir? I want to change all my images cmod settings by running the script once.

$file = all my files in my images folder or this directory

$old = umask(0);
chmod("$file", 0644);
umask($old);

// Checking
if ($old != umask()) {
die('An error occured while changing back the umask');
}

View Replies !
How To Read Pdf Files?
I have a batch of pdf files need to be convert to html. Is there good script or library can do that? I made some research, most of them only do another way (convert html to pdf)

View Replies !
How Can I Read .doc Files
Here is a small doubt with which iam struggling,The problem is
how can i read .doc files and display content in browser in php.ok i
have done it with file() and file _get_contents() but iam getting
content with some meta characters like boxes etc. please solve this
problem and reply me immediately it i surgent.

View Replies !
Read Log Files
I have a client doing some minor PHP development on my server, and they've asked for access to the apache error log to debug. I don't want to give them shell access, so I thought AJAX/PHP might be able to read and refresh the last 50 lines or so of the log file for them to view on the web.

View Replies !
How Can I Read Text From PDF Files?
Can you someone tell me how can I read text from PDF files?

View Replies !
Can Php Read .xls Files Directly?
I'd like to be able to read a microsoft spreadsheet with php. I know that php can read mysql, so I was thinking that maybe it could read excel spreadsheets as well.

Does anyone know if that can be done?

View Replies !
Read Multiple Files
I have a PHP script where I read parts of xml feeds from multiple web addresses and display data. Something like :

for(){
$filedata = @file(url);
parse xml -> display data
}

My problem : can I read more files at once (multithreading?) - because it seems to work very slow now.

View Replies !
Using PHP To Read XL Spreadsheet Files?
Is there a simple way to read the content of uploaded Microsoft XL
spreadsheet files?

View Replies !
Read Dirs And Files
I have this code which reads all the folders and files within the path. Code:

$path = getcwd();
read_dir($path);
}

function read_dir($dir) {
$path = opendir($dir);
while (($element = readdir($path)) !== false) {
if($element != "." && $element != "..") {

if(is_dir($dir."/".$element)) {
$dirs[]=$dir."/".$element; // put all folders in CWD into an array
$folders[] = $element;
}
if(is_file($dir."/".$element)) {
$files[]=$element; // put all files in CWD into an array
}
when reading the files.

View Replies !
Read All Files From A Directory?
how to read all files from a directory and put them in a table?

View Replies !
Script To Read Files
i am trying to place a file in a user secure area, so when they go to 'My Account' i can place system message, files etc that only that user will see.

i have a table idx_link_user and in that table a field called 'files'. how would i go about retrieving the data from database to present to logged in user?

View Replies !
Read And Extract From CSV Files
I have just given an interview in php and their is my test on php tomorrow. He told me that i will give you 1 csv file and i have to write a php code /find code from internet which. Reads the csv file and its contents, Exract the information from csv and insert into database, generate the Report: i know php but i don't know how to read csv files with tables and data.

View Replies !
Read Files From Visitor
I've tried, PHP Code:

$fp = fopen('C:ProgrammesyscOnetstat.txt', 'r');

but of course this only reads out the netstat.txt on my server, not from the client. PHP Code:

$fp = fopen('file:////c://Programme//syscOn//netstat.txt', 'r');

didn't worked as well. I just thought it must be possible, because some "1337-pages" can even read out your harddisk-content to an iframe.

View Replies !
How To Read Files From Directoiries/sub Directories
I am new to PHP and doing a project. I want to read all files from all directories/sub directories starting from the root of the web site. ie. I want to get the root directory programmatically. I am using linux. The purpose of the file reading is to do an internal searching. Could u give me a sample code.

View Replies !
Arrays And Sorting, Read From Files
this is an ecommerce website. the categories are static, but the products are not. what happens is a user clicks on a link, subgroups.php?a=miscellaneous. subgroups either has a=, p=, l=, c= or s= but not more than one.

so, in a folder called 'dat' there are 5 text files: a, p, l, c, s. these contain the products for each category. what i want is a list of products to be read from the correct file and displayed in a tabled list. the files are layed out like this:

miscellaneous|Sticky Tape|MS394
miscellaneous|Scissors|MS012

so, subgroups.php?a=miscellaneous will read a.txt and look for all rows starting with miscellaneous and display them in a table. along with a thumbnail (img/thumbs/MS394.gif or img/thumbs/MS012.gif) and a link to product information (dat/a/miscellaneous/ms394.txt) which will be included on the next page. How can i do this?

View Replies !
PHP Scripts To Parse/read OE Dbx Files ?
Does anyone know whethere a PHP class or script exists to read messages in
outlook express mail databases ? I can't get OE to auto-save certain
messages to regular files, and doing a manual SaveAs four times a day
becomes a bit of a bore.

Or should I intercept these messages directly from my pop3 mail server.

View Replies !
Can I At Least Read The Session Files For All Sessions?
Right now, I am attempting to see how many users are "signed on" to my system. Since this is, at best, rather tenuous in a WEB environment, I thought to read the active session variables and see how many sessions there were.

View Replies !
How Do You Read And Write UTF-8-encoded XML Files In PHP?
I have a very simple XML file I created as a sample:

<?xml version="1.0" encoding="UTF-8" ?>
<stuff>.....

View Replies !
Can I Use Php To Read From/write To Other Files On Server
I've got a news section on my page and I want people in the company to be able to fill out an online form to add new news stories so that the website looks constantly updated. all the news stories and scrolling abilities are currently in a javascript file which are written out to the page when a user loads the page. So preferably I'm looking to take in information from a form and write that information into my javascript file if that's possible. r if I can't do the above I want to take in information from my form and write to a database or new file then read that from my javascript file with php.

View Replies !
Is It Possible To Read From The Dir According To The Cration Time Of Files
is it possible to read from the dir according to the cration time of files.

View Replies !
Read/write To Excel Or Same Type Of Files.
We need to be able to process invoices through the internet and have the customers be able to download these invoices. We are currently using Excel to do all the information.

I was hoping to be able to use a third party program to generate these files, I have looked into .pdf, and xls files. From what I have read, it is pretty much impossible for me to get a script that will read an xls file, write data from a mysql database to it, then send the file to the customer for them to download/view with the new information.

Is there a different program that works the same that I might be able to use.. or am I stuck trying to make alot of invoicing data look pretty through html tables?

View Replies !
Ereg, Read The Dir And Print List Of Files.
I have a dir of html files that link to websites, i would like to read the dir
and print a list of those files as a link. Which the script i have does. I
would like to take this one step further and replace the ".html" extension
with ".com" so it winds up being:

View Replies !
Security Read Write Files And Folders
when i upload files to my webspace i set permission to my files and folders. Im wondering how im unsafe if i grand a folder or file with write permissions to all/everybody. In fact I have the intelligence to understand that ones can places files to my webspace and then execute them. But I dont have the knowledge how to implement it.

How can i write to that folder and files?

View Replies !
Search :: Read Files And Just Pick Out Certain Words
I wanted to know if there is a way with PHP to read files and just pick out certain words. For example, I have an essay paper and I want to see if with php I can find out how many times I said the word "for".

View Replies !
Read A Directory Files, And Create Echo HTML?
i have a foo/ directory and a foobar/ directory, and a barfoo/ directory in root/

for each directory in root, i'll put x or y or z amount of images in each directory. then, have the php write 01.html with the correct links to a) main image, b) thumb images and prev/fwd links.

we could have separate php files to handle the drawing of the new sequenced .html files in each directory (probably best to pass variables), because they're slightly different, or one to rule them all (sounds like too much work).

then, the syntax would need to be sorted out (so index.html has a link to foo/foo.php?=foo01) would work correctly and draw up 01.html with the correct images, being that index.html would probably have to have hardcoded variable-passing links. eh?

it's sweet, 'cause updating would be fast. upload and delete image files. done. I mean, I know that you could go the database/XML route, but sigh ........

View Replies !
How Can I Display The Result Of The Array Of Files I Have Read From A Directory.
how can I display the result of the array of files I have read from a directory. I know How to read from a directory but I am wondering how to diplay the result in a table with, let's say, rows of 5 images. What would happen if I don't have enough of file to make a row ?

View Replies !
Setup My Htaccess File To Read My Html Files As Php.
I am trying to setup my htaccess file to read my html files as php. How would I do this, or where can I find how to do it?

View Replies !
Read Contents Of Directory - If Not Text Files Exit
I have to make a page that shows the contents of a directory BUT if there are no text files in the folder I am supposed to kill the script. Code I tried (for that specific part of the script) was: Code:

$directory = dir("./courses/");
if(!(isset($directory[2]))){
die("No files in directory");
}

To my knowledge $directory[0] would be taken up by "." and [1] would have ".." so I thought if [2] isn't set then there isnt an actual file in the directory. I am sure there must be a better way of doing this however as [2] could easily be taken up by a folder or image and still come out true that there is a txt file.

View Replies !
Access To Mp3 Files Below Web Root
I want to place some mp3 files below the web root directory to keep people from accessing these files. however i want certain php scripts to be able to use them (ie for a flash movie that plays mp3 files)whats the best way to accomplish this?

View Replies !
MS Access Files With Php - Impossible?
I'm running Apache/MySQL/PHP and recently my boss wanted me to create some pages that interface with the database files from another part of the company, and they're all Microsoft Access .mdb files sitting on a network drive.  It easy to use ODBC to get at one file, but I need the ability to arbitrarily access files . ODBC is NOT an option, because  there are at least 120 different .mdb files in system.  Also, changing from Access to MySQL for them is not an option- our software there doesn't support it.

Advice?  Is this even POSSIBLE with php?  Is there a server-side language that I could pick up that would be much better for this?  (Preferably one that wouldn't cause me to have to dump Apache).

View Replies !
Access Network Files?
I'm making a script to read a certian file in 10 different machines. The problem is: If a machine is down, or inaccessible, then PHP will continue to "try to access" that file until a timeout occurs.

Is there a way to "ping" a machine to see if it exists, without having to wait for a timout? Currently, I'm using the following code:

View Replies !
Limit Access To Some Files
I'm in need of a script that would limit the access to a high-bandwidth file. I am on a shared server, and this file will generate enough traffic to crash it, and I don't want this. So I need a script to allow a certain amount of users to access this file at a time. I would also need to know how to use this script, since my knowledge of php, is. shall I say, non-existent.

View Replies !
Random-access Files
I am looking for a way to random-access text files from a PHP-based script. I don't think PHP itself has any functions that can do this. But are there any other solutions, e.g. using Python, Perl, etc. and somehow interact with PHP? Or some other way? By the way, are there any fundamental reasons why PHP should not be able to do this or is it just that no one still has developed the necessary PHP library/extension?

View Replies !
How To Access OCX Files In Javascript?
I have a ocx file in each system of my intranet, what i need is i want to access the informations in the ocx file. Is this possible in javascript, If yes reply me how we can access the local OCX files...

View Replies !
Passing Variable - Make Read A Two Files, And Create A New File
I have a small script with a form, and if the form is submited (goes back to the same script) that it will make read a two files, and create a new file, and move it to a different directory. Everything works except, I'm trying to change one part. When I insert

$header3 = "<?php $title = $header ?>";

Then I add that to another variable
$data = "$header3
$top
$header2
$info2
$bot
";

Then I write that to the file via:
if (!$file_handle = fopen($filename,"w+")) { echo "Cannot open file"; }
if (!fwrite($file_handle, $data)) { echo "Cannot write to file"; }
echo "Successfully written data to $filename!<br>";
...................

View Replies !
Restrict Access To Folders/files
On a website, I will have several PDFs that I need to make available if user gives correct password or is in a given IP range. My first thought was to use .htaccess, but the host doesn't support that. they do support .htconfig and I didnt find any way of using that to resolve my needs.

If there any walk around in this situation using PHP and MySQL?

View Replies !
Unable To Access PHP Files On Server
I'm running a Windows 2003/IIS6 server and have just installed the most recent PHP4. For some reason, I'm able to access any files on the server EXCEPT .php files! When I try to access a .php file it's returning a 404 not found error.

View Replies !
Giving Access To Files Outside The Web Root
I was wondering if anyone could help me with making a link to a file outside a web root. For example, I have a huge video file that I recorded of surfing on my external hard drive that will not fit under my htdocs root folder.

As a result, how would I make a link to my J: drive (which is outside my web root) so people could download this video? Would I need a php script?

Also, because this file is big, I also want to make sure it doesn't create a temp folder while the file is transfering. One more thing, how would i protect against directory traversal?

View Replies !

Copyright © 2005-08 www.BigResource.com, All rights reserved