php parser

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Selmi Mourad

    #1

    php parser

    Hello,
    I like to know wheter it is possible with php to do the following
    taskes:
    - read a file (.txt, .doc, .pdf, ...) word by word to chek if a word
    or a sentencs exists...
    - chek the form of presentation of a word i.e. chek if the word is
    bold, in which size, is it centered or aligned to left,...
    thank you for your help
  • Colin McKinnon

    #2
    Re: php parser

    Selmi Mourad wrote:
    [color=blue]
    > Hello,
    > I like to know wheter it is possible with php to do the following
    > taskes:
    > - read a file (.txt, .doc, .pdf, ...) word by word to chek if a word
    > or a sentencs exists...
    > - chek the form of presentation of a word i.e. chek if the word is
    > bold, in which size, is it centered or aligned to left,...
    > thank you for your help[/color]

    .....yes, strictly speaking it's *possible*. But unless you have COM wrappers
    for these files which provide this kind of functionality, then you really
    don't want to try implementing yourself in PHP.

    C.

    Comment

    • Erwin Moller

      #3
      Re: php parser

      Selmi Mourad wrote:
      [color=blue]
      > Hello,
      > I like to know wheter it is possible with php to do the following
      > taskes:
      > - read a file (.txt, .doc, .pdf, ...) word by word to chek if a word
      > or a sentencs exists...
      > - chek the form of presentation of a word i.e. chek if the word is
      > bold, in which size, is it centered or aligned to left,...
      > thank you for your help[/color]

      Hi,

      You can probably easily search a plaintextfile, coding it yourself.
      But if you enter the (evil) domain of propietary software, like doc, you
      need some code (in a com or something) to help you access the file.
      Or a friendly guy who backengeneered the stuff.

      Have a look a .doc in a plaintext editor and see how that looks...

      And then there is a newer Word-version.
      Things start over again.

      Anyway, I'll stop ranting.

      Have a look here:


      You will find some pdf-api at least.

      Be sure to read the notes too.
      They contain a few examples on M$-based systems with COM.

      Good luck

      Regards,
      Erwin Moller


      Comment

      • Malcolm Dew-Jones

        #4
        Re: php parser

        Selmi Mourad (selmi.mourad@l aposte.net) wrote:
        : Hello,
        : I like to know wheter it is possible with php to do the following
        : taskes:
        : - read a file (.txt, .doc, .pdf, ...) word by word to chek if a word
        : or a sentencs exists...
        : - chek the form of presentation of a word i.e. chek if the word is
        : bold, in which size, is it centered or aligned to left,...
        : thank you for your help


        for .doc files, google "antiword"


        --

        This space not for rent.

        Comment

        Working...