Skip to content

Instantly share code, notes, and snippets.

@aspose-words-cloud-gists
Last active May 15, 2023 14:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aspose-words-cloud-gists/e2a72445b96362dc0117f06ab54bb94a to your computer and use it in GitHub Desktop.
Save aspose-words-cloud-gists/e2a72445b96362dc0117f06ab54bb94a to your computer and use it in GitHub Desktop.
This gist exceeds the recommended number of files (~10). To access all files, please clone this gist.
This Gist contains PHP code samples for Aspose.Words Cloud API
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{AcceptAllRevisionsRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$acceptRequest = new AcceptAllRevisionsRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->acceptAllRevisions($acceptRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{AcceptAllRevisionsOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$acceptRequest = new AcceptAllRevisionsOnlineRequest(
$requestDocument, NULL, NULL, NULL, NULL);
$wordsApi->acceptAllRevisionsOnline($acceptRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{AppendDocumentRequest};
use Aspose\Words\Model\{DocumentEntry, DocumentEntryList, FileReference};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$remoteFileName = "Sample.docx";
$requestDocumentListDocumentEntries0FileReference = FileReference::fromRemoteFilePath($remoteFileName);
$requestDocumentListDocumentEntries0 = new DocumentEntry(array(
"file_reference" => $requestDocumentListDocumentEntries0FileReference,
"import_format_mode" => "KeepSourceFormatting",));
$requestDocumentListDocumentEntries = [
$requestDocumentListDocumentEntries0,
];
$requestDocumentList = new DocumentEntryList(array(
"document_entries" => $requestDocumentListDocumentEntries,));
$appendRequest = new AppendDocumentRequest(
$remoteFileName, $requestDocumentList, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->appendDocument($appendRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{AppendDocumentOnlineRequest};
use Aspose\Words\Model\{DocumentEntry, DocumentEntryList, FileReference};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$localFile = "Sample.docx";
$requestDocument = $localFile;
$requestDocumentListDocumentEntries0FileReferenceStream = realpath(__DIR__ . '/../../..') . '/TestData/' . $localFile;
$requestDocumentListDocumentEntries0FileReference = FileReference::fromLocalFileContent($requestDocumentListDocumentEntries0FileReferenceStream);
$requestDocumentListDocumentEntries0 = new DocumentEntry(array(
"file_reference" => $requestDocumentListDocumentEntries0FileReference,
"import_format_mode" => "KeepSourceFormatting",));
$requestDocumentListDocumentEntries = [
$requestDocumentListDocumentEntries0,
];
$requestDocumentList = new DocumentEntryList(array(
"document_entries" => $requestDocumentListDocumentEntries,));
$appendRequest = new AppendDocumentOnlineRequest(
$requestDocument, $requestDocumentList, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->appendDocumentOnline($appendRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ApplyStyleToDocumentElementRequest};
use Aspose\Words\Model\{StyleApply};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestStyleApply = new StyleApply(array(
"style_name" => "Heading 1",));
$applyStyleRequest = new ApplyStyleToDocumentElementRequest(
"Sample.docx", "paragraphs/1/paragraphFormat", $requestStyleApply, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->applyStyleToDocumentElement($applyStyleRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ApplyStyleToDocumentElementOnlineRequest};
use Aspose\Words\Model\{StyleApply};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$requestStyleApply = new StyleApply(array(
"style_name" => "Heading 1",));
$applyStyleRequest = new ApplyStyleToDocumentElementOnlineRequest(
$requestDocument, "paragraphs/1/paragraphFormat", $requestStyleApply, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->applyStyleToDocumentElementOnline($applyStyleRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{BuildReportRequest};
use Aspose\Words\Model\{ReportEngineSettings};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestReportEngineSettingsReportBuildOptions = [
"AllowMissingMembers",
"RemoveEmptyParagraphs",
];
$requestReportEngineSettings = new ReportEngineSettings(array(
"data_source_type" => "Json",
"report_build_options" => $requestReportEngineSettingsReportBuildOptions,));
$buildReportRequest = new BuildReportRequest(
"Sample.docx", "Data.json", $requestReportEngineSettings, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->buildReport($buildReportRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{BuildReportOnlineRequest};
use Aspose\Words\Model\{ReportEngineSettings};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestTemplate = "Sample.docx";
$requestReportEngineSettings = new ReportEngineSettings(array(
"data_source_type" => "Json",
"data_source_name" => "persons",));
$buildReportRequest = new BuildReportOnlineRequest(
$requestTemplate, "Data.json", $requestReportEngineSettings, NULL);
$wordsApi->buildReportOnline($buildReportRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ClassifyRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$classifyRequest = new ClassifyRequest(
"Try text classification", "3");
$wordsApi->classify($classifyRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ClassifyDocumentRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$classifyRequest = new ClassifyDocumentRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, "3", NULL);
$wordsApi->classifyDocument($classifyRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ClassifyDocumentOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$classifyRequest = new ClassifyDocumentOnlineRequest(
$requestDocument, NULL, NULL, NULL, "3", NULL);
$wordsApi->classifyDocumentOnline($classifyRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CompareDocumentRequest};
use Aspose\Words\Model\{CompareData};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestCompareData = new CompareData(array(
"author" => "author",
"comparing_with_document" => "TestCompareDocument2.doc",
"date_time" => new \DateTime("2015-10-26T00:00:00.0000000Z"),));
$compareRequest = new CompareDocumentRequest(
"TestCompareDocument1.doc", $requestCompareData, NULL, NULL, NULL, NULL, NULL, "CompareDocumentOut.doc", NULL);
$wordsApi->compareDocument($compareRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CompareDocumentOnlineRequest};
use Aspose\Words\Model\{CompareData};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "compareTestDoc1.doc";
$requestCompareData = new CompareData(array(
"author" => "author",
"comparing_with_document" => "TestCompareDocument2.doc",
"date_time" => new \DateTime("2015-10-26T00:00:00.0000000Z"),));
$requestComparingDocument = "compareTestDoc2.doc";
$compareRequest = new CompareDocumentOnlineRequest(
$requestDocument, $requestCompareData, $requestComparingDocument, NULL, NULL, NULL, "CompareDocumentOut.doc", NULL);
$wordsApi->compareDocumentOnline($compareRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CompressDocumentRequest};
use Aspose\Words\Model\{CompressOptions};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestCompressOptions = new CompressOptions(array());
$compressDocument = new CompressDocumentRequest(
"Sample.docx", $requestCompressOptions, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->compressDocument($compressDocument);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CompressDocumentOnlineRequest};
use Aspose\Words\Model\{CompressOptions};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "TestCompress.docx";
$requestCompressOptions = new CompressOptions(array());
$compressDocumentOnline = new CompressDocumentOnlineRequest(
$requestDocument, $requestCompressOptions, NULL, NULL, NULL, NULL);
$wordsApi->compressDocumentOnline($compressDocumentOnline);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ConvertDocumentRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$convertRequest = new ConvertDocumentRequest(
$requestDocument, "pdf", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->convertDocument($convertRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ConvertDocumentRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$convertRequest = new ConvertDocumentRequest(
$requestDocument, "pdf", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->convertDocument($convertRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ConvertDocumentRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$convertRequest = new ConvertDocumentRequest(
$requestDocument, "pdf", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->convertDocument($convertRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CopyFileRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$copyRequest = new CopyFileRequest(
"Copy.docx", "Sample.docx", NULL, NULL, NULL);
$wordsApi->copyFile($copyRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CopyFolderRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$folderToCopy = "/TestCopyFolder";
$copyRequest = new CopyFolderRequest(
$folderToCopy . "Dest", $folderToCopy . "Src", NULL, NULL);
$wordsApi->copyFolder($copyRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CopyStyleRequest};
use Aspose\Words\Model\{StyleCopy};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestStyleCopy = new StyleCopy(array(
"style_name" => "Heading 1",));
$copyRequest = new CopyStyleRequest(
"Sample.docx", $requestStyleCopy, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->copyStyle($copyRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CopyStyleOnlineRequest};
use Aspose\Words\Model\{StyleCopy};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$requestStyleCopy = new StyleCopy(array(
"style_name" => "Heading 1",));
$copyRequest = new CopyStyleOnlineRequest(
$requestDocument, $requestStyleCopy, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->copyStyleOnline($copyRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CopyStylesFromTemplateRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$copyRequest = new CopyStylesFromTemplateRequest(
"Sample.docx", "StyleTemplate.docx", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->copyStylesFromTemplate($copyRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CreateDocumentRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$createRequest = new CreateDocumentRequest(
"Sample.docx", NULL, NULL);
$wordsApi->createDocument($createRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CreateFolderRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$createRequest = new CreateFolderRequest(
"/TestCreateFolder", NULL);
$wordsApi->createFolder($createRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CreateOrUpdateDocumentPropertyRequest};
use Aspose\Words\Model\{DocumentPropertyCreateOrUpdate};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestProperty = new DocumentPropertyCreateOrUpdate(array(
"value" => "John Doe",));
$createRequest = new CreateOrUpdateDocumentPropertyRequest(
"Sample.docx", "AsposeAuthor", $requestProperty, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->createOrUpdateDocumentProperty($createRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{CreateOrUpdateDocumentPropertyOnlineRequest};
use Aspose\Words\Model\{DocumentPropertyCreateOrUpdate};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$requestProperty = new DocumentPropertyCreateOrUpdate(array(
"value" => "John Doe",));
$createRequest = new CreateOrUpdateDocumentPropertyOnlineRequest(
$requestDocument, "AsposeAuthor", $requestProperty, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->createOrUpdateDocumentPropertyOnline($createRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteAllParagraphTabStopsRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteAllParagraphTabStopsRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteAllParagraphTabStops($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteAllParagraphTabStopsOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteAllParagraphTabStopsOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteAllParagraphTabStopsOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteBookmarkRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteBookmarkRequest(
"Sample.docx", "aspose", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteBookmark($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteBookmarkOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteBookmarkOnlineRequest(
$requestDocument, "aspose", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteBookmarkOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteBookmarksRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteBookmarksRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteBookmarks($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteBookmarksOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteBookmarksOnlineRequest(
$requestDocument, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteBookmarksOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteBorderRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteBorderRequest(
"Sample.docx", "left", "tables/1/rows/0/cells/0", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteBorder($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteBorderOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteBorderOnlineRequest(
$requestDocument, "left", "tables/1/rows/0/cells/0", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteBorderOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteBordersRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteBordersRequest(
"Sample.docx", "tables/1/rows/0/cells/0", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteBorders($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteBordersOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteBordersOnlineRequest(
$requestDocument, "tables/1/rows/0/cells/0", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteBordersOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteCommentRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteCommentRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteComment($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteCommentOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteCommentOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteCommentOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteCommentsRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteCommentsRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteComments($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteCommentsOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteCommentsOnlineRequest(
$requestDocument, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteCommentsOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteCustomXmlPartRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteCustomXmlPartRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteCustomXmlPart($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteCustomXmlPartOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteCustomXmlPartOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteCustomXmlPartOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteCustomXmlPartsRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteCustomXmlPartsRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteCustomXmlParts($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteCustomXmlPartsOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteCustomXmlPartsOnlineRequest(
$requestDocument, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteCustomXmlPartsOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteDocumentPropertyRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteDocumentPropertyRequest(
"Sample.docx", "testProp", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteDocumentProperty($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteDocumentPropertyOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteDocumentPropertyOnlineRequest(
$requestDocument, "testProp", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteDocumentPropertyOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteDrawingObjectRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteDrawingObjectRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteDrawingObject($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteDrawingObjectOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteDrawingObjectOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteDrawingObjectOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFieldRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteFieldRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteField($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFieldOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteFieldOnlineRequest(
$requestDocument, 0, "sections/0/paragraphs/0", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteFieldOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFieldsRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteFieldsRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteFields($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFieldsOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteFieldsOnlineRequest(
$requestDocument, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteFieldsOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFileRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteFileRequest(
"Sample.docx", NULL, NULL);
$wordsApi->deleteFile($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFolderRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteFolderRequest(
"", NULL, NULL);
$wordsApi->deleteFolder($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFootnoteRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteFootnoteRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteFootnote($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFootnoteOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.doc";
$deleteRequest = new DeleteFootnoteOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteFootnoteOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFormFieldRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteFormFieldRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteFormField($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteFormFieldOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteFormFieldOnlineRequest(
$requestDocument, 0, "sections/0", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteFormFieldOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteHeaderFooterRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteHeaderFooterRequest(
"Sample.docx", "", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteHeaderFooter($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteHeaderFooterOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.doc";
$deleteRequest = new DeleteHeaderFooterOnlineRequest(
$requestDocument, "", 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteHeaderFooterOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteHeadersFootersRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteHeadersFootersRequest(
"Sample.docx", "", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteHeadersFooters($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteHeadersFootersOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.doc";
$deleteRequest = new DeleteHeadersFootersOnlineRequest(
$requestDocument, "", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteHeadersFootersOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteMacrosRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteMacrosRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteMacros($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteMacrosOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteMacrosOnlineRequest(
$requestDocument, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteMacrosOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteOfficeMathObjectRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteOfficeMathObjectRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteOfficeMathObject($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteOfficeMathObjectOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteOfficeMathObjectOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteOfficeMathObjectOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteParagraphRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteParagraphRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteParagraph($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteParagraphListFormatRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteParagraphListFormatRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteParagraphListFormat($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteParagraphListFormatOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.doc";
$deleteRequest = new DeleteParagraphListFormatOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteParagraphListFormatOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteParagraphOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteParagraphOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteParagraphOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteParagraphTabStopRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteParagraphTabStopRequest(
"Sample.docx", 72.0, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteParagraphTabStop($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteParagraphTabStopOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteParagraphTabStopOnlineRequest(
$requestDocument, 72.0, 0, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteParagraphTabStopOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteRunRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteRunRequest(
"Sample.docx", "paragraphs/1", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteRun($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteRunOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.doc";
$deleteRequest = new DeleteRunOnlineRequest(
$requestDocument, "paragraphs/1", 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteRunOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteSectionRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteSectionRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteSection($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteSectionOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteSectionOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteSectionOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteStructuredDocumentTagRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteStructuredDocumentTagRequest(
"Sample.docx", 0, "sections/0/body/paragraphs/0", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteStructuredDocumentTag($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteStructuredDocumentTagOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteStructuredDocumentTagOnlineRequest(
$requestDocument, 0, "sections/0/body/paragraphs/0", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteStructuredDocumentTagOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteTableRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteTableRequest(
"Sample.docx", 1, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteTable($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteTableCellRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteTableCellRequest(
"Sample.docx", "sections/0/tables/2/rows/0", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteTableCell($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteTableCellOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteTableCellOnlineRequest(
$requestDocument, "sections/0/tables/2/rows/0", 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteTableCellOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteTableOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteTableOnlineRequest(
$requestDocument, 1, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteTableOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteTableRowRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteTableRowRequest(
"Sample.docx", "tables/1", 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteTableRow($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteTableRowOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteTableRowOnlineRequest(
$requestDocument, "tables/1", 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteTableRowOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteWatermarkRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$deleteRequest = new DeleteWatermarkRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteWatermark($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DeleteWatermarkOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$deleteRequest = new DeleteWatermarkOnlineRequest(
$requestDocument, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->deleteWatermarkOnline($deleteRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{DownloadFileRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$downloadRequest = new DownloadFileRequest(
"Sample.docx", NULL, NULL);
$wordsApi->downloadFile($downloadRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ExecuteMailMergeRequest};
use Aspose\Words\Model\{FieldOptions, UserInformation};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestOptionsCurrentUser = new UserInformation(array(
"name" => "SdkTestUser",));
$requestOptions = new FieldOptions(array(
"current_user" => $requestOptionsCurrentUser,));
$mailMergeRequest = new ExecuteMailMergeRequest(
"Sample.docx", file_get_contents(realpath(__DIR__ . '/../../..') . "/TestData/" . "TestMailMergeData.xml"), $requestOptions, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->executeMailMerge($mailMergeRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests;
// Create WordsApi instance
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$fileName = "template.doc";
$destName = "Out_PostDocumentExecuteMailMergeWithHTMLData.docx";
$data = file_get_contents('TestPostDocumentExecuteMailMerge.txt');
// Upload document to Cloud Storage
$wordsApi->uploadFile(new Requests\UploadFileRequest($fileName, "", null));
// Create request and execute api method
$request = new Requests\ExecuteMailMergeRequest($fileName, $data, null, null, null, null, null, null, null, false, $destName);
$result = $wordsApi->executeMailMerge($request);
print_r($result);
?>
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests;
// Create WordsApi instance
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$fileName = "SampleMailMergeTemplate.docx";
$destName = "Out_SampleMailMergeTemplate.docx";
$data = file_get_contents('SampleMailMergeTemplateData.xml');
// Upload document to Cloud Storage
$wordsApi->uploadFile(new Requests\UploadFileRequest($fileName, "", null));
// Create request and execute api method
$request = new Requests\ExecuteMailMergeRequest($fileName, $data, null, null, null, null, null, null, null, false, $destName);
$result = $wordsApi->executeMailMerge($request);
print_r($result);
?>
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ExecuteMailMergeOnlineRequest};
use Aspose\Words\Model\{FieldOptions, UserInformation};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestTemplate = "Sample.docx";
$requestData = file_get_contents(realpath(__DIR__ . '/../../..') . "/TestData/" . "TestMailMergeData.xml");
$requestOptionsCurrentUser = new UserInformation(array(
"name" => "SdkTestUser",));
$requestOptions = new FieldOptions(array(
"current_user" => $requestOptionsCurrentUser,));
$mailMergeRequest = new ExecuteMailMergeOnlineRequest(
$requestTemplate, $requestData, $requestOptions, NULL, NULL, NULL);
$wordsApi->executeMailMergeOnline($mailMergeRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ExecuteMailMergeOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestTemplate = "TestMailMergeWithImages.doc";
$requestData = "MailMergeData.json";
$mailMergeRequest = new ExecuteMailMergeOnlineRequest(
$requestTemplate, $requestData, NULL, NULL, NULL, "Out_TestMailMergeWithImages.doc");
$wordsApi->executeMailMergeOnline($mailMergeRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ExecuteMailMergeOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestTemplate = "template.doc";
$requestData = "TestPostDocumentExecuteMailMerge.txt";
$mailMergeRequest = new ExecuteMailMergeOnlineRequest(
$requestTemplate, $requestData, NULL, NULL, NULL, "Out_PostDocumentExecuteMailMergeWithHTMLData.docx");
$wordsApi->executeMailMergeOnline($mailMergeRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{ExecuteMailMergeOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestTemplate = "SampleMailMergeTemplate.docx";
$requestData = "SampleMailMergeTemplateData.xml";
$mailMergeRequest = new ExecuteMailMergeOnlineRequest(
$requestTemplate, $requestData, NULL, NULL, NULL, "Out_SampleMailMergeTemplate.docx");
$wordsApi->executeMailMergeOnline($mailMergeRequest);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetAvailableFontsRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetAvailableFontsRequest(
NULL);
$wordsApi->getAvailableFonts($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetBookmarkByNameRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetBookmarkByNameRequest(
"Sample.docx", "aspose", NULL, NULL, NULL, NULL, NULL);
$wordsApi->getBookmarkByName($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetBookmarkByNameOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetBookmarkByNameOnlineRequest(
$requestDocument, "aspose", NULL, NULL, NULL);
$wordsApi->getBookmarkByNameOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetBookmarksRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetBookmarksRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL);
$wordsApi->getBookmarks($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetBookmarksOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetBookmarksOnlineRequest(
$requestDocument, NULL, NULL, NULL);
$wordsApi->getBookmarksOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetBorderRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetBorderRequest(
"Sample.docx", "left", "tables/1/rows/0/cells/0", NULL, NULL, NULL, NULL, NULL);
$wordsApi->getBorder($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetBorderOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetBorderOnlineRequest(
$requestDocument, "left", "tables/1/rows/0/cells/0", NULL, NULL, NULL);
$wordsApi->getBorderOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetBordersRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetBordersRequest(
"Sample.docx", "tables/1/rows/0/cells/0", NULL, NULL, NULL, NULL, NULL);
$wordsApi->getBorders($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetBordersOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetBordersOnlineRequest(
$requestDocument, "tables/1/rows/0/cells/0", NULL, NULL, NULL);
$wordsApi->getBordersOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetCommentRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetCommentRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL);
$wordsApi->getComment($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetCommentOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetCommentOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL);
$wordsApi->getCommentOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetCommentsRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetCommentsRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL);
$wordsApi->getComments($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetCommentsOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetCommentsOnlineRequest(
$requestDocument, NULL, NULL, NULL);
$wordsApi->getCommentsOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetCustomXmlPartRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetCustomXmlPartRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL);
$wordsApi->getCustomXmlPart($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetCustomXmlPartOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetCustomXmlPartOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL);
$wordsApi->getCustomXmlPartOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetCustomXmlPartsRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetCustomXmlPartsRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL);
$wordsApi->getCustomXmlParts($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetCustomXmlPartsOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetCustomXmlPartsOnlineRequest(
$requestDocument, NULL, NULL, NULL);
$wordsApi->getCustomXmlPartsOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetDocumentRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL);
$wordsApi->getDocument($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentDrawingObjectByIndexRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetDocumentDrawingObjectByIndexRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->getDocumentDrawingObjectByIndex($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentDrawingObjectByIndexOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetDocumentDrawingObjectByIndexOnlineRequest(
$requestDocument, 0, "sections/0", NULL, NULL, NULL);
$wordsApi->getDocumentDrawingObjectByIndexOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentDrawingObjectImageDataRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetDocumentDrawingObjectImageDataRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->getDocumentDrawingObjectImageData($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentDrawingObjectImageDataOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetDocumentDrawingObjectImageDataOnlineRequest(
$requestDocument, 0, "sections/0", NULL, NULL, NULL);
$wordsApi->getDocumentDrawingObjectImageDataOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentDrawingObjectOleDataRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetDocumentDrawingObjectOleDataRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->getDocumentDrawingObjectOleData($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentDrawingObjectOleDataOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetDocumentDrawingObjectOleDataOnlineRequest(
$requestDocument, 0, "sections/0", NULL, NULL, NULL);
$wordsApi->getDocumentDrawingObjectOleDataOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentDrawingObjectsRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetDocumentDrawingObjectsRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->getDocumentDrawingObjects($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentDrawingObjectsOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetDocumentDrawingObjectsOnlineRequest(
$requestDocument, "sections/0", NULL, NULL, NULL);
$wordsApi->getDocumentDrawingObjectsOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentFieldNamesRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetDocumentFieldNamesRequest(
"Sample.docx", NULL, NULL, NULL, NULL, NULL, NULL);
$wordsApi->getDocumentFieldNames($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentFieldNamesOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestTemplate = "Sample.docx";
$request = new GetDocumentFieldNamesOnlineRequest(
$requestTemplate, NULL, NULL, NULL, true);
$wordsApi->getDocumentFieldNamesOnline($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentHyperlinkByIndexRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$request = new GetDocumentHyperlinkByIndexRequest(
"Sample.docx", 0, NULL, NULL, NULL, NULL, NULL);
$wordsApi->getDocumentHyperlinkByIndex($request);
<?php
use Aspose\Words\WordsApi;
use Aspose\Words\Model\Requests\{GetDocumentHyperlinkByIndexOnlineRequest};
$clientId = '####-####-####-####-####';
$secret = '##################';
$wordsApi = new WordsApi($clientId, $secret);
$requestDocument = "Sample.docx";
$request = new GetDocumentHyperlinkByIndexOnlineRequest(
$requestDocument, 0, NULL, NULL, NULL);
$wordsApi->getDocumentHyperlinkByIndexOnline($request);