GithubHelp home page GithubHelp logo

guoyu07 / pdfparser-3 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from knutfr/pdfparser

0.0 0.0 0.0 744 KB

Creating indexes array from pdf file

License: GNU General Public License v3.0

PHP 100.00%

pdfparser-3's Introduction

Presentation

Ce script permet la création de fichier index (format tableau serialize) pour faire des recherches à partir de document pdf.

Utilisation

Creation de l'arborescence

Une fois les pdf récupéré, il faut splitter ceux-ci en page unique (http://www.splitpdf.com/ fait largement le boulot, il faut cocher Extract all pages into separate files) Une fois l'ensemble des chapitres split en page unique il faut créer l'arborescense suivante :

Pour utiliser ce script il faut créer un repertoire ayant la structure suivante:

  • root
    • 1
      • x.pdf
      • y.pdf
    • 2
      • z.pdf
      • w.pdf

Parametrage

Les parametres sont à renseigner dans settings.php

$rootdoc = "root"; //Repertoire racine (root dans l'exemple ci-dessus) $nbChapt = 1; //nombre de chapitre contenu dans le repertoire root (sous repertoire ayant un nombre incrementé)

$dataFile = "indexes/"; //repertoire de sortie pour le tableau de data serializé $dataTabFile = "data"; //nom du fichier stockant les indexs.

Utilisation

Une fois votre fichier data généré, placé celui-ci à la racine du site (au niveau de l'index.php et du search.php) la recherche s'effectuera maintenant sur les nouveaux index.

NOTES :

-La génération peut être longue, veillez à augmenté le max_execution_time dans votre php.ini, selon la taille des pdf et la machine sur laquel on génére les index. -Non sérieusement quand je dis long c'est super long ... pour 3 pdf j'ai mis quasi 10 minutes

pdfparser-3's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.