Joomla
本文实例讲述了Joomla开启SEF的方法。分享给大家供大家参考,具体如下:
使用SEF(search engine friendly)网址的主要目的是使内容的关键词出现在URL中,这也是我们常说的SEO中的一项重要内容,对于搜索引擎的来说,这样可以增强当前页面与这些关键词之间的关联度。下面我们来看看如何在Joomla 1.5中使用SEF网址。
1.安装Joomla1.5
2.在全局设置中(Global Configuration),将“搜索引擎优化网址(Search Engine Friendly URLs)”设置为“开启(Yes)”,保存设置。
这是Joomla系统中最主要的搜索引擎优化设置,所以在进行下面的步骤之前,我们首先将它开启;现在,站点的URL就是由当前页面或文章的标题别名 (Alias)构成了。如果没有为当前页面或文章设置别名,那么URL会直接使用页面或文章的标题来构成URL(Title)。
如果你遇到问题,可以尝试修改configuration.php文件中的$live_site设置。如果你的Joomla安装在站点根路径中(例 如 public_html或htdocs),那么需要将$live_site设置为“/” 或 “http://www.example.com”或 “http://example.com”。如果站点安装在子路径中,就需要将$live_site设置为“/子路径名” 或 “http://www.example.com/子路径名”或 “http://example.com/子路径名”。
如果设置成功,那么现在URL应该由:
http://www.example.com/index.php?option=com_content&view=article&id=19&Itemid=27
变为:
http://www.example.com/index.php/joomla-overview
3.在全局设置中,将“为URL添加后缀(Add suffix to URLs)”设置为“开启(Yes)”,保存设置。
这只是一个“形式上”的步骤——为URL增加.html后缀,例如将:
http://www.example.com/index.php/joomla-overview
变为:
http://www.example.com/index.php/joomla-overview.html
4.在全局设置中,将“使用Apache的mod_rewrite(Use Apache mod_rewrite)”设置为“开启(Yes)”,保存设置。
注意,要使Apache的mod_rewrite正常开启,我们需要将站点根目录中的“htaccess.txt”文件重命名为“.htaccess”。
成功开启后,下面这样的URL:
http://www.example.com/index.php/joomla-overview.html
将被改变为:
http://www.example.com/joomla-overview.html
有一点建议,就是尽量为你站点中所有的页面和文章添加别名,这样就可以比较精确的控制SEF网址了;别名尽量只使用数字与字母,通过连字号“-”进行分隔,避免特殊符号。
更多关于joomla相关内容感兴趣的读者可查看本站专题:《Yii框架入门及常用技巧总结》、《php优秀开发框架总结》、《smarty模板入门基础教程》、《ThinkPHP常用方法总结》、《php面向对象程序设计入门教程》、《php字符串(string)用法总结》、《php+mysql数据库操作入门教程》及《php常见数据库操作技巧汇总》
希望本文所述对大家基于joomla程序设计有所帮助。

Laravel simplifies handling temporary session data using its intuitive flash methods. This is perfect for displaying brief messages, alerts, or notifications within your application. Data persists only for the subsequent request by default: $request-

This is the second and final part of the series on building a React application with a Laravel back-end. In the first part of the series, we created a RESTful API using Laravel for a basic product-listing application. In this tutorial, we will be dev

The PHP Client URL (cURL) extension is a powerful tool for developers, enabling seamless interaction with remote servers and REST APIs. By leveraging libcurl, a well-respected multi-protocol file transfer library, PHP cURL facilitates efficient execution of various network protocols, including HTTP, HTTPS, and FTP. This extension offers granular control over HTTP requests, supports multiple concurrent operations, and provides built-in security features.

Laravel provides concise HTTP response simulation syntax, simplifying HTTP interaction testing. This approach significantly reduces code redundancy while making your test simulation more intuitive. The basic implementation provides a variety of response type shortcuts: use Illuminate\Support\Facades\Http; Http::fake([ 'google.com' => 'Hello World', 'github.com' => ['foo' => 'bar'], 'forge.laravel.com' =>

Do you want to provide real-time, instant solutions to your customers' most pressing problems? Live chat lets you have real-time conversations with customers and resolve their problems instantly. It allows you to provide faster service to your custom

In this article, we're going to explore the notification system in the Laravel web framework. The notification system in Laravel allows you to send notifications to users over different channels. Today, we'll discuss how you can send notifications ov

Article discusses late static binding (LSB) in PHP, introduced in PHP 5.3, allowing runtime resolution of static method calls for more flexible inheritance.Main issue: LSB vs. traditional polymorphism; LSB's practical applications and potential perfo

PHP logging is essential for monitoring and debugging web applications, as well as capturing critical events, errors, and runtime behavior. It provides valuable insights into system performance, helps identify issues, and supports faster troubleshoot


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Dreamweaver Mac version
Visual web development tools

Atom editor mac version download
The most popular open source editor

WebStorm Mac version
Useful JavaScript development tools

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft

Notepad++7.3.1
Easy-to-use and free code editor
