codedefective/translateandsearch

此包的最新版本(v1.0)没有可用的许可信息。

翻译和搜索

v1.0 2019-05-19 14:04 UTC

This package is auto-updated.

Last update: 2024-09-20 19:25:00 UTC


README

介绍

此应用程序是一个使用Zend框架基础设施并从谷歌人工智能获取动力的翻译应用程序。

它还专注于翻译后想要搜索的单词。

安装

使用Composer(推荐)

克隆存储库并手动使用附带的composer.phar调用composer

cd my/project/dir
git clone git://github.com/codedefective/translateandsearch.git
cd translateandsearch
php composer.phar self-update
php composer.phar install

self-update指令是为了确保您有最新的composer.phar可用。)

使用Git子模块

或者,您也可以使用本地的git子模块进行安装

git clone git://github.com/codedefective/translateandsearch.git --recursive

Web服务器设置

PHP CLI服务器

如果您使用的是PHP 5.4或更高版本,最简单的方法是在根目录中启动内部PHP cli-server

php -S 0.0.0.0:8080 -t public/ public/index.php

这将在8080端口启动cli-server,并将其绑定到所有网络接口。

**注意:** 内置的CLI服务器仅用于开发。

Apache设置

要设置Apache,请设置一个虚拟主机,指向项目的public/目录,您就可以开始了!它应该看起来像下面这样

<VirtualHost *:80>
    ServerName translateandsearch.localhost
    DocumentRoot /path/to/translateandsearch/public
    SetEnv APPLICATION_ENV "development"
    <Directory /path/to/translateandsearch/public>
        DirectoryIndex index.php
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>
</VirtualHost>