EZ Publish虚拟主机设置详解.docx

上传人:b****6 文档编号:4686581 上传时间:2022-12-07 格式:DOCX 页数:8 大小:65.95KB
下载 相关 举报
EZ Publish虚拟主机设置详解.docx_第1页
第1页 / 共8页
EZ Publish虚拟主机设置详解.docx_第2页
第2页 / 共8页
EZ Publish虚拟主机设置详解.docx_第3页
第3页 / 共8页
EZ Publish虚拟主机设置详解.docx_第4页
第4页 / 共8页
EZ Publish虚拟主机设置详解.docx_第5页
第5页 / 共8页
点击查看更多>>
下载资源
资源描述

EZ Publish虚拟主机设置详解.docx

《EZ Publish虚拟主机设置详解.docx》由会员分享,可在线阅读,更多相关《EZ Publish虚拟主机设置详解.docx(8页珍藏版)》请在冰豆网上搜索。

EZ Publish虚拟主机设置详解.docx

EZPublish虚拟主机设置详解

EZPublish虚拟主机设置详解

✓出处:

站长百科

✓原文地址:

✓本电子书整理自站长百科EZ_Publish/EZ_Publish虚拟主机设置词条,查看内容请访问网站。

通用虚拟注意配置

虚拟主机通常在"httpd.conf"(Apache服务器的主要配置文件)结尾处定义。

可以复制以下内容并替换方括号"[]"内部的内容。

参阅下面真实的虚拟主机配置文件示例。

NameVirtualHost[IP_ADDRESS]

[PORT]>

OptionsFollowSymLinks

AllowOverrideNone

php_admin_flagsafe_modeOff

php_admin_valueregister_globals0

php_valuemagic_quotes_gpc0

php_valuemagic_quotes_runtime0

php_valueallow_call_time_pass_reference0

DirectoryIndexindex.php

RewriteEngineOn

RewriteRulecontent/treemenu/?

$/index_treemenu.php[L]

Rewriterule^/var/storage/.*-[L]

Rewriterule^/var/[^/]+/storage/.*-[L]

RewriteRule^/var/cache/texttoimage/.*-[L]

RewriteRule^/var/[^/]+/cache/texttoimage/.*-[L]

Rewriterule^/design/[^/]+/(stylesheets|images|javascript)/.*-[L]

Rewriterule^/share/icons/.*-[L]

Rewriterule^/extension/[^/]+/design/[^/]+/(stylesheets|images|javascripts?

)/.*-

[L]

Rewriterule^/packages/styles/.+/(stylesheets|images|javascript)/[^/]+/.*-[L]

RewriteRule^/packages/styles/.+/thumbnail/.*-[L]

RewriteRule^/favicon\.ico-[L]

RewriteRule^/robots\.txt-[L]

#Uncommentthefollowinglineswhenusingpopupstyledebug.

#RewriteRule^/var/cache/debug\.html.*-[L]

#RewriteRule^/var/[^/]+/cache/debug\.html.*-[L]

RewriteRule.*/index.php

DocumentRoot[PATH_TO_EZPUBLISH]

ServerName[SERVER_NAME]

ServerAlias[SERVER_ALIAS]

[IP_ADDRESS]

虚拟主机的IP地址,例如:

"128.39.140.28"。

Apache允许使用通配符("*")

[PORT]

WEB服务器的监听端口。

端口配置是可选配置,默认端口为80。

IP地址与端口的组合通常被称为套接字。

Apache允许使用通配符("*")

[PATH_TO_EZPUBLISH]

eZPublish安装目录的绝对路径。

如:

"/var/www/ezpublish-3.6.0"

[SERVER_NAME]

Apache需要监控的IP地址或主机名。

如果匹配,对应的虚拟主机配置会被使用

[SERVER_ALIAS]

Apache需要监控的附加的主机名/IP地址。

如果匹配,对应的虚拟主机配置会被使用

注意:

"mod_rewrite"模块必须在"httpd.conf"中启用,才能使用RewriteRules。

NameVirtualHost

"NameVirtualHost"配置可能已经存在。

如果定义新的NameVirtualHost会造成冲突。

如果“ Apache报告如“NameVirtualHost[IP_ADDRESS]没有VirtualHost ”或“ 不能混用*端口和非*端口的NameVirtualHost地址 ”的错误,尝试注释NameVirtualHost这一行。

详情请参阅http:

//httpd.apache.org/docs/1.3/mod/core.html#namevirtualhost了解更多关于NameVirtualHost的内容。

SOAP与WebDAV

如果希望在eZPublish中使用SOAP与/或WebDAV,需要在虚拟主机配置文件中添加以下内容:

RewriteCond %{HTTP_HOST}^webdav\..*

RewriteRule^(.*)/webdav.php[L]

RewriteCond %{HTTP_HOST}^soap\..*

RewriteRule^(.*)/soap.php[L]

ServerAlias

ServerAlias

配置示例

此示例演示了如何在Apache中为eZPublish配置虚拟主机。

假设eZPublish安装在"/var/www/example",并且可以通过以下URL访问:

•(公共站点入口)

•(管理界面站点入口)

为了达到这个目的,需要配置Apache和eZPublish从而保证它们可以正确相应不同的请求。

配置eZPublish

站点入口配置eZPublish需要被配置为使用主机名访问方法。

可以通过安装向导或手动编辑"settings/override/site.ini.append.php"。

典型的配置如下:

...

[SiteAccessSettings]

AvailableSiteAccessList[]

AvailableSiteAccessList[]=example

AvailableSiteAccessList[]=example_admin

MatchOrder=host

HostMatchMapItems[]=;example

HostMatchMapItems[]=;example_admin

...

以上配置要求eZPublish为""使用"example"站点入口,为""使用"example_admin"站点入口。

参阅“EZPublish基本概念

(二)”中的“站点管理”章节了解更多站点管理的内容。

Apache配置

虚拟主机配置

对此我们先做出一个安装假设

•eZPublish被安装在"/var/www/example"

•服务器IP地址为128.39.140.28

•希望通过""和""访问站点

以下虚拟主机配置需要被添加到"http.conf"结尾处:

NameVirtualHost128.39.140.28

OptionsFollowSymLinks

AllowOverrideNone

php_admin_flagsafe_modeOff

php_admin_valueregister_globals0

php_valuemagic_quotes_gpc0

php_valuemagic_quotes_runtime0

php_valueallow_call_time_pass_reference0

DirectoryIndexindex.php

RewriteEngineOn

RewriteRulecontent/treemenu/?

$/index_treemenu.php[L]

Rewriterule^/var/storage/.*-[L]

Rewriterule^/var/[^/]+/storage/.*-[L]

RewriteRule^/var/cache/texttoimage/.*-[L]

RewriteRule^/var/[^/]+/cache/texttoimage/.*-[L]

Rewriterule^/design/[^/]+/(stylesheets|images|javascript)/.*-[L]

Rewriterule^/share/icons/.*-[L]

Rewriterule^/extension/[^/]+/design/[^/]+/(stylesheets|images|javascripts?

)/.*-

[L]

Rewriterule^/packages/styles/.+/(stylesheets|images|javascript)/[^/]+/.*-[L]

RewriteRule^/packages/styles/.+/thumbnail/.*-[L]

RewriteRule^/favicon\.ico-[L]

RewriteRule^/robots\.txt-[L]

#Uncommentthefollowinglineswhenusingpopupstyledebug.

#RewriteRule^/var/cache/debug\.html.*-[L]

#RewriteRule^/var/[^/]+/cache/debug\.html.*-[L]

RewriteRule.*/index.php

DocumentRoot/var/www/example

ServerName

ServerAlias

注意:

不必为""配置单独的虚拟主机,它可以作为"ServerAlias"添加。

可以在同一个虚拟主机内使用apache1和apache2。

这种方式允许用户为两个服务器中使用同一个虚拟主机。

#IfyouareusingApache2,youhavetouse

#insteadof.

#someparts/addonsmightonlyrunsafemodeon

php_admin_flagsafe_modeOff

#securityjustincase

php_admin_valueregister_globals0

#performance

php_valuemagic_quotes_gpc0

#performance

php_valuemagic_quotes_runtime0

#

php_valueallow_call_time_pass_reference0

#IfyouareusingApache2,youhavetouse

#insteadof.

#someparts/addonsmightonlyrunsafemodeon

php_admin_flagsafe_modeOff

#securityjustincase

php_admin_valueregister_globals0

#performance

php_valuemagic_quotes_gpc0

#performance

php_valuemagic_quotes_runtime0

#

php_valueallow_call_time_pass_reference0

参考来源

∙http:

//ez.no/eZPublish/New-Release

EZPublish使用手册导航

EZPublish安装卸载:

EZPublish正常安装|EZPublish手动安装|EZPublish自动安装|EZPublish安装向导|EZPublish虚拟主机设置|EZPublish使用扩展|EZPublish的卸载

EZPublish的使用:

模板使用:

EZPublish节点模板|EZPublish系统模板|EZPublishPagelayout页头信息|EZPublishPagelayout变量|EZPublish模板注释|EZPublish模板变量类型|EZPublish模板变量用法|EZPublish调查数组和对象|EZPublish模板控制结构|EZPublish函数与操作符|EZPublishURL处理|EZPublish内容提取|EZPublish模板重设系统

系统功能:

EZPublish系统记帐|EZPublish策略功能|EZPublish多语言使用

(一)|EZPublish多语言使用

(二)|EZPublish集群的使用|EZPublish安装包的使用|EZPublishCronjob脚本的使用|EZPublish多货币功能|EZPublish通知功能

其他功能:

EZPublish增值税(VAT)系统|EZPublish改进的商品配送系统|EZPublish多语言URL别名|EZPublish登录后高级重定向|EZPublish检索引擎|EZPublishWebDAV|EZPublish视图缓存

EZPublish常见问题:

EZPublish安装常见问题|EZPublish使用常见问题

EZPublish其他:

EZPublish内部结构|EZPublish内容与界面|EZPublish内容管理

(一)|EZPublish内容管理

(二)|EZPublish配置模型|EZPublish模块与视图|EZPublishURL翻译|EZPublish界面|EZPublish访问控制|EZPublish网络商店|EZPublish工作流

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 工程科技 > 兵器核科学

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1