{"id":16832640,"url":"https://github.com/zswang/jphps","last_synced_at":"2025-07-29T23:05:42.399Z","repository":{"id":57281813,"uuid":"50123361","full_name":"zswang/jphps","owner":"zswang","description":"Unmarked PHP template","archived":false,"fork":false,"pushed_at":"2017-11-08T06:23:01.000Z","size":24,"stargazers_count":5,"open_issues_count":2,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-03T07:49:25.174Z","etag":null,"topics":["php","template"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/zswang.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":"2016-01-21T17:15:51.000Z","updated_at":"2017-11-08T09:49:45.000Z","dependencies_parsed_at":"2022-08-31T10:51:24.088Z","dependency_job_id":null,"html_url":"https://github.com/zswang/jphps","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/zswang/jphps","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zswang%2Fjphps","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zswang%2Fjphps/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zswang%2Fjphps/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zswang%2Fjphps/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zswang","download_url":"https://codeload.github.com/zswang/jphps/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zswang%2Fjphps/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265451500,"owners_count":23767771,"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":["php","template"],"created_at":"2024-10-13T11:49:50.746Z","updated_at":"2025-07-15T18:35:31.426Z","avatar_url":"https://github.com/zswang.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"jphps(\u003c%\u003e)\n-----\n\n# [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Coverage Status][coverage-image]][coverage-url]\n\n## 处理前\n\n```html\nfunction renderItem($item) {\n  if (isset($item)) {\n  \u003cli\u003e\n    \u003ca href=\"!#{$item['url']}\"\u003e#{$item['title']}\u003c/a\u003e\n  \u003c/li\u003e\n  }\n}\n\n\u003cul\u003e\nrenderItem(array('url' =\u003e 'http://google.com/', 'title' =\u003e 'Google'));\nrenderItem(array('url' =\u003e 'http://www.baidu.com/', 'title' =\u003e '百度'));\n\u003c/ul\u003e\n```\n\n## 处理后\n\n```php\n\u003c?php function renderItem($item) {\n  if (isset($item)) { ?\u003e\n  \u003cli\u003e\n    \u003ca href=\"\u003c?php echo $item['url'] ?\u003e\"\u003e\u003c?php echo htmlentities($item['title']) ?\u003e\u003c/a\u003e\n  \u003c/li\u003e\n\u003c?php   }\n} ?\u003e\n\n\u003cul\u003e\n\u003c?php renderItem(array('url' =\u003e 'http://google.com/', 'title' =\u003e 'Google'));\nrenderItem(array('url' =\u003e 'http://www.baidu.com/', 'title' =\u003e '百度')); ?\u003e\n\u003c/ul\u003e\n```\n\n## 运行后\n\n```html\n\n\u003cul\u003e\n  \u003cli\u003e\n    \u003ca href=\"http://google.com/\"\u003eGoogle\u003c/a\u003e\n  \u003c/li\u003e\n  \u003cli\u003e\n    \u003ca href=\"http://www.baidu.com/\"\u003e百度\u003c/a\u003e\n  \u003c/li\u003e\n\u003c/ul\u003e\n```\n\n## License\n\nMIT © [zswang](http://weibo.com/zswang)\n\n[npm-url]: https://npmjs.org/package/jphps\n[npm-image]: https://badge.fury.io/js/jphps.svg\n[travis-url]: https://travis-ci.org/zswang/jphps\n[travis-image]: https://travis-ci.org/zswang/jphps.svg?branch=master\n[coverage-url]: https://coveralls.io/github/zswang/jphps?branch=master\n[coverage-image]: https://coveralls.io/repos/zswang/jphps/badge.svg?branch=master\u0026service=github\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzswang%2Fjphps","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzswang%2Fjphps","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzswang%2Fjphps/lists"}