Speichern Sie eine XLS-Datei als JSON in PHP
API
POST
https://api.aspose.cloud/v3.0/cells/{name}/SaveAs
Das Speichern von Dateiformaten von XLS als JSON ist eine komplexe Aufgabe. Alle Formatübergänge von XLS zu JSON werden von unserem SDK PHP durchgeführt, wobei der strukturelle und logische Hauptinhalt der Quell-XLS-Tabelle erhalten bleibt. Unsere Bibliothek PHP ist eine professionelle Lösung zum Online-Speichern von XLS als JSON-Dateien. Dieses Cloud-SDK bietet PHP-Entwicklern leistungsstarke Funktionen und perfekte JSON-Ausgabe.
PHP Codebeispiel zum Speichern von XLS als JSON mit REST API
// For complete examples and data files, please go to https://github.com/aspose-cells-cloud/aspose-cells-cloud-php/
$apiInstance = new CellsApi( getenv("ProductClientId"),getenv("ProductClientSecret") );
$name ='Book1.xls';
$saveOptions =new \Aspose\Cells\Cloud\Model\SaveOptions();
$saveOptions->SaveFormat = "json";
$newfilename = "Book1Saveas.json";
$isAutoFitRows= 'true';
$isAutoFitColumns= 'true';
$folder = "Temp";
$result = $apiInstance->cellsSaveAsPostDocumentSaveAs($name, $saveOptions, $newfilename,$isAutoFitRows, $isAutoFitColumns, $folder);
So speichern Sie XLS als JSON mithilfe der Cells Cloud PHP-Bibliothek.
- Registrieren Sie ein Konto unterArmaturenbrett um ein kostenloses API-Kontingent und Autorisierungsdetails zu erhalten
- Installieren Sie die Bibliothek PHP und fügen Sie die Referenz (importieren Sie die Bibliothek) zu Ihrem Projekt hinzu.
- Öffnen Sie die Quelldatei in PHP.
- Verwenden Sie die Methode `PostWorkbookSaveAs`, um den resultierenden Stream abzurufen.
System Anforderungen
- PHP 7.4 oder neuer