/* About ----- This directory contains extra files to make the 'fancy urls' feature even more fancier, by eliminating the 'index.php'-part of the URL Installation ------------ 1. Copy all files in this directory (except for index.html) to your main nucleus dir (where your index.php and action.php file are) If you have an already existing .htaccess file (most ftp-programs don't show hidden files by default, so don't start uploading it without checking your server). If you do, download that old one first, and copy the contents of the new .htaccess file (from the fancyurls folder) in your old one, and upload that... 2. Edit this file so that $CONF['Self'] points to your main directory. NOTE: this time, and only this time, the URL should NOT end in a slash 3. Also edit the $CONF['Self'] variable in your index.php, if you don't want to end up with index.php/item/1234 urls when people come via that way 4. Enable 'Fancy URLs' in the Nucleus admin area (nucleus management / edit settings) 5. Off you go! If it doesn't work: ------------------- Remove the files again (don't forget the hidden file .htaccess). Voila. */ // remember: this URL should _NOT_ end with a slash. $CONF['Self'] = 'http://www.momoso-net.com/~ms08'; ?>
2005-12-08: User Agentの変更
我が家にインターネット端末が増えました。それは先日購入したばかりのHONDA Edixに搭載されているInternaviなるインターネットを利用しVICS情報を受信したりするもの。(そのほかにもたくさん機能あり)
そんなんでこれももれずにインターネット端末なわけです。そこで実際にネットサーフィンすると通信インフラが携帯電話なので遅い!そんなこんなでこのブログページだけは快適に表示させるため、自動で携帯ページに移る仕組みを追加した。
話は長くなりましたがここでUser Agentの変更なわけです。
内容は簡単で携帯機種のられつにInternaviのAgentを追加するだけです。
InternaviのAgent:
internavi/3.003.002-> INTERNAVI/3.003.002※けろけろ日記でも採用しました。
<変更点>
<?php
$i=$_SERVER['HTTP_USER_AGENT'];
if (
preg_match("/DoCoMo\//",$i) || // i-mode
preg_match("/UP\.Browser/",$i) || // ezweb
preg_match("/ASTEL\//",$i) || // astel
preg_match("/DDIPOCKET;/",$i) || // ddipocket
preg_match("/L-mode\/\//",$i) || // l-mode
preg_match("/UP\.Browser\/[3-5]/",$i) || // ezweb
preg_match("/J-PHONE\//",$i) || // j-sky
preg_match("/PDXGW\//",$i) || // pdxgw
preg_match("/KDDI\//",$i) || // ezweb
preg_match("/INTERNAVI\//",$i)) { // internaviの部分
header("Location: http://www.momoso-net.com/~ms08/i/index.php");
exit();
}
// This file will generate and return the main page of the site
$CONF = array();
//$CONF['Self'] = 'index.php';
$CONF['Self'] = 'http://www.momoso-net.com/~ms08';
include('./config.php');
selector();
?>
これでうまくいくはず。
実際の表示画面は家族とEdixの不定期日記で後日紹介します。
Category: BLOG/Nucleus No Trackbacks