RE: [PHP] Editing Word Documents
Hmm, I don't know about intercepting the "Save As..." option from word to trigger a PHP URL, but you could direct people to save their edited word files to a specific directory on a network share on a PHP-enabled server (easy enough on a Windows network, and not too much harder with Samba on Linux)... then you could run a PHP script as a cron job to check for modified files in that directory every five or ten minutes, and have the script upload them as needed. It's not instantaneous, and there would definitely be some logistics to work out (what if two people are editing the same file at the same time, how do you account for that 5-10 minute lag, etc.) but it might be better than nothing. -Andy > -Original Message- > From: Chris Hewitt [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, July 09, 2002 3:47 AM > To: Kevin Stone > Cc: David Russell; php-general > Subject: Re: [PHP] Editing Word Documents > > > I think what the OP meant (certainly what I meant), is that the Word doc > is accessed from a normal link. Clients use windows and the browser has > the .doc mime type set and spawns Word. The user edits it. I had > (vainly) hoped for a way of setting the "File..Save As" to trigger PHP's > File Upload facility. > > Has anyone had this need, found a way around it or found it not possible? > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Editing Word Documents
I think what the OP meant (certainly what I meant), is that the Word doc is accessed from a normal link. Clients use windows and the browser has the .doc mime type set and spawns Word. The user edits it. I had (vainly) hoped for a way of setting the "File..Save As" to trigger PHP's File Upload facility. Has anyone had this need, found a way around it or found it not possible? Thanks for the WebDAV pointer. I shall certainly be looking into that but I had hoped for a simpler way compatible with existing windows versions. Longer term it looks the right way to go. Thanks Chris Kevin Stone wrote: >Of course you can open and edit any file in PHP you just need to know the >file format. But I highly doubt there is any method using PHP that will >allow you to prompt the opening of a file into an external application. >Editing of the file would have to be done in memory, or manually in the >browser (HTML form, textarea field). Unfortunately Microsoft is notoriously >protective of its file formats. >-Kevin > >- Original Message - >From: "Chris Hewitt" <[EMAIL PROTECTED]> >To: "David Russell" <[EMAIL PROTECTED]> >Cc: "php-general" <[EMAIL PROTECTED]> >Sent: Monday, July 08, 2002 11:51 AM >Subject: Re: [PHP] Editing Word Documents > > >>David Russell wrote: >> >>>snip-- >>>5. The client then closes the file, it "auto-saves" and he goes about >>>his business. >>> >>By coincidence, I'd be very interested in this too, particularly from a >>linux server. >> >>Regards >> >>Chris >> >> >>-- >>PHP General Mailing List (http://www.php.net/) >>To unsubscribe, visit: http://www.php.net/unsub.php >> > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Editing Word Documents
On Mon, 8 Jul 2002, David Russell wrote: > I have just had a request about editing Word Documents... > > I have an intranet, which provides access to, amongst others, Word > Documents about policies, etc. What the guys are looking for is a way to > do the following: > > 1. Show a list of files available for editing > 2. If a file is clicked, then it is locked for other users (no access) > 3. The file opens on the client's machine > 4. The client edits it > 5. The client then closes the file, it "auto-saves" and he goes about > his business. > > Points 1 through 3 are relatively trivial. Point 4 and 5 (especially 5) > have me lost. > > How do you get a file to be edited, and then automatically returned to > the server by M$ Word in it's changed format. Is this possible? > > How would this change in a database-backended system (including the > files as BLOBs)? Assuming you're using Apache, you can use mod_dav (http://www.webdav.org/) to provide read/write access to files for clients with newer operating systems (WinXP, OSX, maybe a few earlier versions) over HTTP. Combine this with a simple locking mechanism in your database (i.e., update file set locked='1' and lockedat=now() and lockedby=$user where file_id=$file) and you're good to go. miguel -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Editing Word Documents
It sounds like a job for WebDAV to me... -Josh -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Editing Word Documents
Of course you can open and edit any file in PHP you just need to know the file format. But I highly doubt there is any method using PHP that will allow you to prompt the opening of a file into an external application. Editing of the file would have to be done in memory, or manually in the browser (HTML form, textarea field). Unfortunately Microsoft is notoriously protective of its file formats. -Kevin - Original Message - From: "Chris Hewitt" <[EMAIL PROTECTED]> To: "David Russell" <[EMAIL PROTECTED]> Cc: "php-general" <[EMAIL PROTECTED]> Sent: Monday, July 08, 2002 11:51 AM Subject: Re: [PHP] Editing Word Documents > David Russell wrote: > > > snip-- > > 5. The client then closes the file, it "auto-saves" and he goes about > > his business. > > By coincidence, I'd be very interested in this too, particularly from a > linux server. > > Regards > > Chris > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Editing Word Documents
David Russell wrote: > snip-- > 5. The client then closes the file, it "auto-saves" and he goes about > his business. By coincidence, I'd be very interested in this too, particularly from a linux server. Regards Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Editing Word Documents
Hi all I have just had a request about editing Word Documents... I have an intranet, which provides access to, amongst others, Word Documents about policies, etc. What the guys are looking for is a way to do the following: 1. Show a list of files available for editing 2. If a file is clicked, then it is locked for other users (no access) 3. The file opens on the client's machine 4. The client edits it 5. The client then closes the file, it "auto-saves" and he goes about his business. Points 1 through 3 are relatively trivial. Point 4 and 5 (especially 5) have me lost. How do you get a file to be edited, and then automatically returned to the server by M$ Word in it's changed format. Is this possible? How would this change in a database-backended system (including the files as BLOBs)? Thanks David R -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php