Constants

VERSION_97

VERSION_97 = '97'

VERSION_2000

VERSION_2000 = '2000'

VERSION_2002

VERSION_2002 = '2002'

VERSION_2003

VERSION_2003 = '2003'

VERSION_2007

VERSION_2007 = '2007'

SPRA_VALUE

SPRA_VALUE = 10

SPRA_VALUE_OPPOSITE

SPRA_VALUE_OPPOSITE = 20

OFFICEARTBLIPEMF

OFFICEARTBLIPEMF = 61466

OFFICEARTBLIPWMF

OFFICEARTBLIPWMF = 61467

OFFICEARTBLIPPICT

OFFICEARTBLIPPICT = 61468

OFFICEARTBLIPJPG

OFFICEARTBLIPJPG = 61469

OFFICEARTBLIPPNG

OFFICEARTBLIPPNG = 61470

OFFICEARTBLIPDIB

OFFICEARTBLIPDIB = 61471

OFFICEARTBLIPTIFF

OFFICEARTBLIPTIFF = 61481

OFFICEARTBLIPJPEG

OFFICEARTBLIPJPEG = 61482

MSOBLIPERROR

MSOBLIPERROR = 0

MSOBLIPUNKNOWN

MSOBLIPUNKNOWN = 1

MSOBLIPEMF

MSOBLIPEMF = 2

MSOBLIPWMF

MSOBLIPWMF = 3

MSOBLIPPICT

MSOBLIPPICT = 4

MSOBLIPJPEG

MSOBLIPJPEG = 5

MSOBLIPPNG

MSOBLIPPNG = 6

MSOBLIPDIB

MSOBLIPDIB = 7

MSOBLIPTIFF

MSOBLIPTIFF = 17

MSOBLIPCMYKJPEG

MSOBLIPCMYKJPEG = 18

Properties

$readDataOnly

$readDataOnly : boolean

Read data only?

Type

boolean

$fileHandle

$fileHandle : boolean|resource

File pointer

Type

boolean|resource

$dataWorkDocument

$dataWorkDocument : 

WordDocument Stream

Type

$data1Table

$data1Table : 

1Table Stream

Type

$dataData

$dataData : 

Data Stream

Type

$dataObjectPool

$dataObjectPool : 

Object Pool Stream

Type

$arrayCharacters

$arrayCharacters : array<mixed,\stdClass>

Type

array<mixed,\stdClass>

$arrayFib

$arrayFib : array

Type

array

$arrayFonts

$arrayFonts : array<mixed,string>

Type

array<mixed,string>

$arrayParagraphs

$arrayParagraphs : array<mixed,string>

Type

array<mixed,string>

$arraySections

$arraySections : array<mixed,\stdClass>

Type

array<mixed,\stdClass>

Methods

isReadDataOnly()

isReadDataOnly() : boolean

Read data only?

Returns

boolean

setReadDataOnly()

setReadDataOnly(boolean  $value = true) : self

Set read data only

Parameters

boolean $value

Returns

self

canRead()

canRead(string  $filename) : boolean

Can the current ReaderInterface read the file?

Parameters

string $filename

Returns

boolean

getReadDataOnly()

getReadDataOnly() 

Read data only?

load()

load(string  $filename) : \PhpOffice\PhpWord\PhpWord

Loads PhpWord from file

Parameters

string $filename

Returns

\PhpOffice\PhpWord\PhpWord

getInt1d()

getInt1d(string  $data, integer  $pos) : integer

Read 8-bit unsigned integer

Parameters

string $data
integer $pos

Returns

integer

getInt2d()

getInt2d(string  $data, integer  $pos) : integer

Read 16-bit unsigned integer

Parameters

string $data
integer $pos

Returns

integer

getInt3d()

getInt3d(string  $data, integer  $pos) : integer

Read 24-bit signed integer

Parameters

string $data
integer $pos

Returns

integer

getInt4d()

getInt4d(string  $data, integer  $pos) : integer

Read 32-bit signed integer

Parameters

string $data
integer $pos

Returns

integer

openFile()

openFile(string  $filename) : resource

Open file for reading

Parameters

string $filename

Throws

\PhpOffice\PhpWord\Exception\Exception

Returns

resource

loadOLE()

loadOLE(string  $filename) 

Load an OLE Document

Parameters

string $filename

getNumInLcb()

getNumInLcb(  $lcb,   $iSize) 

Parameters

$lcb
$iSize

getArrayCP()

getArrayCP(  $data,   $posMem,   $iNum) 

Parameters

$data
$posMem
$iNum

readFib()

readFib(string  $data) 

Parameters

string $data

readBlockFibRgFcLcb()

readBlockFibRgFcLcb(  $data,   $pos,   $version) 

Parameters

$data
$pos
$version

readFibContent()

readFibContent() 

readRecordPlcfSed()

readRecordPlcfSed() 

Section and information about them

readRecordSttbfFfn()

readRecordSttbfFfn() 

Specifies the fonts that are used in the document

readRecordPlcfBtePapx()

readRecordPlcfBtePapx() 

Paragraph and information about them

readRecordPlcfBteChpx()

readRecordPlcfBteChpx() 

Character formatting properties to text in a document

readSprm()

readSprm(  $sprm) : \stdClass

Parameters

$sprm

Returns

\stdClass

readSprmSpra()

readSprmSpra(string  $data, integer  $pos, \stdClass  $oSprm) : array

Parameters

string $data
integer $pos
\stdClass $oSprm

Returns

array

readPrl()

readPrl(  $data,   $pos,   $cbNum) : \stdClass

Parameters

$data

int

$pos

int

$cbNum

int

Returns

\stdClass

loadRecordHeader()

loadRecordHeader(string  $stream, integer  $pos) : array

Read a record header

Parameters

string $stream
integer $pos

Returns

array

generatePhpWord()

generatePhpWord()