Renaming Reloaded.
git-svn-id: http://svn.automattic.com/wordpress/trunk@628 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
298b53cc1e
commit
99a7358baf
|
@ -1,7 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
$curpath = dirname(__FILE__).'/';
|
$curpath = dirname(__FILE__).'/';
|
||||||
require_once ($curpath.'wp-config.php');
|
require_once ($curpath.'wp-config.php');
|
||||||
require_once ($curpath.$b2inc.'/template-functions.php');
|
require_once ($curpath.WPINC.'/template-functions.php');
|
||||||
header('HTTP/1.0 301 Moved Permanently');
|
header('HTTP/1.0 301 Moved Permanently');
|
||||||
header('Location: ' . get_bloginfo('rdf_url') . "\n");
|
header('Location: ' . get_bloginfo('rdf_url') . "\n");
|
||||||
exit;
|
exit;
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
$curpath = dirname(__FILE__).'/';
|
$curpath = dirname(__FILE__).'/';
|
||||||
require_once ($curpath.'wp-config.php');
|
require_once ($curpath.'wp-config.php');
|
||||||
require_once ($curpath.$b2inc.'/template-functions.php');
|
require_once ($curpath.WPINC.'/template-functions.php');
|
||||||
header('HTTP/1.0 301 Moved Permanently');
|
header('HTTP/1.0 301 Moved Permanently');
|
||||||
header('Location: ' . get_bloginfo('rss_url') . "\n");
|
header('Location: ' . get_bloginfo('rss_url') . "\n");
|
||||||
exit;
|
exit;
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
$curpath = dirname(__FILE__).'/';
|
$curpath = dirname(__FILE__).'/';
|
||||||
require_once ($curpath.'wp-config.php');
|
require_once ($curpath.'wp-config.php');
|
||||||
require_once ($curpath.$b2inc.'/template-functions.php');
|
require_once ($curpath.WPINC.'/template-functions.php');
|
||||||
header('HTTP/1.0 301 Moved Permanently');
|
header('HTTP/1.0 301 Moved Permanently');
|
||||||
header('Location: ' . get_bloginfo('rss2_url') . "\n");
|
header('Location: ' . get_bloginfo('rss2_url') . "\n");
|
||||||
exit;
|
exit;
|
||||||
|
|
|
@ -11,22 +11,22 @@ $wpsmarty->plugin_dir = './wp-plugins';
|
||||||
require_once( 'b2-include/class-smarty.php' );
|
require_once( 'b2-include/class-smarty.php' );
|
||||||
$blog = 1;
|
$blog = 1;
|
||||||
require_once('wp-blog-header.php');
|
require_once('wp-blog-header.php');
|
||||||
require_once($abspath.'wp-links/links.php');
|
require_once(ABSPATH.'wp-links/links.php');
|
||||||
// not on by default: require_once($abspath.'wp-links/links.weblogs.com.php');
|
// not on by default: require_once(ABSPATH.'wp-links/links.weblogs.com.php');
|
||||||
|
|
||||||
define( 'NODISPLAY', false );
|
define( 'NODISPLAY', false );
|
||||||
|
|
||||||
$wpsmarty->assign( 'siteurl', $siteurl );
|
$wpsmarty->assign( 'siteurl', $siteurl );
|
||||||
$wpsmarty->assign( 'b2_version', $b2_version );
|
$wpsmarty->assign( 'b2_version', $wp_version );
|
||||||
|
|
||||||
if($posts)
|
if($posts)
|
||||||
{
|
{
|
||||||
foreach ($posts as $post)
|
foreach ($posts as $post)
|
||||||
{
|
{
|
||||||
start_b2();
|
start_wp();
|
||||||
$content .= $wpsmarty->fetch( 'post.html' );
|
$content .= $wpsmarty->fetch( 'post.html' );
|
||||||
ob_start();
|
ob_start();
|
||||||
include($abspath . 'wp-comments.php');
|
include(ABSPATH . 'wp-comments.php');
|
||||||
$txt = ob_get_contents();
|
$txt = ob_get_contents();
|
||||||
ob_end_clean();
|
ob_end_clean();
|
||||||
$content .= $txt;
|
$content .= $txt;
|
||||||
|
|
|
@ -30,7 +30,7 @@ require_once('wp-blog-header.php');
|
||||||
<h1 id="header"><a href="<?php echo $siteurl; ?>" title="<?php bloginfo('name'); ?>"><?php bloginfo('name'); ?></a></h1>
|
<h1 id="header"><a href="<?php echo $siteurl; ?>" title="<?php bloginfo('name'); ?>"><?php bloginfo('name'); ?></a></h1>
|
||||||
|
|
||||||
<div id="content">
|
<div id="content">
|
||||||
<?php if ($posts) { foreach ($posts as $post) { start_b2(); ?>
|
<?php if ($posts) { foreach ($posts as $post) { start_wp(); ?>
|
||||||
|
|
||||||
<?php the_date('','<h2>','</h2>'); ?>
|
<?php the_date('','<h2>','</h2>'); ?>
|
||||||
|
|
||||||
|
@ -51,7 +51,7 @@ require_once('wp-blog-header.php');
|
||||||
<?php trackback_rdf(); ?>
|
<?php trackback_rdf(); ?>
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<?php include($abspath . 'wp-comments.php'); ?>
|
<?php include(ABSPATH . 'wp-comments.php'); ?>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?php } } else { // end foreach, end if any posts ?>
|
<?php } } else { // end foreach, end if any posts ?>
|
||||||
|
|
171
layout2b.css
171
layout2b.css
|
@ -1,171 +0,0 @@
|
||||||
/* Default WordPress by Matthew Mullenweg http://photomatt.net
|
|
||||||
This is just a basic layout, with only the bare minimum defined.
|
|
||||||
Please tweak this and make it your own. :)
|
|
||||||
*/
|
|
||||||
|
|
||||||
a {
|
|
||||||
color: #069;
|
|
||||||
}
|
|
||||||
|
|
||||||
a:visited {
|
|
||||||
color: #039;
|
|
||||||
}
|
|
||||||
|
|
||||||
a:hover {
|
|
||||||
color: #39c;
|
|
||||||
}
|
|
||||||
|
|
||||||
acronym, abbr {
|
|
||||||
border-bottom: 1px dashed #333;
|
|
||||||
}
|
|
||||||
|
|
||||||
acronym, abbr, span.caps {
|
|
||||||
cursor: help;
|
|
||||||
font-size: 90%;
|
|
||||||
letter-spacing: .07em;
|
|
||||||
}
|
|
||||||
|
|
||||||
blockquote {
|
|
||||||
border-left: 5px solid #ccc;
|
|
||||||
margin-left: 1.5em;
|
|
||||||
padding-left: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
body {
|
|
||||||
font-family: Georgia, "Times New Roman", Times, serif;
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
h2 {
|
|
||||||
border-bottom: 2px solid #ccc;
|
|
||||||
margin-bottom: 2px;
|
|
||||||
}
|
|
||||||
|
|
||||||
p, li {
|
|
||||||
line-height: 130%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.b2calendarcell {
|
|
||||||
color: #000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.b2calendaremptycell {
|
|
||||||
}
|
|
||||||
|
|
||||||
.b2calendarheadercell {
|
|
||||||
background: #808080;
|
|
||||||
color: #ccc;
|
|
||||||
}
|
|
||||||
|
|
||||||
.b2calendarlinkpost {
|
|
||||||
color: #f00;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.b2calendarmonth {
|
|
||||||
color: #aaa;
|
|
||||||
}
|
|
||||||
|
|
||||||
.b2calendarrow {
|
|
||||||
color: #0f0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.b2calendartable {
|
|
||||||
background: #fff;
|
|
||||||
border: 1px solid #000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.b2calendartoday {
|
|
||||||
color: #00f;
|
|
||||||
}
|
|
||||||
|
|
||||||
.credit {
|
|
||||||
font-size: 11px;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.feedback {
|
|
||||||
text-align: right;
|
|
||||||
color: #ccc;
|
|
||||||
}
|
|
||||||
|
|
||||||
.meta, .meta a {
|
|
||||||
color: #808080;
|
|
||||||
font-size: small;
|
|
||||||
}
|
|
||||||
|
|
||||||
.storytitle a {
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#content {
|
|
||||||
margin: 0 160px 0 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#header {
|
|
||||||
background-color: #808080;
|
|
||||||
margin: 0;
|
|
||||||
padding-left: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#header a {
|
|
||||||
color: #fff;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#header a:hover {
|
|
||||||
color: #ccc;
|
|
||||||
}
|
|
||||||
|
|
||||||
#menu {
|
|
||||||
background-color: #000;
|
|
||||||
border-left: 3px solid #666;
|
|
||||||
padding-bottom: 10px;
|
|
||||||
position: absolute;
|
|
||||||
right: 0;
|
|
||||||
top: 65px;
|
|
||||||
width: 150px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#menu form {
|
|
||||||
margin: 0 0 0 13px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#menu input {
|
|
||||||
background-color: #ccc;
|
|
||||||
border: 2px solid #666;
|
|
||||||
}
|
|
||||||
|
|
||||||
#menu ul {
|
|
||||||
color: #ccc;
|
|
||||||
font-variant: small-caps;
|
|
||||||
font-weight: bold;
|
|
||||||
list-style-type: none;
|
|
||||||
margin: 0;
|
|
||||||
padding-left: 3px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#menu ul ul {
|
|
||||||
font-variant: normal;
|
|
||||||
font-weight: normal;
|
|
||||||
line-height: 100%;
|
|
||||||
list-style-type: none;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
text-align: left;
|
|
||||||
}
|
|
||||||
|
|
||||||
#menu ul ul li {
|
|
||||||
line-height: 115%;
|
|
||||||
padding-left: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#menu ul ul li a {
|
|
||||||
color: #fff;
|
|
||||||
height: 13px;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#menu ul ul li a:hover {
|
|
||||||
border-bottom: 1px solid #ccc;
|
|
||||||
}
|
|
|
@ -1,6 +1,6 @@
|
||||||
|
|
||||||
|
|
||||||
<p align="center" style="width: 100%" class="tabletoprow"><strong><a href="http://wordpress.org">WordPress</a></strong> <?php echo $b2_version ?> — <a href="http://wordpress.org/support/">Support Forums</a><br />
|
<p align="center" style="width: 100%" class="tabletoprow"><strong><a href="http://wordpress.org">WordPress</a></strong> <?php echo $wp_version ?> — <a href="http://wordpress.org/support/">Support Forums</a><br />
|
||||||
<?php
|
<?php
|
||||||
echo number_format(timer_stop(), 2)." seconds";
|
echo number_format(timer_stop(), 2)." seconds";
|
||||||
?>
|
?>
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
require_once('../wp-config.php');
|
require_once('../wp-config.php');
|
||||||
require_once($abspath.'/wp-admin/auth.php');
|
require_once(ABSPATH.'/wp-admin/auth.php');
|
||||||
|
|
||||||
function gethelp_link($this_file, $helptag) {
|
function gethelp_link($this_file, $helptag) {
|
||||||
$url = 'http://wordpress.org/docs/reference/links/#'.$helptag;
|
$url = 'http://wordpress.org/docs/reference/links/#'.$helptag;
|
||||||
|
@ -29,18 +29,18 @@ $admin_area_charset = (!isset($admin_area_charset)) ? 'iso-8859-15' : $admin_are
|
||||||
if (($is_macIE) || ($is_lynx))
|
if (($is_macIE) || ($is_lynx))
|
||||||
$use_quicktags = 0;
|
$use_quicktags = 0;
|
||||||
|
|
||||||
$b2varstoreset = array('profile','standalone','redirect','redirect_url','a','popuptitle','popupurl','text', 'trackback', 'pingback');
|
$wpvarstoreset = array('profile','standalone','redirect','redirect_url','a','popuptitle','popupurl','text', 'trackback', 'pingback');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -90,8 +90,8 @@ $text = stripslashes($text);
|
||||||
/* big funky fixes for browsers' javascript bugs */
|
/* big funky fixes for browsers' javascript bugs */
|
||||||
|
|
||||||
if (($is_macIE) && (!isset($IEMac_bookmarklet_fix))) {
|
if (($is_macIE) && (!isset($IEMac_bookmarklet_fix))) {
|
||||||
$popuptitle = preg_replace($b2_macIE_correction["in"],$b2_macIE_correction["out"],$popuptitle);
|
$popuptitle = preg_replace($wp_macIE_correction["in"],$wp_macIE_correction["out"],$popuptitle);
|
||||||
$text = preg_replace($b2_macIE_correction["in"],$b2_macIE_correction["out"],$text);
|
$text = preg_replace($wp_macIE_correction["in"],$wp_macIE_correction["out"],$text);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (($is_winIE) && (!isset($IEWin_bookmarklet_fix))) {
|
if (($is_winIE) && (!isset($IEWin_bookmarklet_fix))) {
|
||||||
|
@ -100,8 +100,8 @@ if (($is_winIE) && (!isset($IEWin_bookmarklet_fix))) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (($is_gecko) && (!isset($Gecko_bookmarklet_fix))) {
|
if (($is_gecko) && (!isset($Gecko_bookmarklet_fix))) {
|
||||||
$popuptitle = preg_replace($b2_gecko_correction["in"],$b2_gecko_correction["out"],$popuptitle);
|
$popuptitle = preg_replace($wp_gecko_correction["in"],$wp_gecko_correction["out"],$popuptitle);
|
||||||
$text = preg_replace($b2_gecko_correction["in"],$b2_gecko_correction["out"],$text);
|
$text = preg_replace($wp_gecko_correction["in"],$wp_gecko_correction["out"],$text);
|
||||||
}
|
}
|
||||||
|
|
||||||
$post_title = $_REQUEST['post_title'];
|
$post_title = $_REQUEST['post_title'];
|
||||||
|
|
|
@ -19,18 +19,18 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action','standalone','cat');
|
$wpvarstoreset = array('action','standalone','cat');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -234,12 +234,12 @@ echo $posts_nav_bar;
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
// these lines are b2's "motor", do not alter nor remove them
|
// these lines are b2's "motor", do not alter nor remove them
|
||||||
include($abspath.'wp-blog-header.php');
|
include(ABSPATH.'wp-blog-header.php');
|
||||||
|
|
||||||
if ($posts) {
|
if ($posts) {
|
||||||
foreach ($posts as $post) {
|
foreach ($posts as $post) {
|
||||||
//$posts_per_page = 10;
|
//$posts_per_page = 10;
|
||||||
start_b2(); ?>
|
start_wp(); ?>
|
||||||
<p>
|
<p>
|
||||||
<strong><?php the_time('Y/m/d @ H:i:s'); ?></strong> [ <a href="post.php?p=<?php echo $id ?>&c=1"><?php comments_number('no comments', '1 comment', "% comments", true) ?></a>
|
<strong><?php the_time('Y/m/d @ H:i:s'); ?></strong> [ <a href="post.php?p=<?php echo $id ?>&c=1"><?php comments_number('no comments', '1 comment', "% comments", true) ?></a>
|
||||||
<?php
|
<?php
|
||||||
|
|
|
@ -233,10 +233,10 @@ echo $posts_nav_bar;
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
include($abspath.'wp-blog-header.php');
|
include(ABSPATH.'wp-blog-header.php');
|
||||||
|
|
||||||
if ($posts) {
|
if ($posts) {
|
||||||
foreach ($posts as $post) { start_b2();
|
foreach ($posts as $post) { start_wp();
|
||||||
?>
|
?>
|
||||||
<p>
|
<p>
|
||||||
<strong><?php the_time('Y/m/d @ H:i:s'); ?></strong> [ <a href="edit.php?p=<?php echo $id ?>&c=1"><?php comments_number('no comments', '1 comment', "% comments", true) ?></a>
|
<strong><?php the_time('Y/m/d @ H:i:s'); ?></strong> [ <a href="edit.php?p=<?php echo $id ?>&c=1"><?php comments_number('no comments', '1 comment', "% comments", true) ?></a>
|
||||||
|
|
|
@ -1,17 +1,17 @@
|
||||||
<?php // rename this to blogger-2-b2.php
|
<?php // rename this to blogger-2-b2.php
|
||||||
|
|
||||||
$b2varstoreset = array('action');
|
$wpvarstoreset = array('action');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -21,9 +21,9 @@ switch ($action) {
|
||||||
case "step1":
|
case "step1":
|
||||||
|
|
||||||
require_once('../wp-config.php');
|
require_once('../wp-config.php');
|
||||||
require_once($abspath.$b2inc.'/template-functions.php');
|
require_once(ABSPATH.WPINC.'/template-functions.php');
|
||||||
require_once($abspath.$b2inc.'/functions.php');
|
require_once(ABSPATH.WPINC.'/functions.php');
|
||||||
require_once($abspath.$b2inc.'/vars.php');
|
require_once(ABSPATH.WPINC.'/vars.php');
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||||
|
|
|
@ -5,20 +5,20 @@
|
||||||
// 3. load in the browser from there
|
// 3. load in the browser from there
|
||||||
|
|
||||||
require_once('wp-config.php');
|
require_once('wp-config.php');
|
||||||
require_once($abspath.$b2inc.'/functions.php');
|
require_once(ABSPATH.WPINC.'/functions.php');
|
||||||
|
|
||||||
$b2varstoreset = array('action', 'gmpath', 'archivespath');
|
$wpvarstoreset = array('action', 'gmpath', 'archivespath');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,18 +7,18 @@ $title = 'Link Categories';
|
||||||
$this_file='link-categories.php';
|
$this_file='link-categories.php';
|
||||||
$parent_file = 'link-manager.php';
|
$parent_file = 'link-manager.php';
|
||||||
|
|
||||||
$b2varstoreset = array('action','standalone','cat', 'auto_toggle');
|
$wpvarstoreset = array('action','standalone','cat', 'auto_toggle');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,21 +41,21 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action','standalone','cat_id', 'linkurl', 'name', 'image',
|
$wpvarstoreset = array('action','standalone','cat_id', 'linkurl', 'name', 'image',
|
||||||
'description', 'visible', 'target', 'category', 'link_id',
|
'description', 'visible', 'target', 'category', 'link_id',
|
||||||
'submit', 'order_by', 'links_show_cat_id', 'rating', 'rel',
|
'submit', 'order_by', 'links_show_cat_id', 'rating', 'rel',
|
||||||
'notes', 'linkcheck[]');
|
'notes', 'linkcheck[]');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
require_once('../wp-config.php');
|
require_once('../wp-config.php');
|
||||||
require_once($abspath.$b2inc.'/functions.php');
|
require_once(ABSPATH.WPINC.'/functions.php');
|
||||||
|
|
||||||
// columns we wish to find are: link_url, link_name, link_target, link_description
|
// columns we wish to find are: link_url, link_name, link_target, link_description
|
||||||
// we need to map XML attribute names to our columns
|
// we need to map XML attribute names to our columns
|
||||||
|
|
|
@ -20,18 +20,18 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action','item_ignored','item_deleted','item_approved');
|
$wpvarstoreset = array('action','item_ignored','item_deleted','item_approved');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,18 +19,18 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action','standalone', 'option_group_id');
|
$wpvarstoreset = array('action','standalone', 'option_group_id');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,18 +19,18 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action','standalone', 'option_group_id');
|
$wpvarstoreset = array('action','standalone', 'option_group_id');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,19 +18,19 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action', 'safe_mode', 'withcomments', 'c', 'posts', 'poststart', 'postend', 'content', 'edited_post_title', 'comment_error', 'profile', 'trackback_url', 'excerpt', 'showcomments', 'commentstart', 'commentend', 'commentorder');
|
$wpvarstoreset = array('action', 'safe_mode', 'withcomments', 'c', 'posts', 'poststart', 'postend', 'content', 'edited_post_title', 'comment_error', 'profile', 'trackback_url', 'excerpt', 'showcomments', 'commentstart', 'commentend', 'commentorder');
|
||||||
|
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,24 +18,24 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action','standalone','redirect','profile','user');
|
$wpvarstoreset = array('action','standalone','redirect','profile','user');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
require_once('../wp-config.php');
|
require_once('../wp-config.php');
|
||||||
require_once($abspath.$b2inc.'/functions.php');
|
require_once(ABSPATH.WPINC.'/functions.php');
|
||||||
|
|
||||||
switch($action) {
|
switch($action) {
|
||||||
|
|
||||||
|
|
|
@ -18,18 +18,18 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action','standalone','redirect','profile','error','warning','a','file');
|
$wpvarstoreset = array('action','standalone','redirect','profile','error','warning','a','file');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,7 +15,7 @@ $allowed_types = explode(" ", trim($fileupload_allowedtypes));
|
||||||
?><html>
|
?><html>
|
||||||
<head>
|
<head>
|
||||||
<title>WordPress :: upload images/files</title>
|
<title>WordPress :: upload images/files</title>
|
||||||
<link rel="stylesheet" href="<?php echo $b2inc; ?>/b2.css" type="text/css">
|
<link rel="stylesheet" href="<?php echo WPINC; ?>/b2.css" type="text/css">
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
<!--
|
<!--
|
||||||
body {
|
body {
|
||||||
|
|
|
@ -2,18 +2,18 @@
|
||||||
$title = 'Users';
|
$title = 'Users';
|
||||||
/* <Team> */
|
/* <Team> */
|
||||||
|
|
||||||
$b2varstoreset = array('action','standalone','redirect','profile');
|
$wpvarstoreset = array('action','standalone','redirect','profile');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,19 +11,19 @@ if (!file_exists($curpath . '/wp-config.php'))
|
||||||
|
|
||||||
require_once ($curpath.'/wp-config.php');
|
require_once ($curpath.'/wp-config.php');
|
||||||
|
|
||||||
$b2varstoreset = array('m','p','posts','w','c', 'cat','withcomments','s','search','exact', 'sentence','poststart','postend','preview','debug', 'calendar','page','paged','more','tb', 'pb','author','order','orderby', 'year', 'monthnum', 'day', 'name', 'category_name');
|
$wpvarstoreset = array('m','p','posts','w','c', 'cat','withcomments','s','search','exact', 'sentence','poststart','postend','preview','debug', 'calendar','page','paged','more','tb', 'pb','author','order','orderby', 'year', 'monthnum', 'day', 'name', 'category_name');
|
||||||
|
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS[$b2var])) {
|
if (empty($HTTP_POST_VARS[$wpvar])) {
|
||||||
if (empty($HTTP_GET_VARS[$b2var])) {
|
if (empty($HTTP_GET_VARS[$wpvar])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS[$b2var];
|
$$wpvar = $HTTP_GET_VARS[$wpvar];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS[$b2var];
|
$$wpvar = $HTTP_POST_VARS[$wpvar];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
$blog = 1;
|
$blog = 1;
|
||||||
require ('wp-blog-header.php');
|
require ('wp-blog-header.php');
|
||||||
add_filter('comment_text', 'popuplinks');
|
add_filter('comment_text', 'popuplinks');
|
||||||
foreach ($posts as $post) { start_b2();
|
foreach ($posts as $post) { start_wp();
|
||||||
?>
|
?>
|
||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
<!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">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
|
|
|
@ -12,7 +12,7 @@ require('wp-blog-header.php');
|
||||||
if (!isset($rss_language)) { $rss_language = 'en'; }
|
if (!isset($rss_language)) { $rss_language = 'en'; }
|
||||||
echo "<?xml version=\"1.0\"?".">";
|
echo "<?xml version=\"1.0\"?".">";
|
||||||
?>
|
?>
|
||||||
<!-- generator="wordpress/<?php echo $b2_version ?>" -->
|
<!-- generator="wordpress/<?php echo $wp_version ?>" -->
|
||||||
<rss version="2.0"
|
<rss version="2.0"
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||||
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
|
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
|
||||||
|
@ -22,7 +22,7 @@ echo "<?xml version=\"1.0\"?".">";
|
||||||
<channel>
|
<channel>
|
||||||
<?php
|
<?php
|
||||||
$i = 0;
|
$i = 0;
|
||||||
foreach ($posts as $post) { start_b2();
|
foreach ($posts as $post) { start_wp();
|
||||||
if ($i < 1) {
|
if ($i < 1) {
|
||||||
$i++;
|
$i++;
|
||||||
?>
|
?>
|
||||||
|
@ -33,7 +33,7 @@ foreach ($posts as $post) { start_b2();
|
||||||
<dc:creator><?php echo antispambot($admin_email) ?></dc:creator>
|
<dc:creator><?php echo antispambot($admin_email) ?></dc:creator>
|
||||||
<dc:rights>Copyright <?php echo mysql2date('Y', get_lastpostdate()); ?></dc:rights>
|
<dc:rights>Copyright <?php echo mysql2date('Y', get_lastpostdate()); ?></dc:rights>
|
||||||
<dc:date><?php echo gmdate('Y-m-d\TH:i:s'); ?></dc:date>
|
<dc:date><?php echo gmdate('Y-m-d\TH:i:s'); ?></dc:date>
|
||||||
<admin:generatorAgent rdf:resource="http://wordpress.org/?v=<?php echo $b2_version ?>"/>
|
<admin:generatorAgent rdf:resource="http://wordpress.org/?v=<?php echo $wp_version ?>"/>
|
||||||
<admin:errorReportsTo rdf:resource="mailto:<?php echo antispambot($admin_email) ?>"/>
|
<admin:errorReportsTo rdf:resource="mailto:<?php echo antispambot($admin_email) ?>"/>
|
||||||
<sy:updatePeriod>hourly</sy:updatePeriod>
|
<sy:updatePeriod>hourly</sy:updatePeriod>
|
||||||
<sy:updateFrequency>1</sy:updateFrequency>
|
<sy:updateFrequency>1</sy:updateFrequency>
|
||||||
|
|
|
@ -26,7 +26,7 @@ $month['11']='November';
|
||||||
$month['12']='December';
|
$month['12']='December';
|
||||||
|
|
||||||
// here's the conversion table, you can modify it if you know what you're doing
|
// here's the conversion table, you can modify it if you know what you're doing
|
||||||
$b2smiliestrans = array(
|
$wpsmiliestrans = array(
|
||||||
' :)' => 'icon_smile.gif',
|
' :)' => 'icon_smile.gif',
|
||||||
' :D' => 'icon_biggrin.gif',
|
' :D' => 'icon_biggrin.gif',
|
||||||
' :-D' => 'icon_biggrin.gif',
|
' :-D' => 'icon_biggrin.gif',
|
||||||
|
|
|
@ -19,8 +19,8 @@ $loginsql = DB_USER;
|
||||||
$passsql = DB_PASSWORD;
|
$passsql = DB_PASSWORD;
|
||||||
$base = DB_NAME;
|
$base = DB_NAME;
|
||||||
|
|
||||||
$abspath = dirname(__FILE__).'/';
|
define('ABSPATH', dirname(__FILE__).'/');
|
||||||
|
|
||||||
// Get everything else
|
// Get everything else
|
||||||
require_once($abspath.'wp-settings.php');
|
require_once(ABSPATH.'wp-settings.php');
|
||||||
?>
|
?>
|
|
@ -228,7 +228,7 @@ function get_weekstartend($mysqlstring, $start_of_week) {
|
||||||
|
|
||||||
function convert_chars($content,$flag='obsolete attribute left there for backwards compatibility') { // html/unicode entities output
|
function convert_chars($content,$flag='obsolete attribute left there for backwards compatibility') { // html/unicode entities output
|
||||||
|
|
||||||
global $use_htmltrans, $b2_htmltrans, $b2_htmltranswinuni;
|
global $use_htmltrans, $wp_htmltrans, $wp_htmltranswinuni;
|
||||||
|
|
||||||
// removes metadata tags
|
// removes metadata tags
|
||||||
$content = preg_replace('/<title>(.+?)<\/title>/','',$content);
|
$content = preg_replace('/<title>(.+?)<\/title>/','',$content);
|
||||||
|
@ -241,12 +241,12 @@ function convert_chars($content,$flag='obsolete attribute left there for backwar
|
||||||
|
|
||||||
// converts HTML-entities to their display values in order to convert them again later
|
// converts HTML-entities to their display values in order to convert them again later
|
||||||
$content = preg_replace('/['.chr(127).'-'.chr(255).']/e', '"&#".ord(\'\0\').";"', $content );
|
$content = preg_replace('/['.chr(127).'-'.chr(255).']/e', '"&#".ord(\'\0\').";"', $content );
|
||||||
$content = strtr($content, $b2_htmltrans);
|
$content = strtr($content, $wp_htmltrans);
|
||||||
|
|
||||||
// now converting: Windows CP1252 => Unicode (valid HTML)
|
// now converting: Windows CP1252 => Unicode (valid HTML)
|
||||||
// (if you've ever pasted text from MSWord, you'll understand)
|
// (if you've ever pasted text from MSWord, you'll understand)
|
||||||
|
|
||||||
$content = strtr($content, $b2_htmltranswinuni);
|
$content = strtr($content, $wp_htmltranswinuni);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -259,9 +259,9 @@ function convert_chars($content,$flag='obsolete attribute left there for backwar
|
||||||
}
|
}
|
||||||
|
|
||||||
function convert_bbcode($content) {
|
function convert_bbcode($content) {
|
||||||
global $b2_bbcode, $use_bbcode;
|
global $wp_bbcode, $use_bbcode;
|
||||||
if ($use_bbcode) {
|
if ($use_bbcode) {
|
||||||
$content = preg_replace($b2_bbcode["in"], $b2_bbcode["out"], $content);
|
$content = preg_replace($wp_bbcode["in"], $wp_bbcode["out"], $content);
|
||||||
}
|
}
|
||||||
$content = convert_bbcode_email($content);
|
$content = convert_bbcode_email($content);
|
||||||
return $content;
|
return $content;
|
||||||
|
@ -283,16 +283,16 @@ function convert_bbcode_email($content) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function convert_gmcode($content) {
|
function convert_gmcode($content) {
|
||||||
global $b2_gmcode, $use_gmcode;
|
global $wp_gmcode, $use_gmcode;
|
||||||
if ($use_gmcode) {
|
if ($use_gmcode) {
|
||||||
$content = preg_replace($b2_gmcode["in"], $b2_gmcode["out"], $content);
|
$content = preg_replace($wp_gmcode["in"], $wp_gmcode["out"], $content);
|
||||||
}
|
}
|
||||||
return $content;
|
return $content;
|
||||||
}
|
}
|
||||||
|
|
||||||
function convert_smilies($text) {
|
function convert_smilies($text) {
|
||||||
global $smilies_directory, $use_smilies;
|
global $smilies_directory, $use_smilies;
|
||||||
global $b2_smiliessearch, $b2_smiliesreplace;
|
global $wp_smiliessearch, $wp_smiliesreplace;
|
||||||
$output = '';
|
$output = '';
|
||||||
if ($use_smilies) {
|
if ($use_smilies) {
|
||||||
// HTML loop taken from texturize function, could possible be consolidated
|
// HTML loop taken from texturize function, could possible be consolidated
|
||||||
|
@ -301,7 +301,7 @@ function convert_smilies($text) {
|
||||||
for ($i = 0; $i < $stop; $i++) {
|
for ($i = 0; $i < $stop; $i++) {
|
||||||
$content = $textarr[$i];
|
$content = $textarr[$i];
|
||||||
if ((strlen($content) > 0) && ('<' != $content{0})) { // If it's not a tag
|
if ((strlen($content) > 0) && ('<' != $content{0})) { // If it's not a tag
|
||||||
$content = str_replace($b2_smiliessearch, $b2_smiliesreplace, $content);
|
$content = str_replace($wp_smiliessearch, $wp_smiliesreplace, $content);
|
||||||
}
|
}
|
||||||
$output .= $content;
|
$output .= $content;
|
||||||
}
|
}
|
||||||
|
@ -1030,7 +1030,7 @@ function debug_fclose($fp) {
|
||||||
|
|
||||||
function pingback($content, $post_ID) {
|
function pingback($content, $post_ID) {
|
||||||
// original code by Mort (http://mort.mine.nu:8080)
|
// original code by Mort (http://mort.mine.nu:8080)
|
||||||
global $siteurl, $blogfilename, $b2_version;
|
global $siteurl, $blogfilename, $wp_version;
|
||||||
$log = debug_fopen('./pingback.log', 'a');
|
$log = debug_fopen('./pingback.log', 'a');
|
||||||
$post_links = array();
|
$post_links = array();
|
||||||
debug_fwrite($log, 'BEGIN '.time()."\n");
|
debug_fwrite($log, 'BEGIN '.time()."\n");
|
||||||
|
@ -1099,7 +1099,7 @@ function pingback($content, $post_ID) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Send the GET request
|
// Send the GET request
|
||||||
$request = "GET $path HTTP/1.1\r\nHost: $host\r\nUser-Agent: b2/$b2_version PHP/" . phpversion() . "\r\n\r\n";
|
$request = "GET $path HTTP/1.1\r\nHost: $host\r\nUser-Agent: b2/$wp_version PHP/" . phpversion() . "\r\n\r\n";
|
||||||
ob_end_flush();
|
ob_end_flush();
|
||||||
fputs($fp, $request);
|
fputs($fp, $request);
|
||||||
|
|
||||||
|
@ -1553,7 +1553,7 @@ if (!function_exists('in_array')) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function start_b2() {
|
function start_wp() {
|
||||||
global $post, $id, $postdata, $authordata, $day, $preview, $page, $pages, $multipage, $more, $numpages;
|
global $post, $id, $postdata, $authordata, $day, $preview, $page, $pages, $multipage, $more, $numpages;
|
||||||
global $preview_userid,$preview_date,$preview_content,$preview_title,$preview_category,$preview_notify,$preview_make_clickable,$preview_autobr;
|
global $preview_userid,$preview_date,$preview_content,$preview_title,$preview_category,$preview_notify,$preview_make_clickable,$preview_autobr;
|
||||||
global $pagenow;
|
global $pagenow;
|
||||||
|
@ -1609,18 +1609,18 @@ function is_new_day() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function apply_filters($tag, $string) {
|
function apply_filters($tag, $string) {
|
||||||
global $b2_filter;
|
global $wp_filter;
|
||||||
if (isset($b2_filter['all'])) {
|
if (isset($wp_filter['all'])) {
|
||||||
$b2_filter['all'] = (is_string($b2_filter['all'])) ? array($b2_filter['all']) : $b2_filter['all'];
|
$wp_filter['all'] = (is_string($wp_filter['all'])) ? array($wp_filter['all']) : $wp_filter['all'];
|
||||||
if (isset($b2_filter[$tag]))
|
if (isset($wp_filter[$tag]))
|
||||||
$b2_filter[$tag] = array_merge($b2_filter['all'], $b2_filter[$tag]);
|
$wp_filter[$tag] = array_merge($wp_filter['all'], $wp_filter[$tag]);
|
||||||
else
|
else
|
||||||
$b2_filter[$tag] = array_merge($b2_filter['all'], array());
|
$wp_filter[$tag] = array_merge($wp_filter['all'], array());
|
||||||
$b2_filter[$tag] = array_unique($b2_filter[$tag]);
|
$wp_filter[$tag] = array_unique($wp_filter[$tag]);
|
||||||
}
|
}
|
||||||
if (isset($b2_filter[$tag])) {
|
if (isset($wp_filter[$tag])) {
|
||||||
$b2_filter[$tag] = (is_string($b2_filter[$tag])) ? array($b2_filter[$tag]) : $b2_filter[$tag];
|
$wp_filter[$tag] = (is_string($wp_filter[$tag])) ? array($wp_filter[$tag]) : $wp_filter[$tag];
|
||||||
$functions = $b2_filter[$tag];
|
$functions = $wp_filter[$tag];
|
||||||
foreach($functions as $function) {
|
foreach($functions as $function) {
|
||||||
//error_log("apply_filters #1 applying filter $function");
|
//error_log("apply_filters #1 applying filter $function");
|
||||||
$string = $function($string);
|
$string = $function($string);
|
||||||
|
@ -1630,9 +1630,9 @@ function apply_filters($tag, $string) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function add_filter($tag, $function_to_add) {
|
function add_filter($tag, $function_to_add) {
|
||||||
global $b2_filter;
|
global $wp_filter;
|
||||||
if (isset($b2_filter[$tag])) {
|
if (isset($wp_filter[$tag])) {
|
||||||
$functions = $b2_filter[$tag];
|
$functions = $wp_filter[$tag];
|
||||||
if (is_array($functions)) {
|
if (is_array($functions)) {
|
||||||
foreach($functions as $function) {
|
foreach($functions as $function) {
|
||||||
$new_functions[] = $function;
|
$new_functions[] = $function;
|
||||||
|
@ -1644,25 +1644,25 @@ function add_filter($tag, $function_to_add) {
|
||||||
for no apparent reason
|
for no apparent reason
|
||||||
if (is_array($function_to_add)) {
|
if (is_array($function_to_add)) {
|
||||||
foreach($function_to_add as $function) {
|
foreach($function_to_add as $function) {
|
||||||
if (!in_array($function, $b2_filter[$tag])) {
|
if (!in_array($function, $wp_filter[$tag])) {
|
||||||
$new_functions[] = $function;
|
$new_functions[] = $function;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else */if (is_string($function_to_add)) {
|
} else */if (is_string($function_to_add)) {
|
||||||
if (!@in_array($function_to_add, $b2_filter[$tag])) {
|
if (!@in_array($function_to_add, $wp_filter[$tag])) {
|
||||||
$new_functions[] = $function_to_add;
|
$new_functions[] = $function_to_add;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$b2_filter[$tag] = $new_functions;
|
$wp_filter[$tag] = $new_functions;
|
||||||
} else {
|
} else {
|
||||||
$b2_filter[$tag] = array($function_to_add);
|
$wp_filter[$tag] = array($function_to_add);
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check for hacks file if the option is enabled
|
// Check for hacks file if the option is enabled
|
||||||
if (get_settings('hack_file')) {
|
if (get_settings('hack_file')) {
|
||||||
if (file_exists($abspath . '/my-hacks.php'))
|
if (file_exists(ABSPATH . '/my-hacks.php'))
|
||||||
require($abspath . '/my-hacks.php');
|
require(ABSPATH . '/my-hacks.php');
|
||||||
}
|
}
|
||||||
?>
|
?>
|
|
@ -1464,15 +1464,15 @@ function comments_link($file='', $echo=true) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function comments_popup_script($width=400, $height=400, $file='wp-comments-popup.php') {
|
function comments_popup_script($width=400, $height=400, $file='wp-comments-popup.php') {
|
||||||
global $b2commentspopupfile, $b2trackbackpopupfile, $b2pingbackpopupfile, $b2commentsjavascript;
|
global $wpcommentspopupfile, $wptrackbackpopupfile, $wppingbackpopupfile, $wpcommentsjavascript;
|
||||||
$b2commentspopupfile = $file;
|
$wpcommentspopupfile = $file;
|
||||||
$b2commentsjavascript = 1;
|
$wpcommentsjavascript = 1;
|
||||||
$javascript = "<script type='text/javascript'>\nfunction wpopen (macagna) {\n window.open(macagna, '_blank', 'width=$width,height=$height,scrollbars=yes,status=yes');\n}\n</script>\n";
|
$javascript = "<script type='text/javascript'>\nfunction wpopen (macagna) {\n window.open(macagna, '_blank', 'width=$width,height=$height,scrollbars=yes,status=yes');\n}\n</script>\n";
|
||||||
echo $javascript;
|
echo $javascript;
|
||||||
}
|
}
|
||||||
|
|
||||||
function comments_popup_link($zero='No Comments', $one='1 Comment', $more='% Comments', $CSSclass='', $none='Comments Off') {
|
function comments_popup_link($zero='No Comments', $one='1 Comment', $more='% Comments', $CSSclass='', $none='Comments Off') {
|
||||||
global $id, $b2commentspopupfile, $b2commentsjavascript, $post, $wpdb, $tablecomments, $HTTP_COOKIE_VARS, $cookiehash;
|
global $id, $wpcommentspopupfile, $wpcommentsjavascript, $post, $wpdb, $tablecomments, $HTTP_COOKIE_VARS, $cookiehash;
|
||||||
global $querystring_start, $querystring_equal, $querystring_separator, $siteurl;
|
global $querystring_start, $querystring_equal, $querystring_separator, $siteurl;
|
||||||
$number = $wpdb->get_var("SELECT COUNT(*) FROM $tablecomments WHERE comment_post_ID = $id AND comment_approved = '1'");
|
$number = $wpdb->get_var("SELECT COUNT(*) FROM $tablecomments WHERE comment_post_ID = $id AND comment_approved = '1'");
|
||||||
if (0 == $number && 'closed' == $post->comment_status) {
|
if (0 == $number && 'closed' == $post->comment_status) {
|
||||||
|
@ -1486,8 +1486,8 @@ function comments_popup_link($zero='No Comments', $one='1 Comment', $more='% Com
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
echo '<a href="';
|
echo '<a href="';
|
||||||
if ($b2commentsjavascript) {
|
if ($wpcommentsjavascript) {
|
||||||
echo $b2commentspopupfile.$querystring_start.'p'.$querystring_equal.$id.$querystring_separator.'c'.$querystring_equal.'1';
|
echo $wpcommentspopupfile.$querystring_start.'p'.$querystring_equal.$id.$querystring_separator.'c'.$querystring_equal.'1';
|
||||||
//echo get_permalink();
|
//echo get_permalink();
|
||||||
echo '" onclick="wpopen(this.href); return false"';
|
echo '" onclick="wpopen(this.href); return false"';
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -3,10 +3,10 @@
|
||||||
/* This file sets various arrays and variables for use in b2 */
|
/* This file sets various arrays and variables for use in b2 */
|
||||||
|
|
||||||
#b2 version
|
#b2 version
|
||||||
$b2_version = '0.80';
|
$wp_version = '0.80';
|
||||||
|
|
||||||
#BBcode search and replace arrays
|
#BBcode search and replace arrays
|
||||||
$b2_bbcode['in'] = array(
|
$wp_bbcode['in'] = array(
|
||||||
'#\[b](.+?)\[/b]#is', // Formatting tags
|
'#\[b](.+?)\[/b]#is', // Formatting tags
|
||||||
'#\[i](.+?)\[/i]#is',
|
'#\[i](.+?)\[/i]#is',
|
||||||
'#\[u](.+?)\[/u]#is',
|
'#\[u](.+?)\[/u]#is',
|
||||||
|
@ -20,7 +20,7 @@ $b2_bbcode['in'] = array(
|
||||||
# '#\[email](.+?)\[/email]#eis', // E-mail
|
# '#\[email](.+?)\[/email]#eis', // E-mail
|
||||||
# '#\[email=(.+?)](.+?)\[/email]#eis'
|
# '#\[email=(.+?)](.+?)\[/email]#eis'
|
||||||
);
|
);
|
||||||
$b2_bbcode['out'] = array(
|
$wp_bbcode['out'] = array(
|
||||||
'<strong>$1</strong>', // Formatting tags
|
'<strong>$1</strong>', // Formatting tags
|
||||||
'<em>$1</em>',
|
'<em>$1</em>',
|
||||||
'<span style="text-decoration:underline">$1</span>',
|
'<span style="text-decoration:underline">$1</span>',
|
||||||
|
@ -36,22 +36,22 @@ $b2_bbcode['out'] = array(
|
||||||
);
|
);
|
||||||
|
|
||||||
#GreyMatter formatting search and replace arrays
|
#GreyMatter formatting search and replace arrays
|
||||||
$b2_gmcode['in'] = array(
|
$wp_gmcode['in'] = array(
|
||||||
'#\\*\*(.+?)\\*\*#is', // **bold**
|
'#\\*\*(.+?)\\*\*#is', // **bold**
|
||||||
'#\\\\(.+?)\\\\#is', // \\italic\\
|
'#\\\\(.+?)\\\\#is', // \\italic\\
|
||||||
'#\__(.+?)\__#is' // __underline__
|
'#\__(.+?)\__#is' // __underline__
|
||||||
);
|
);
|
||||||
$b2_gmcode['out'] = array(
|
$wp_gmcode['out'] = array(
|
||||||
'<strong>$1</strong>',
|
'<strong>$1</strong>',
|
||||||
'<em>$1</em>',
|
'<em>$1</em>',
|
||||||
'<span style="text-decoration:underline">$1</span>'
|
'<span style="text-decoration:underline">$1</span>'
|
||||||
);
|
);
|
||||||
|
|
||||||
#Translation of HTML entities and special characters
|
#Translation of HTML entities and special characters
|
||||||
$b2_htmltrans = array_flip(get_html_translation_table(HTML_ENTITIES));
|
$wp_htmltrans = array_flip(get_html_translation_table(HTML_ENTITIES));
|
||||||
$b2_htmltrans['<'] = '<'; # preserve HTML
|
$wp_htmltrans['<'] = '<'; # preserve HTML
|
||||||
$b2_htmltrans['>'] = '>'; # preserve HTML
|
$wp_htmltrans['>'] = '>'; # preserve HTML
|
||||||
$b2_htmltransbis = array(
|
$wp_htmltransbis = array(
|
||||||
'–' => '–',
|
'–' => '–',
|
||||||
'—' => '—',
|
'—' => '—',
|
||||||
'‘' => '‘',
|
'‘' => '‘',
|
||||||
|
@ -95,10 +95,10 @@ $b2_htmltransbis = array(
|
||||||
'⊇' => '⊇', '⊕' => '⊕', '⊗' => '⊗', '⊥' => '⊥', '⋅' => '⋅', '⌈' => '⌈', '⌉' => '⌉', '⌊' => '⌊', '⌋' => '⌋', '⟨' => '〈',
|
'⊇' => '⊇', '⊕' => '⊕', '⊗' => '⊗', '⊥' => '⊥', '⋅' => '⋅', '⌈' => '⌈', '⌉' => '⌉', '⌊' => '⌊', '⌋' => '⌋', '⟨' => '〈',
|
||||||
'⟩' => '〉', '◊' => '◊', '♠' => '♠', '♣' => '♣', '♥' => '♥', '♦' => '♦'
|
'⟩' => '〉', '◊' => '◊', '♠' => '♠', '♣' => '♣', '♥' => '♥', '♦' => '♦'
|
||||||
);
|
);
|
||||||
$b2_htmltrans = array_merge($b2_htmltrans,$b2_htmltransbis);
|
$wp_htmltrans = array_merge($wp_htmltrans,$wp_htmltransbis);
|
||||||
|
|
||||||
#Translation of invalid Unicode references range to valid range
|
#Translation of invalid Unicode references range to valid range
|
||||||
$b2_htmltranswinuni = array(
|
$wp_htmltranswinuni = array(
|
||||||
'€' => '€', // the Euro sign
|
'€' => '€', // the Euro sign
|
||||||
'' => '',
|
'' => '',
|
||||||
'‚' => '‚', // these are Windows CP1252 specific characters
|
'‚' => '‚', // these are Windows CP1252 specific characters
|
||||||
|
@ -164,28 +164,28 @@ if (preg_match('/Lynx/', $HTTP_USER_AGENT)) {
|
||||||
$is_IE = (($is_macIE) || ($is_winIE));
|
$is_IE = (($is_macIE) || ($is_winIE));
|
||||||
|
|
||||||
# browser-specific javascript corrections
|
# browser-specific javascript corrections
|
||||||
$b2_macIE_correction['in'] = array(
|
$wp_macIE_correction['in'] = array(
|
||||||
'/\%uFFD4/', '/\%uFFD5/', '/\%uFFD2/', '/\%uFFD3/',
|
'/\%uFFD4/', '/\%uFFD5/', '/\%uFFD2/', '/\%uFFD3/',
|
||||||
'/\%uFFA5/', '/\%uFFD0/', '/\%uFFD1/', '/\%uFFBD/',
|
'/\%uFFA5/', '/\%uFFD0/', '/\%uFFD1/', '/\%uFFBD/',
|
||||||
'/\%uFF83%uFFC0/', '/\%uFF83%uFFC1/', '/\%uFF83%uFFC6/', '/\%uFF83%uFFC9/',
|
'/\%uFF83%uFFC0/', '/\%uFF83%uFFC1/', '/\%uFF83%uFFC6/', '/\%uFF83%uFFC9/',
|
||||||
'/\%uFFB9/', '/\%uFF81%uFF8C/', '/\%uFF81%uFF8D/', '/\%uFF81%uFFDA/',
|
'/\%uFFB9/', '/\%uFF81%uFF8C/', '/\%uFF81%uFF8D/', '/\%uFF81%uFFDA/',
|
||||||
'/\%uFFDB/'
|
'/\%uFFDB/'
|
||||||
);
|
);
|
||||||
$b2_macIE_correction['out'] = array(
|
$wp_macIE_correction['out'] = array(
|
||||||
'‘', '’', '“', '”',
|
'‘', '’', '“', '”',
|
||||||
'•', '–', '—', 'Ω',
|
'•', '–', '—', 'Ω',
|
||||||
'β', 'γ', 'θ', 'λ',
|
'β', 'γ', 'θ', 'λ',
|
||||||
'π', '′', '″', '∠',
|
'π', '′', '″', '∠',
|
||||||
'€'
|
'€'
|
||||||
);
|
);
|
||||||
$b2_gecko_correction['in'] = array(
|
$wp_gecko_correction['in'] = array(
|
||||||
'/\‘/', '/\’/', '/\“/', '/\â€<C3A2>/',
|
'/\‘/', '/\’/', '/\“/', '/\â€<C3A2>/',
|
||||||
'/\•/', '/\–/', '/\—/', '/\Ω/',
|
'/\•/', '/\–/', '/\—/', '/\Ω/',
|
||||||
'/\β/', '/\γ/', '/\θ/', '/\λ/',
|
'/\β/', '/\γ/', '/\θ/', '/\λ/',
|
||||||
'/\Ï€/', '/\′/', '/\″/', '/\âˆ/',
|
'/\Ï€/', '/\′/', '/\″/', '/\âˆ/',
|
||||||
'/\€/', '/\ /'
|
'/\€/', '/\ /'
|
||||||
);
|
);
|
||||||
$b2_gecko_correction['out'] = array(
|
$wp_gecko_correction['out'] = array(
|
||||||
'&8216;', '’', '“', '”',
|
'&8216;', '’', '“', '”',
|
||||||
'•', '–', '—', 'Ω',
|
'•', '–', '—', 'Ω',
|
||||||
'β', 'γ', 'θ', 'λ',
|
'β', 'γ', 'θ', 'λ',
|
||||||
|
@ -198,8 +198,8 @@ $is_Apache = strstr($HTTP_SERVER_VARS['SERVER_SOFTWARE'], 'Apache') ? 1 : 0;
|
||||||
$is_IIS = strstr($HTTP_SERVER_VARS['SERVER_SOFTWARE'], 'Microsoft-IIS') ? 1 : 0;
|
$is_IIS = strstr($HTTP_SERVER_VARS['SERVER_SOFTWARE'], 'Microsoft-IIS') ? 1 : 0;
|
||||||
|
|
||||||
# if the config file does not provide the smilies array, let's define it here
|
# if the config file does not provide the smilies array, let's define it here
|
||||||
if (!isset($b2smiliestrans)) {
|
if (!isset($wpsmiliestrans)) {
|
||||||
$b2smiliestrans = array(
|
$wpsmiliestrans = array(
|
||||||
' :)' => 'icon_smile.gif',
|
' :)' => 'icon_smile.gif',
|
||||||
' :D' => 'icon_biggrin.gif',
|
' :D' => 'icon_biggrin.gif',
|
||||||
' :-D' => 'icon_biggrin.gif',
|
' :-D' => 'icon_biggrin.gif',
|
||||||
|
@ -257,16 +257,16 @@ if (!function_exists('smiliescmp')) {
|
||||||
return (strlen($a) > strlen($b)) ? -1 : 1;
|
return (strlen($a) > strlen($b)) ? -1 : 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
uksort($b2smiliestrans, 'smiliescmp');
|
uksort($wpsmiliestrans, 'smiliescmp');
|
||||||
|
|
||||||
# generates smilies' search & replace arrays
|
# generates smilies' search & replace arrays
|
||||||
foreach($b2smiliestrans as $smiley => $img) {
|
foreach($wpsmiliestrans as $smiley => $img) {
|
||||||
$b2_smiliessearch[] = $smiley;
|
$wp_smiliessearch[] = $smiley;
|
||||||
$smiley_masked = '';
|
$smiley_masked = '';
|
||||||
for ($i = 0; $i < strlen($smiley); $i = $i + 1) {
|
for ($i = 0; $i < strlen($smiley); $i = $i + 1) {
|
||||||
$smiley_masked .= substr($smiley, $i, 1).chr(160);
|
$smiley_masked .= substr($smiley, $i, 1).chr(160);
|
||||||
}
|
}
|
||||||
$b2_smiliesreplace[] = " <img src='$smilies_directory/$img' alt='$smiley_masked' />";
|
$wp_smiliesreplace[] = " <img src='$smilies_directory/$img' alt='$smiley_masked' />";
|
||||||
}
|
}
|
||||||
|
|
||||||
add_filter('all', 'wptexturize');
|
add_filter('all', 'wptexturize');
|
||||||
|
|
|
@ -7,7 +7,7 @@ include('wp-blog-header.php');
|
||||||
$start = count($posts)-1;
|
$start = count($posts)-1;
|
||||||
for ($i = $start; $i >= 0; $i--) {
|
for ($i = $start; $i >= 0; $i--) {
|
||||||
$post = $posts[$i];
|
$post = $posts[$i];
|
||||||
start_b2();
|
start_wp();
|
||||||
if ((get_Lon() != null) && (get_Lon > -360) && (get_Lon() < 360 )) {
|
if ((get_Lon() != null) && (get_Lon > -360) && (get_Lon() < 360 )) {
|
||||||
?>
|
?>
|
||||||
<location arrival="<?php the_date_xml() ?>">
|
<location arrival="<?php the_date_xml() ?>">
|
||||||
|
|
18
wp-login.php
18
wp-login.php
|
@ -20,19 +20,19 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action','mode','error','text','popupurl','popuptitle');
|
$wpvarstoreset = array('action','mode','error','text','popupurl','popuptitle');
|
||||||
|
|
||||||
for ($i = 0; $i < count($b2varstoreset); $i = $i + 1) {
|
for ($i = 0; $i < count($wpvarstoreset); $i = $i + 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
require(dirname(__FILE__) . '/wp-config.php');
|
require(dirname(__FILE__) . '/wp-config.php');
|
||||||
|
|
||||||
require_once($abspath.$b2inc.'/class-pop3.php');
|
require_once(ABSPATH.WPINC.'/class-pop3.php');
|
||||||
|
|
||||||
|
|
||||||
timer_start();
|
timer_start();
|
||||||
|
|
10
wp-rdf.php
10
wp-rdf.php
|
@ -20,7 +20,7 @@ add_filter('the_content', 'trim');
|
||||||
if (!isset($rss_language)) { $rss_language = 'en'; }
|
if (!isset($rss_language)) { $rss_language = 'en'; }
|
||||||
?>
|
?>
|
||||||
<?php echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?".">"; ?>
|
<?php echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?".">"; ?>
|
||||||
<!-- generator="wordpress/<?php echo $b2_version ?>" -->
|
<!-- generator="wordpress/<?php echo $wp_version ?>" -->
|
||||||
<rdf:RDF
|
<rdf:RDF
|
||||||
xmlns="http://purl.org/rss/1.0/"
|
xmlns="http://purl.org/rss/1.0/"
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||||
|
@ -36,20 +36,20 @@ if (!isset($rss_language)) { $rss_language = 'en'; }
|
||||||
<dc:language><?php echo $rss_language ?></dc:language>
|
<dc:language><?php echo $rss_language ?></dc:language>
|
||||||
<dc:date><?php echo gmdate('Y-m-d\TH:i:s'); ?></dc:date>
|
<dc:date><?php echo gmdate('Y-m-d\TH:i:s'); ?></dc:date>
|
||||||
<dc:creator><?php echo antispambot($admin_email) ?></dc:creator>
|
<dc:creator><?php echo antispambot($admin_email) ?></dc:creator>
|
||||||
<admin:generatorAgent rdf:resource="http://wordpress.org/?v=<?php echo $b2_version ?>"/>
|
<admin:generatorAgent rdf:resource="http://wordpress.org/?v=<?php echo $wp_version ?>"/>
|
||||||
<admin:errorReportsTo rdf:resource="mailto:<?php echo antispambot($admin_email) ?>"/>
|
<admin:errorReportsTo rdf:resource="mailto:<?php echo antispambot($admin_email) ?>"/>
|
||||||
<sy:updatePeriod>hourly</sy:updatePeriod>
|
<sy:updatePeriod>hourly</sy:updatePeriod>
|
||||||
<sy:updateFrequency>1</sy:updateFrequency>
|
<sy:updateFrequency>1</sy:updateFrequency>
|
||||||
<sy:updateBase>2000-01-01T12:00+00:00</sy:updateBase>
|
<sy:updateBase>2000-01-01T12:00+00:00</sy:updateBase>
|
||||||
<items>
|
<items>
|
||||||
<rdf:Seq>
|
<rdf:Seq>
|
||||||
<?php $items_count = 0; if ($posts) { foreach ($posts as $post) { start_b2(); ?>
|
<?php $items_count = 0; if ($posts) { foreach ($posts as $post) { start_wp(); ?>
|
||||||
<rdf:li rdf:resource="<?php permalink_single_rss() ?>"/>
|
<rdf:li rdf:resource="<?php permalink_single_rss() ?>"/>
|
||||||
<?php $b2_items[] = $row; $items_count++; if (($items_count == $posts_per_rss) && empty($m)) { break; } } } ?>
|
<?php $wp_items[] = $row; $items_count++; if (($items_count == $posts_per_rss) && empty($m)) { break; } } } ?>
|
||||||
</rdf:Seq>
|
</rdf:Seq>
|
||||||
</items>
|
</items>
|
||||||
</channel>
|
</channel>
|
||||||
<?php if ($posts) { foreach ($posts as $post) { start_b2(); ?>
|
<?php if ($posts) { foreach ($posts as $post) { start_wp(); ?>
|
||||||
<item rdf:about="<?php permalink_single_rss() ?>">
|
<item rdf:about="<?php permalink_single_rss() ?>">
|
||||||
<title><?php the_title_rss() ?></title>
|
<title><?php the_title_rss() ?></title>
|
||||||
<link><?php permalink_single_rss() ?></link>
|
<link><?php permalink_single_rss() ?></link>
|
||||||
|
|
|
@ -18,18 +18,18 @@ if (!get_magic_quotes_gpc()) {
|
||||||
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
$HTTP_COOKIE_VARS = add_magic_quotes($HTTP_COOKIE_VARS);
|
||||||
}
|
}
|
||||||
|
|
||||||
$b2varstoreset = array('action');
|
$wpvarstoreset = array('action');
|
||||||
for ($i=0; $i<count($b2varstoreset); $i += 1) {
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
||||||
$b2var = $b2varstoreset[$i];
|
$wpvar = $wpvarstoreset[$i];
|
||||||
if (!isset($$b2var)) {
|
if (!isset($$wpvar)) {
|
||||||
if (empty($HTTP_POST_VARS["$b2var"])) {
|
if (empty($HTTP_POST_VARS["$wpvar"])) {
|
||||||
if (empty($HTTP_GET_VARS["$b2var"])) {
|
if (empty($HTTP_GET_VARS["$wpvar"])) {
|
||||||
$$b2var = '';
|
$$wpvar = '';
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_GET_VARS["$b2var"];
|
$$wpvar = $HTTP_GET_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$$b2var = $HTTP_POST_VARS["$b2var"];
|
$$wpvar = $HTTP_POST_VARS["$wpvar"];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,7 +22,7 @@ if (!isset($rss_encoded_html)) { $rss_encoded_html = 0; }
|
||||||
if (!isset($rss_excerpt_length) || ($rss_encoded_html == 1)) { $rss_excerpt_length = 0; }
|
if (!isset($rss_excerpt_length) || ($rss_encoded_html == 1)) { $rss_excerpt_length = 0; }
|
||||||
?>
|
?>
|
||||||
<?php echo "<?xml version=\"1.0\"?".">"; ?>
|
<?php echo "<?xml version=\"1.0\"?".">"; ?>
|
||||||
<!-- generator="wordpress/<?php echo $b2_version ?>" -->
|
<!-- generator="wordpress/<?php echo $wp_version ?>" -->
|
||||||
<rss version="0.92">
|
<rss version="0.92">
|
||||||
<channel>
|
<channel>
|
||||||
<title><?php bloginfo_rss("name") ?></title>
|
<title><?php bloginfo_rss("name") ?></title>
|
||||||
|
@ -34,7 +34,7 @@ if (!isset($rss_excerpt_length) || ($rss_encoded_html == 1)) { $rss_excerpt_leng
|
||||||
<webMaster><?php echo antispambot($admin_email) ?></webMaster>
|
<webMaster><?php echo antispambot($admin_email) ?></webMaster>
|
||||||
<language><?php echo $rss_language ?></language>
|
<language><?php echo $rss_language ?></language>
|
||||||
|
|
||||||
<?php $items_count = 0; if ($posts) { foreach ($posts as $post) { start_b2(); ?>
|
<?php $items_count = 0; if ($posts) { foreach ($posts as $post) { start_wp(); ?>
|
||||||
<item>
|
<item>
|
||||||
<title><?php the_title_rss() ?></title>
|
<title><?php the_title_rss() ?></title>
|
||||||
<?php
|
<?php
|
||||||
|
|
|
@ -23,7 +23,7 @@ if (!isset($rss_encoded_html)) { $rss_encoded_html = 0; }
|
||||||
if (!isset($rss_excerpt_length) || ($rss_encoded_html == 1)) { $rss_excerpt_length = 0; }
|
if (!isset($rss_excerpt_length) || ($rss_encoded_html == 1)) { $rss_excerpt_length = 0; }
|
||||||
?>
|
?>
|
||||||
<?php echo '<?xml version="1.0"?'.'>'; ?>
|
<?php echo '<?xml version="1.0"?'.'>'; ?>
|
||||||
<!-- generator="wordpress/<?php echo $b2_version ?>" -->
|
<!-- generator="wordpress/<?php echo $wp_version ?>" -->
|
||||||
<rss version="2.0"
|
<rss version="2.0"
|
||||||
xmlns:content="http://purl.org/rss/1.0/modules/content/">
|
xmlns:content="http://purl.org/rss/1.0/modules/content/">
|
||||||
|
|
||||||
|
@ -34,9 +34,9 @@ if (!isset($rss_excerpt_length) || ($rss_encoded_html == 1)) { $rss_excerpt_leng
|
||||||
<language><?php echo $rss_language ?></language>
|
<language><?php echo $rss_language ?></language>
|
||||||
<copyright>Copyright <?php echo mysql2date('Y', get_lastpostdate()); ?></copyright>
|
<copyright>Copyright <?php echo mysql2date('Y', get_lastpostdate()); ?></copyright>
|
||||||
<pubDate><?php echo gmdate('r'); ?></pubDate>
|
<pubDate><?php echo gmdate('r'); ?></pubDate>
|
||||||
<generator>http://wordpress.org/?v=<?php echo $b2_version ?>"</generator>
|
<generator>http://wordpress.org/?v=<?php echo $wp_version ?>"</generator>
|
||||||
|
|
||||||
<?php $items_count = 0; if ($posts) { foreach ($posts as $post) { start_b2(); ?>
|
<?php $items_count = 0; if ($posts) { foreach ($posts as $post) { start_wp(); ?>
|
||||||
<item>
|
<item>
|
||||||
<title><?php the_title_rss() ?></title>
|
<title><?php the_title_rss() ?></title>
|
||||||
<link><?php permalink_single_rss() ?></link>
|
<link><?php permalink_single_rss() ?></link>
|
||||||
|
|
|
@ -19,15 +19,15 @@ $tableoptiongroups = $table_prefix . 'optiongroups';
|
||||||
$tableoptiongroup_options = $table_prefix . 'optiongroup_options';
|
$tableoptiongroup_options = $table_prefix . 'optiongroup_options';
|
||||||
|
|
||||||
// This is the name of the include directory. No "/" allowed.
|
// This is the name of the include directory. No "/" allowed.
|
||||||
$b2inc = 'wp-includes';
|
define('WPINC', 'wp-includes');
|
||||||
|
|
||||||
require ($abspath . 'wp-config-extra.php');
|
require (ABSPATH . 'wp-config-extra.php');
|
||||||
require ($abspath . $b2inc . '/wp-db.php');
|
require (ABSPATH . WPINC . '/wp-db.php');
|
||||||
require ($abspath . $b2inc . '/functions.php');
|
require (ABSPATH . WPINC . '/functions.php');
|
||||||
require ($abspath . $b2inc . '/template-functions.php');
|
require (ABSPATH . WPINC . '/template-functions.php');
|
||||||
require ($abspath . $b2inc . '/class-xmlrpc.php');
|
require (ABSPATH . WPINC . '/class-xmlrpc.php');
|
||||||
require ($abspath . $b2inc . '/class-xmlrpcs.php');
|
require (ABSPATH . WPINC . '/class-xmlrpcs.php');
|
||||||
require ($abspath . '/wp-links/links.php');
|
require (ABSPATH . '/wp-links/links.php');
|
||||||
|
|
||||||
//setup the old globals from b2config.php
|
//setup the old globals from b2config.php
|
||||||
//
|
//
|
||||||
|
@ -97,5 +97,5 @@ if (!isset($_wp_installing) || !$_wp_installing) {
|
||||||
|
|
||||||
} //end !$_wp_installing
|
} //end !$_wp_installing
|
||||||
|
|
||||||
require ($abspath . $b2inc . '/vars.php');
|
require (ABSPATH . WPINC . '/vars.php');
|
||||||
?>
|
?>
|
4
wp.php
4
wp.php
|
@ -8,7 +8,7 @@ require_once("wp-blog-header.php");
|
||||||
<title><?php bloginfo('name') ?><?php single_post_title(' :: ') ?><?php single_cat_title(' :: ') ?><?php single_month_title(' :: ') ?></title>
|
<title><?php bloginfo('name') ?><?php single_post_title(' :: ') ?><?php single_cat_title(' :: ') ?><?php single_month_title(' :: ') ?></title>
|
||||||
<!-- Change charset if needed(?) But please do not remove this metatag -->
|
<!-- Change charset if needed(?) But please do not remove this metatag -->
|
||||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||||
<meta name="generator" content="WordPress <?php $b2_version ?>" /> <!-- leave this for stats -->
|
<meta name="generator" content="WordPress <?php $wp_version ?>" /> <!-- leave this for stats -->
|
||||||
<meta http-equiv="reply-to" content="you@somewhere.zzz" />
|
<meta http-equiv="reply-to" content="you@somewhere.zzz" />
|
||||||
<link rel="alternate" type="text/xml" title="RDF" href="<?php bloginfo('rdf_url'); ?>" />
|
<link rel="alternate" type="text/xml" title="RDF" href="<?php bloginfo('rdf_url'); ?>" />
|
||||||
<link rel="alternate" type="text/xml" title="RSS" href="<?php bloginfo('rss2_url'); ?>" />
|
<link rel="alternate" type="text/xml" title="RSS" href="<?php bloginfo('rss2_url'); ?>" />
|
||||||
|
@ -18,7 +18,7 @@ require_once("wp-blog-header.php");
|
||||||
<h1 id="header"><a href="<?php echo $siteurl; ?>" title="<?php bloginfo('name'); ?>"><?php bloginfo('name'); ?></a></h1>
|
<h1 id="header"><a href="<?php echo $siteurl; ?>" title="<?php bloginfo('name'); ?>"><?php bloginfo('name'); ?></a></h1>
|
||||||
|
|
||||||
<!-- // loop start -->
|
<!-- // loop start -->
|
||||||
<?php foreach ($posts as $post) { start_b2(); ?>
|
<?php foreach ($posts as $post) { start_wp(); ?>
|
||||||
<?php the_date("d.m.y","<h2>","</h2>"); ?>
|
<?php the_date("d.m.y","<h2>","</h2>"); ?>
|
||||||
<h3 class="storytitle" id="post-<?php the_ID(); ?>"><a href="<?php echo get_permalink() ?>" rel="bookmark" title="Permanent Link: <?php the_title(); ?>"><?php the_title(); ?></a></h3>
|
<h3 class="storytitle" id="post-<?php the_ID(); ?>"><a href="<?php echo get_permalink() ?>" rel="bookmark" title="Permanent Link: <?php the_title(); ?>"><?php the_title(); ?></a></h3>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue