Version 1.3.0
This commit is contained in:
1 parent
7ef3d1712a
commit
f87d29ba65
290 files changed
+50206
-17930
No files matched your search
@@ -2,15 +2,17 @@
|
||||
|
||||
/*
|
||||
+--------------------------------------------------------------------------
|
||||
| Invision Board v1.1
|
||||
| Invision Power Board v1.3 Final
|
||||
| ========================================
|
||||
| by Matthew Mecham
|
||||
| (c) 2001,2002 Invision Power Services
|
||||
| http://www.ibforums.com
|
||||
| (c) 2001 - 2003 Invision Power Services
|
||||
| http://www.invisionpower.com
|
||||
| ========================================
|
||||
| Web: http://www.ibforums.com
|
||||
| Email: phpboards@ibforums.com
|
||||
| Licence Info: phpib-licence@ibforums.com
|
||||
| Web: http://www.invisionboard.com
|
||||
| Time: Sun, 04 Jan 2004 00:30:16 GMT
|
||||
| Release: 28e7bfb25f08ac72a789cb1b172fa185
|
||||
| Email: matt@invisionpower.com
|
||||
| Licence Info: http://www.invisionboard.com/?license
|
||||
+---------------------------------------------------------------------------
|
||||
|
|
||||
| > Skin -> Templates pop up functions
|
||||
@@ -21,7 +23,11 @@
|
||||
+--------------------------------------------------------------------------
|
||||
*/
|
||||
|
||||
|
||||
if ( ! defined( 'IN_ACP' ) )
|
||||
{
|
||||
print "<h1>Incorrect access</h1>You cannot access this file directly. If you have recently upgraded, make sure you upgraded 'admin.php'.";
|
||||
exit();
|
||||
}
|
||||
|
||||
|
||||
$idx = new ad_settings();
|
||||
@@ -32,7 +38,20 @@ class ad_settings {
|
||||
var $base_url;
|
||||
|
||||
function ad_settings() {
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
|
||||
//---------------------------------------
|
||||
// Kill globals - globals bad, Homer good.
|
||||
//---------------------------------------
|
||||
|
||||
$tmp_in = array_merge( $_GET, $_POST, $_COOKIE );
|
||||
|
||||
foreach ( $tmp_in as $k => $v )
|
||||
{
|
||||
unset($$k);
|
||||
}
|
||||
|
||||
//---------------------------------------
|
||||
|
||||
switch($IN['code'])
|
||||
{
|
||||
@@ -109,7 +128,7 @@ class ad_settings {
|
||||
|
||||
function css_search_frames()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_GET_VARS;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_GET_VARS;
|
||||
|
||||
print "<html>
|
||||
<head><title>Search</title></head>
|
||||
@@ -126,7 +145,7 @@ class ad_settings {
|
||||
|
||||
function css_preview()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_GET_VARS;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_GET_VARS;
|
||||
|
||||
//+---------------------------------------
|
||||
// GET THE TEMPLATES THAT THIS CSS USES
|
||||
@@ -232,13 +251,13 @@ class ad_settings {
|
||||
|
||||
function print_css_searchlinks()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_GET_VARS;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_GET_VARS;
|
||||
|
||||
//+---------------------------------------
|
||||
// GET THE TEMPLATES THAT THIS CSS USES
|
||||
//+---------------------------------------
|
||||
|
||||
$DB->query("SELECT tmpl_id FROM ibf_skins WHERE css_id='".$IN['id']."'");
|
||||
$DB->query("SELECT set_id FROM ibf_skins WHERE css_id='".$IN['id']."'");
|
||||
|
||||
if ( ! $set = $DB->fetch_row() )
|
||||
{
|
||||
@@ -261,11 +280,11 @@ class ad_settings {
|
||||
|
||||
//die("SELECT suid, set_id, group_name, func_name FROM ibf_skin_templates WHERE set_id='".$set['tmpl_id']."' AND section_content LIKE '%".$like."%' ORDER BY group_name");
|
||||
|
||||
$DB->query("SELECT suid, set_id, group_name, func_name FROM ibf_skin_templates WHERE set_id='".$set['tmpl_id']."' AND section_content LIKE '%".$like."%' ORDER BY group_name");
|
||||
$DB->query("SELECT suid, set_id, group_name, func_name FROM ibf_skin_templates WHERE set_id='".$set['set_id']."' AND section_content LIKE '%".$like."%' ORDER BY group_name");
|
||||
|
||||
if (! $DB->get_num_rows() )
|
||||
{
|
||||
$this->do_message("No matches for that string");
|
||||
$this->do_message("No matches for that string in template set ID {$set['set_id']}");
|
||||
}
|
||||
|
||||
$results = array();
|
||||
@@ -316,7 +335,7 @@ class ad_settings {
|
||||
|
||||
function print_searchlinks()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_POST_VARS;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_POST_VARS;
|
||||
|
||||
if ($IN['bypass'] == 1)
|
||||
{
|
||||
@@ -393,7 +412,7 @@ class ad_settings {
|
||||
|
||||
function do_message($message="")
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
|
||||
$ADMIN->html = "<tr><td id='tdrow1' height='100%' align='center' valign='middle'><br><br><b>$message</b><br><br> </td></tr>";
|
||||
|
||||
@@ -405,7 +424,7 @@ class ad_settings {
|
||||
|
||||
function print_search_box()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
|
||||
$ADMIN->html .= $SKIN->start_form( array( 1 => array( 'code' , 'searchlinks' ),
|
||||
2 => array( 'act' , 'rtempl' ),
|
||||
@@ -435,7 +454,7 @@ class ad_settings {
|
||||
|
||||
function search_frames()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
|
||||
print "<html>
|
||||
<head><title>Search</title></head>
|
||||
@@ -455,7 +474,7 @@ class ad_settings {
|
||||
|
||||
function compare_frames()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
|
||||
print "<html>
|
||||
<head>
|
||||
@@ -480,7 +499,7 @@ class ad_settings {
|
||||
|
||||
function print_compare_top()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
|
||||
$content = $IN['content'] == 'orig' ? 'Original Template' : 'Current Template';
|
||||
|
||||
@@ -496,7 +515,7 @@ class ad_settings {
|
||||
|
||||
function print_compare_new()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
|
||||
$DB->query("SELECT * FROM ibf_skin_templates WHERE suid='".$IN['suid']."'");
|
||||
|
||||
@@ -539,7 +558,7 @@ class ad_settings {
|
||||
|
||||
function macro_one()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
|
||||
$ADMIN->html .= $SKIN->start_form( array( 1 => array( 'code' , 'macro_two' ),
|
||||
2 => array( 'act' , 'rtempl' ),
|
||||
@@ -571,7 +590,7 @@ class ad_settings {
|
||||
|
||||
function macro_two()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP;
|
||||
|
||||
if ($IN['lookup'] == "")
|
||||
{
|
||||
@@ -715,7 +734,7 @@ class ad_settings {
|
||||
|
||||
function do_preview()
|
||||
{
|
||||
global $IN, $root_path, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_GET_VARS;
|
||||
global $IN, $INFO, $DB, $SKIN, $ADMIN, $std, $MEMBER, $GROUP, $HTTP_GET_VARS;
|
||||
|
||||
|
||||
if ($IN['suid'] == "")
|
||||
@@ -730,6 +749,18 @@ class ad_settings {
|
||||
$ADMIN->error("You must specify an existing template set ID, go back and try again");
|
||||
}
|
||||
|
||||
$DB->query("SELECT macro_id FROM ibf_skins WHERE set_id='".$template['set_id']."'");
|
||||
|
||||
$macrod = $DB->fetch_row();
|
||||
|
||||
$DB->query("SELECT macro_value, macro_replace FROM ibf_macro WHERE macro_set='".$macrod['macro_id']."'");
|
||||
|
||||
while ( $mc = $DB->fetch_row() )
|
||||
{
|
||||
$macro_orig[] = "<{".$mc['macro_value']."}>";
|
||||
$macro_repl[] = $mc['macro_replace'];
|
||||
}
|
||||
|
||||
$table = "<table width='100%' bgcolor='black' cellpadding='4' style='font-family:verdana, arial;font-size:11px;color:white'>
|
||||
<tr>
|
||||
<td align='center' style='font-family:verdana, arial;font-size:11px;color:white'>Template Group: {$template['group_name']} : Template bit: {$template['func_name']}</td>
|
||||
@@ -795,7 +826,7 @@ class ad_settings {
|
||||
|
||||
@header("Content-type: text/html");
|
||||
print "<html><head><title>Preview</title>$css_text</head><body>$table \n";
|
||||
print $this->convert_tags($template['section_content']);
|
||||
print str_replace( $macro_orig, $macro_repl, $this->convert_tags($template['section_content']) );
|
||||
|
||||
exit();
|
||||
|
||||
|
||||
Reference in new issue
Block a user