| สร้างหน้า offline page ของ Joomla เป็นแบบของเรา offline page คืออะไร offline page คือหน้าที่จะแสดงเมื่อเราตั้งค่าให้เว็บเราเป็น offline คือไม่ให้คนอื่นเข้าใช้งาน เช่นตอนที่เรากำลังอัพเกรดระบบ หรือปรับปรุง เว็บ ก็ควรตั้งค่าเว็บเราให้คนทั่วไปเจอหน้านี้ วิธี เข้าไปที่ folder template ของเรา แล้วหาไฟล์ offline.php ถ้ายังไม่มี เราสามารถสร้างขึ้นมาใหม่ หรือ copy จาก folder template/system/ ไปไว้ใน folder template ที่เราใช้เลยก็ได้ ซึ่ง Joomla จะเอาไฟล์นี้ไป แสดงผลเป็นหน้า offline ให้เราอัตโนมัต ตัวอย่างหน้า offline.php <?php // no direct access defined( '_JEXEC' ) or die( 'Restricted access' ); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $this->language; ?>" lang="<?php echo $this->language; ?>" dir="<?php echo $this->direction; ?>"> <head> <jdoc:include type="head" /> <link rel="stylesheet" href="/<?php echo $this->baseurl ?>/templates/system/css/offline.css" type="text/css" /> <?php if($this->direction == 'rtl') : ?> <link rel="stylesheet" href="/<?php echo $this->baseurl ?>/templates/system/css/offline_rtl.css" type="text/css" /> <?php endif; ?> <link rel="stylesheet" href="/<?php echo $this->baseurl ?>/templates/system/css/system.css" type="text/css" /> </head> <body> <jdoc:include type="message" /> <div id="frame"> <p> <?php echo $mainframe->getCfg('offline_message'); ?> </p> </div> </body> </html>
|
เขียนโดย joomla วันเสาร์ที่ 05 มีนาคม 2011 เวลา 00:31 น.
, phpBB3, SMF, Joomla, Wordpress, CMS CRM
, JavaScript & Jquery Ajax
, SQL - Database
, ถาม - ตอบ คอมพิวเตอร์
, PHP Knowledge
, PHP News
, HTML CSS
, Free PHP Code Download script
, Web Hosting Review - Free Host Share Host VPS