WIKI使用導(dǎo)航
站長百科導(dǎo)航
站長專題
- 網(wǎng)站推廣
- 網(wǎng)站程序
- 網(wǎng)站賺錢
- 虛擬主機(jī)
- cPanel
- 網(wǎng)址導(dǎo)航專題
- 云計(jì)算
- 微博營銷
- 虛擬主機(jī)管理系統(tǒng)
- 開放平臺
- WIKI程序與應(yīng)用
- 美國十大主機(jī)
WordPress: WPMU Functions/get current site:修訂間差異
來自站長百科
(新頁面: {{Stub}} Returns the following items: id domain path site_name ==Usage== To get the blog id, you would use the following code: $current_site = get_current_site(); echo $curr...) |
(沒有差異)
|
2008年9月26日 (五) 14:25的版本
This page is [[WordPress::Category:Stubs|marked]] as incomplete. You can help Codex by expanding it.
Returns the following items:
id domain path site_name
Usage
To get the blog id, you would use the following code:
$current_site = get_current_site(); echo $current_site->id;
Or, to do the same, but in only one line:
echo get_current_site()->id;
Other
The function as found in footer.php of most Wordpress themes:
<?php $current_site = get_current_site(); ?>
Need content to help solve the following PHP fatal error:
Fatal error: Call to undefined function get_current_site() in /blah/www.mysite.com/wp-content/themes/blah/footer.php on line 2