{"id":27884063,"url":"https://github.com/ivanstan/php-csv","last_synced_at":"2025-05-05T06:22:36.870Z","repository":{"id":56994808,"uuid":"246121279","full_name":"ivanstan/php-csv","owner":"ivanstan","description":null,"archived":false,"fork":false,"pushed_at":"2020-03-12T18:45:25.000Z","size":46,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2024-04-17T09:27:30.781Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ivanstan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-03-09T19:14:26.000Z","updated_at":"2020-03-12T18:39:04.000Z","dependencies_parsed_at":"2022-08-21T13:50:33.122Z","dependency_job_id":null,"html_url":"https://github.com/ivanstan/php-csv","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanstan%2Fphp-csv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanstan%2Fphp-csv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanstan%2Fphp-csv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanstan%2Fphp-csv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ivanstan","download_url":"https://codeload.github.com/ivanstan/php-csv/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252448814,"owners_count":21749550,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-05-05T06:22:36.037Z","updated_at":"2025-05-05T06:22:36.862Z","avatar_url":"https://github.com/ivanstan.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PhpCsv\n\nPhpCsv is performant csv data manipulation framework. \n\n### Usage\n\nBatch reading text file:\n```\nuse PhpCsv/TextFileReader;\n\n$reader = new TextFileReader('data.list');\n\nforeach($reader-\u003ebatch(10) as $batch) {\n    // $batch is array of 10 lines from file\n}\n```\nBatch reading csv file:\n```\nuse PhpCsv/CsvFileReader;\n\n$file = (new CsvFileReader('data.csv', new CsvFileMetadata()))\n    -\u003efirstLineIsHeader(true)\n    -\u003efetchAssoc(true)\n    -\u003eskipEmpty(true);\n\nforeach($reader-\u003ebatch(10) as $batch) {\n    // $batch is array of 10 rows from file\n\n    Array\n    (\n        [0] =\u003e Array\n            (\n                [id] =\u003e 1\n                [first_name] =\u003e Pattin\n                [last_name] =\u003e Vivyan\n                [email] =\u003e pvivyan0@ox.ac.uk\n                [gender] =\u003e Male\n                [ip_address] =\u003e 176.228.167.165\n            )\n    \n        [1] =\u003e Array\n            (\n                [id] =\u003e 2\n                [first_name] =\u003e Lynette\n                [last_name] =\u003e Kerne\n                [email] =\u003e lkerne1@wix.com\n                [gender] =\u003e Female\n                [ip_address] =\u003e 34.167.242.184\n            )\n\n        ...\n\n    )\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivanstan%2Fphp-csv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fivanstan%2Fphp-csv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivanstan%2Fphp-csv/lists"}