Page MenuHomeIn-Portal Phabricator

in-portal
No OneTemporary

File Metadata

Created
Sun, Feb 2, 6:43 AM

in-portal

Index: trunk/admin/users/group_mail.php
===================================================================
--- trunk/admin/users/group_mail.php (revision 859)
+++ trunk/admin/users/group_mail.php (revision 860)
@@ -1,183 +1,183 @@
<?php
##############################################################
##In-portal ##
##############################################################
## In-portal ##
## Intechnic Corporation ##
## All Rights Reserved, 1998-2002 ##
## ##
## No portion of this code may be copied, reproduced or ##
## otherwise redistributed without proper written ##
## consent of Intechnic Corporation. Violation will ##
## result in revocation of the license and support ##
## privileges along maximum prosecution allowed by law. ##
##############################################################
if(!strlen($pathtoroot))
{
$path=dirname(realpath(__FILE__));
if(strlen($path))
{
/* determine the OS type for path parsing */
$pos = strpos($path,":");
if ($pos === false)
{
$gOS_TYPE="unix";
$pathchar = "/";
}
else
{
$gOS_TYPE="win";
$pathchar="\\";
}
$p = $path.$pathchar;
/*Start looking for the root flag file */
while(!strlen($pathtoroot) && strlen($p))
{
$sub = substr($p,strlen($pathchar)*-1);
if($sub==$pathchar)
{
$filename = $p."root.flg";
}
else
$filename = $p.$pathchar."root.flg";
if(file_exists($filename))
{
$pathtoroot = $p;
}
else
{
$parent = realpath($p.$pathchar."..".$pathchar);
if($parent!=$p)
{
$p = $parent;
}
else
$p = "";
}
}
if(!strlen($pathtoroot))
$pathtoroot = ".".$pathchar;
}
else
{
$pathtoroot = ".".$pathchar;
}
}
$sub = substr($pathtoroot,strlen($pathchar)*-1);
if($sub!=$pathchar)
{
$pathtoroot = $pathtoroot.$pathchar;
}
//echo $pathtoroot;
require_once($pathtoroot."kernel/startup.php");
//admin only util
$rootURL="http://".ThisDomain().$objConfig->Get("Site_Path");
$admin = $objConfig->Get("AdminDirectory");
if(!strlen($admin))
$admin = "admin";
$localURL=$rootURL."kernel/";
$adminURL = $rootURL.$admin;
$imagesURL = $adminURL."/images";
-$pathtolocal = $pathtoroot."in-news/";
+//$pathtolocal = $pathtoroot."in-news/";
require_once ($pathtoroot.$admin."/include/elements.php");
require_once ($pathtoroot."kernel/admin/include/navmenu.php");
-require_once ($pathtolocal."admin/include/navmenu.php");
+//require_once ($pathtolocal."admin/include/navmenu.php");
require_once($pathtoroot.$admin."/toolbar.php");
unset($objEditItems);
$objEditItems = new clsGroupList();
$objEditItems->SourceTable = $objSession->GetEditTable("PortalGroup");
$objEditItems->EnablePaging = FALSE;
$GroupCount = 0;
if (isset($_POST["itemlist"]))
{
if(is_array($_POST["itemlist"]))
{
$GroupList = implode(",",$_POST["itemlist"]);
$GroupCount = count($_POST["itemlist"]);
}
else
{
$a = explode($_POST["itemlist"]);
$GroupCount = count($a);
unset($a);
$GroupList = $_POST["itemlist"];
}
if($itemcount>1)
{
if ($en+1 == $itemcount)
$en_next = -1;
else
$en_next = $en+1;
if ($en == 0)
$en_prev = -1;
else
$en_prev = $en-1;
}
$action = "m_sendmail";
}
$envar = "env=" . BuildEnv();
$section = 'in-portal:editgroup_sendmail';
$title = prompt_language("la_Text_Send")." ".prompt_language("la_Text_Email")." ".prompt_language("la_Text_To")." $GroupCount ".prompt_language("la_Text_Groups");
echo $envar."<br>\n";
//Display header
$sec = $objSections->GetSection($section);
$objCatToolBar = new clsToolBar();
$objCatToolBar->Add("img_save", "la_Save","#","swap('img_save','toolbar/tool_select_f2.gif');", "swap('img_save', 'toolbar/tool_select.gif');","edit_submit('editgroup','".$admin."/users/user_groups.php',1);",$imagesURL."/toolbar/tool_select.gif");
$objCatToolBar->Add("img_cancel", "la_Cancel","#","swap('img_cancel','toolbar/tool_cancel_f2.gif');", "swap('img_cancel', 'toolbar/tool_cancel.gif');","edit_submit('editgroup','".$admin."/users/user_groups.php',2);",$imagesURL."/toolbar/tool_cancel.gif");
int_header($objCatToolBar,NULL,$title);
?>
<table width="100%" border="0" cellspacing="0" cellpadding="4" class="tableborder">
<form ID="mailgroup" name="mailgroup" action="" method=POST>
<tr <?php int_table_color(); ?>>
<td valign="top" colspan="3"><?php echo prompt_language("la_prompt_Enable_HTML"); ?>
<input type="checkbox" name="html_enable" value="1">
<br>
<?php int_hint(prompt_language("la_Warning_Enable_HTML")); ?>
</td>
</tr>
<?php int_subsection_title(prompt_language("la_tab_EmailMessage")); ?>
<tr <?php int_table_color(); ?>>
<td valign="top"><span class="text"><?php echo prompt_language("la_prompt_EmailSubject"); ?></span></td>
<td>
<input type="text" name="email_subject" class="text" size="30" value="">
</td>
<td><span ID="valSubject" class="validation_error"><?php echo prompt_language("la_val_RequiredField"); ?></span></td>
</tr>
<tr <?php int_table_color(); ?>>
<td valign="top"><span class="text"><?php echo prompt_language("la_prompt_EmailBody"); ?></span></td>
<td>
<textarea name="email_body" cols="30" rows="5" class="text"></textarea>
</td>
<td><span ID="valBody" class="validation_error"><?php echo prompt_language("la_val_RequiredField"); ?></span></td>
</tr>
<tr <?php int_table_color(); ?>>
<td colspan="3">
<input type="hidden" name="Action" value="<?php echo $action; ?>">
<input type="hidden" name="idlist" value="<?php echo $GroupList; ?>">
<input type="hidden" name="IdType" VALUE="group">
<input type="button" name="submit1" value="<?php echo admin_language("la_Save"); ?>" class="button" onclick="edit_submit('editgroup','".$admin."/users/user_groups.php',1);">
<input type="button" name="submit3" value="<?php echo admin_language("la_Cancel"); ?>" class="button" onclick="edit_submit('editgroup','".$admin."/users/user_groups.php',2);">
</td>
</tr>
</FORM>
</table>
<SCRIPT LANGUAGE="JavaScript">
InitValidation();
</SCRIPT>
<?php int_footer(); ?>
\ No newline at end of file
Property changes on: trunk/admin/users/group_mail.php
___________________________________________________________________
Modified: cvs2svn:cvs-rev
## -1 +1 ##
-1.2
\ No newline at end of property
+1.3
\ No newline at end of property
Index: trunk/admin/users/user_mail.php
===================================================================
--- trunk/admin/users/user_mail.php (revision 859)
+++ trunk/admin/users/user_mail.php (revision 860)
@@ -1,177 +1,177 @@
<?php
##############################################################
##In-portal ##
##############################################################
## In-portal ##
## Intechnic Corporation ##
## All Rights Reserved, 1998-2002 ##
## ##
## No portion of this code may be copied, reproduced or ##
## otherwise redistributed without proper written ##
## consent of Intechnic Corporation. Violation will ##
## result in revocation of the license and support ##
## privileges along maximum prosecution allowed by law. ##
##############################################################
if(!strlen($pathtoroot))
{
$path=dirname(realpath(__FILE__));
if(strlen($path))
{
/* determine the OS type for path parsing */
$pos = strpos($path,":");
if ($pos === false)
{
$gOS_TYPE="unix";
$pathchar = "/";
}
else
{
$gOS_TYPE="win";
$pathchar="\\";
}
$p = $path.$pathchar;
/*Start looking for the root flag file */
while(!strlen($pathtoroot) && strlen($p))
{
$sub = substr($p,strlen($pathchar)*-1);
if($sub==$pathchar)
{
$filename = $p."root.flg";
}
else
$filename = $p.$pathchar."root.flg";
if(file_exists($filename))
{
$pathtoroot = $p;
}
else
{
$parent = realpath($p.$pathchar."..".$pathchar);
if($parent!=$p)
{
$p = $parent;
}
else
$p = "";
}
}
if(!strlen($pathtoroot))
$pathtoroot = ".".$pathchar;
}
else
{
$pathtoroot = ".".$pathchar;
}
}
$sub = substr($pathtoroot,strlen($pathchar)*-1);
if($sub!=$pathchar)
{
$pathtoroot = $pathtoroot.$pathchar;
}
//echo $pathtoroot;
require_once($pathtoroot."kernel/startup.php");
$rootURL="http://".ThisDomain().$objConfig->Get("Site_Path");
$admin = $objConfig->Get("AdminDirectory");
if(!strlen($admin))
$admin = "admin";
$localURL=$rootURL."kernel/";
$adminURL = $rootURL.$admin;
$imagesURL = $rootURL."/images";
-$pathtolocal = $pathtoroot."in-news/";
+//$pathtolocal = $pathtoroot."in-news/";
require_once ($pathtoroot.$admin."/include/elements.php");
require_once ($pathtoroot."kernel/admin/include/navmenu.php");
-require_once ($pathtolocal."admin/include/navmenu.php");
+//require_once ($pathtolocal."admin/include/navmenu.php");
require_once($pathtoroot.$admin."/toolbar.php");
unset($objEditItems);
$objEditItems = new clsUserManager();
$objEditItems->SourceTable = $objSession->GetEditTable("PortalUser");
$objEditItems->EnablePaging = FALSE;
$GroupCount = 0;
if (isset($_POST["itemlist"]))
{
if(is_array($_POST["itemlist"]))
{
$UserList = implode(",",$_POST["itemlist"]);
$UserCount = count($_POST["itemlist"]);
}
else
{
$a = explode($_POST["itemlist"]);
$userCount = count($a);
unset($a);
$UserList = $_POST["itemlist"];
}
if($itemcount>1)
{
if ($en+1 == $itemcount)
$en_next = -1;
else
$en_next = $en+1;
if ($en == 0)
$en_prev = -1;
else
$en_prev = $en-1;
}
$action = "m_sendmail";
}
$envar = "env=" . BuildEnv();
$section = 'in-portal:edituser_sendmail';
$title = prompt_language("la_Text_Send")." ".prompt_language("la_Text_Email")." ".prompt_language("la_Text_To")." $UserCount ".prompt_language("la_Text_Users");
echo $envar."<br>\n";
//Display header
$sec = $objSections->GetSection($section);
int_header(NULL,NULL,$title);
?>
<table width="100%" border="0" cellspacing="0" cellpadding="4" class="tableborder">
<form ID="mailuser" name="mailuser" action="" method=POST>
<tr <?php int_table_color(); ?>>
<td valign="top" colspan="3"><?php echo prompt_language("la_prompt_Enable_HTML"); ?>
<input type="checkbox" name="html_enable" value="1">
<br>
<?php int_hint(prompt_language("la_Warning_Enable_HTML")); ?>
</td>
</tr>
<?php int_subsection_title(prompt_language("la_tab_EmailMessage")); ?>
<tr <?php int_table_color(); ?>>
<td valign="top"><span class="text"><?php echo prompt_language("la_prompt_EmailSubject"); ?></span></td>
<td>
<input type="text" name="email_subject" class="text" size="30" value="">
</td>
<td><span ID="valSubject" class="validation_error"><?php echo prompt_language("la_val_RequiredField"); ?></span></td>
</tr>
<tr <?php int_table_color(); ?>>
<td valign="top"><span class="text"><?php echo prompt_language("la_prompt_EmailBody"); ?></span></td>
<td>
<textarea name="email_body" cols="30" rows="5" class="text"></textarea>
</td>
<td><span ID="valBody" class="validation_error"><?php echo prompt_language("la_val_RequiredField"); ?></span></td>
</tr>
<tr <?php int_table_color(); ?>>
<td colspan="3">
<input type="hidden" name="Action" value="<?php echo $action; ?>">
<input type="hidden" name="idlist" value="<?php echo $UserList; ?>">
<input type="hidden" name="IdType" VALUE="user">
<input type="button" name="submit1" value="<?php echo admin_language("la_Save"); ?>" class="button" onclick="edit_submit('mailuser','<?php echo $admin; ?>/users/user_list.php',1);">
<input type="button" name="submit3" value="<?php echo admin_language("la_Cancel"); ?>" class="button" onclick="edit_submit('mailuser','<?php echo $admin; ?>/users/user_list.php',2);">
</td>
</tr>
</FORM>
</table>
<SCRIPT LANGUAGE="JavaScript">
InitValidation();
</SCRIPT>
<?php int_footer(); ?>
\ No newline at end of file
Property changes on: trunk/admin/users/user_mail.php
___________________________________________________________________
Modified: cvs2svn:cvs-rev
## -1 +1 ##
-1.2
\ No newline at end of property
+1.3
\ No newline at end of property
Index: trunk/admin/category/category_maint.php
===================================================================
--- trunk/admin/category/category_maint.php (revision 859)
+++ trunk/admin/category/category_maint.php (revision 860)
@@ -1,166 +1,166 @@
<?php
##############################################################
##In-portal ##
##############################################################
## In-portal ##
## Intechnic Corporation ##
## All Rights Reserved, 1998-2002 ##
## ##
## No portion of this code may be copied, reproduced or ##
## otherwise redistributed without proper written ##
## consent of Intechnic Corporation. Violation will ##
## result in revocation of the license and support ##
## privileges along maximum prosecution allowed by law. ##
##############################################################
if(!defined('CACHE_PERM_CHUNK_SIZE'))define('CACHE_PERM_CHUNK_SIZE',30);
if(!strlen($pathtoroot))
{
$path = dirname(realpath(__FILE__));
if( strlen($path) )
{
// determine the OS type for path parsing
$pos = strpos($path, ':');
$gOS_TYPE = ($pos === false) ? 'unix' : 'win';
$pathchar = ($gOS_TYPE == 'unix') ? '/' : "\\";
$p = $path.$pathchar;
// Start looking for the root flag file
while( !strlen($pathtoroot) && strlen($p) )
{
$sub = substr($p, strlen($pathchar) * -1);
$filename = $p.( ($sub == $pathchar) ? '' : $pathchar).'root.flg';
if( !file_exists($filename) )
{
$parent = realpath($p.$pathchar."..".$pathchar);
$p = ($parent != $p) ? $parent : '';
}
else
$pathtoroot = $p;
}
if( !strlen($pathtoroot) ) $pathtoroot = '.'.$pathchar;
}
else
$pathtoroot = '.'.$pathchar;
}
$sub = substr($pathtoroot,strlen($pathchar)*-1);
if( $sub != $pathchar) $pathtoroot = $pathtoroot.$pathchar;
//echo $pathtoroot;
//$FrontEnd=2;
require_once($pathtoroot."kernel/startup.php");
//admin only util
$rootURL="http://".ThisDomain().$objConfig->Get("Site_Path");
$admin = $objConfig->Get("AdminDirectory");
if(!strlen($admin))
$admin = "admin";
$localURL=$rootURL."kernel/";
$adminURL = $rootURL.$admin;
$imagesURL = $adminURL."/images";
-$pathtolocal = $pathtoroot."in-news/";
+//$pathtolocal = $pathtoroot."in-news/";
require_once ($pathtoroot.$admin."/include/elements.php");
require_once ($pathtoroot."kernel/admin/include/navmenu.php");
-require_once ($pathtolocal."admin/include/navmenu.php");
+//require_once ($pathtolocal."admin/include/navmenu.php");
require_once($pathtoroot.$admin."/toolbar.php");
require_once($pathtoroot.$admin."/listview/listview.php");
$section = "in-portal:category_maint";
require_once($pathtoroot.$admin."/category/permcacheupdate.php");
if(!$objSession->GetVariable('PermCache_UpdateRequired'))
{
die(header('Location: '.$adminURL.'/'.$objSession->GetVariable('ReturnScript').'?env='.BuildEnv()));
}
if(isset($_GET['continue']))
{
$updater =& new clsCacheUpdater(1);
if(!intval($_GET['continue']))
{
$updater->clearData();
die(header('Location: '.$adminURL.'/'.$objSession->GetVariable('ReturnScript').'?env='.BuildEnv()));
}
}
else
{
$updater =& new clsCacheUpdater();
$no_url = $_SERVER['PHP_SELF'].'?env='.BuildEnv().'&continue=0';
$yes_url = $_SERVER['PHP_SELF'].'?env='.BuildEnv().'&continue=1';
if(!isset($_GET['force']))
if($updater->totalCats > CACHE_PERM_CHUNK_SIZE)
{
$updater->setData();
$title = prompt_language("la_prompt_updating")." ".prompt_language("la_Text_Categories");
int_header(NULL,NULL,$title);
flush();
?>
<script language="javascript">
function goto_url(url)
{
document.location = url;
}
</script>
<table cellspacing="0" cellpadding="2" width="100%" border="0" class="tableborder">
<tr>
<td align="center" colspan="3" bgcolor="#FFFFFF"><?php echo prompt_language('la_confirm_maintenance'); ?></td>
</tr>
<tr>
<td align="center" colspan="3" bgcolor="#FFFFFF"><?php echo prompt_language('la_prompt_perform_now'); ?></td>
</tr>
<tr>
<td align="right" width="50%">
<input type="button" name="yes_btn" value="<?php echo admin_language("lu_yes"); ?>" onclick="javascript:goto_url('<?php echo $yes_url; ?>');" class="button">
</td>
<td><img src="<?php echo $imagesURL; ?>/spacer.gif" width="10"></td>
<td align="left" width="50%">
<input type="button" name="yes_btn" value="<?php echo admin_language("lu_no"); ?>" onclick="javascript:goto_url('<?php echo $no_url; ?>');" class="button">
</td>
</tr>
</table>
<?php
int_footer();
die();
}
}
$title = prompt_language("la_prompt_updating")." ".prompt_language("la_Text_Categories");
int_header(NULL,NULL,$title);
flush();
$percent=$updater->getDonePercent();
echo '<TABLE cellspacing="0" cellpadding="2" width="100%" border="0" class="tableborder">';
if ($percent == 0)
echo '<TR><TD BGCOLOR="#FFFFFF" width="100%" >'.$percent.'%</td></TR>';
else if ($percent < 60)
echo '<TR><TD BGCOLOR="#4682B2" width="'.$percent.'%"></td><TD BGCOLOR="#FFFFFF" width="'.(100-$percent).'%">'.$percent.'%</td></TR>';
else if ($percent == 100)
echo '<TR><TD BGCOLOR="#4682B2" align="right" width="100%"><FONT COLOR="#FFFFFF">'.$percent.'%</FONT></td>';
else
echo '<TR><TD BGCOLOR="#4682B2" align="right" width="'.$percent.'%"><FONT COLOR="#FFFFFF">'.$percent.'%</FONT></td><TD BGCOLOR="#FFFFFF" width="'.(100-$percent).'%"></td></TR>';
echo '</TABLE>';
flush();
$needs_more = TRUE;
while ($needs_more && $updater->iteration < CACHE_PERM_CHUNK_SIZE) {
$needs_more = $updater->DoTheJob();
}
if ($needs_more)
{
$updater->setData();
$url=$adminURL.'/category/category_maint.php?env='.BuildEnv().'&continue=1';
}
else
{
$updater->clearData();
$url = $adminURL.'/'.$objSession->GetVariable('ReturnScript').'?env='.BuildEnv();
$objSession->SetVariable('PermCache_UpdateRequired', 0);
}
print "<script language=\"javascript\">" ;
print "setTimeout(\"document.location='$url';\",400);";
print "</script>";
int_footer();
exit;
?>
\ No newline at end of file
Property changes on: trunk/admin/category/category_maint.php
___________________________________________________________________
Modified: cvs2svn:cvs-rev
## -1 +1 ##
-1.18
\ No newline at end of property
+1.19
\ No newline at end of property
Index: trunk/admin/config/missing_label_search.php
===================================================================
--- trunk/admin/config/missing_label_search.php (revision 859)
+++ trunk/admin/config/missing_label_search.php (revision 860)
@@ -1,270 +1,270 @@
<?php
##############################################################
##In-portal ##
##############################################################
## In-portal ##
## Intechnic Corporation ##
## All Rights Reserved, 1998-2002 ##
## ##
## No portion of this code may be copied, reproduced or ##
## otherwise redistributed without proper written ##
## consent of Intechnic Corporation. Violation will ##
## result in revocation of the license and support ##
## privileges along maximum prosecution allowed by law. ##
##############################################################
if(!strlen($pathtoroot))
{
$path=dirname(realpath(__FILE__));
if(strlen($path))
{
/* determine the OS type for path parsing */
$pos = strpos($path,":");
if ($pos === false)
{
$gOS_TYPE="unix";
$pathchar = "/";
}
else
{
$gOS_TYPE="win";
$pathchar="\\";
}
$p = $path.$pathchar;
/*Start looking for the root flag file */
while(!strlen($pathtoroot) && strlen($p))
{
$sub = substr($p,strlen($pathchar)*-1);
if($sub==$pathchar)
{
$filename = $p."root.flg";
}
else
$filename = $p.$pathchar."root.flg";
if(file_exists($filename))
{
$pathtoroot = $p;
}
else
{
$parent = realpath($p.$pathchar."..".$pathchar);
if($parent!=$p)
{
$p = $parent;
}
else
$p = "";
}
}
if(!strlen($pathtoroot))
$pathtoroot = ".".$pathchar;
}
else
{
$pathtoroot = ".".$pathchar;
}
}
$sub = substr($pathtoroot,strlen($pathchar)*-1);
if($sub!=$pathchar)
{
$pathtoroot = $pathtoroot.$pathchar;
}
//echo $pathtoroot;
$FrontEnd=2;
require_once($pathtoroot."kernel/startup.php");
class clsLangParser extends clsTemplateList
{
function clsLangParser($TemplateRoot)
{
$this->clsTemplateList($TemplateRoot);
}
function ParseTag($raw)
{
$res = "";
//echo "Tag:".htmlentities($raw).":<br>\n";
if(strlen(trim($raw))>0)
{
$tag = new clsHtmlTag($raw);
switch($tag->name)
{
case "include":
case "perm_include":
$res = "<!-- include skipped -->";
break;
case "mod_include":
$res = "<!-- include skipped -->";
break;
default:
//if($tag->name=="m_language")
$res = $tag->Execute();
break;
}
unset($tag);
}
return $res;
}
}
//admin only util
$rootURL="http://".ThisDomain().$objConfig->Get("Site_Path");
$admin = $objConfig->Get("AdminDirectory");
if(!strlen($admin))
$admin = "admin";
$localURL=$rootURL."kernel/";
$adminURL = $rootURL.$admin;
$imagesURL = $adminURL."/images";
-$pathtolocal = $pathtoroot."in-news/";
+//$pathtolocal = $pathtoroot."in-news/";
require_once ($pathtoroot.$admin."/include/elements.php");
require_once ($pathtoroot."kernel/admin/include/navmenu.php");
-require_once ($pathtolocal."admin/include/navmenu.php");
+//require_once ($pathtolocal."admin/include/navmenu.php");
require_once($pathtoroot.$admin."/toolbar.php");
require_once($pathtoroot.$admin."/listview/listview.php");
$section = "in-portal:missing_label_search";
$FilesPerLoad = 20;
$ado = &GetADODBConnection();
if($_GET["LangId"])
{
$LangId = $_GET["LangId"];
$ThemeId = $_GET["theme"];
$table = $objSession->GetSessionTable("_".$ThemeId."_labels");
@$ado->Execute("DROP TABLE IF EXISTS $table ");
$Phrases = new clsPhraseList();
$query = "SELECT * FROM ".$Phrases->SourceTable." WHERE PhraseId = -1";
$insert = "CREATE TABLE ".$table." ".$query;
$ado->Execute($insert);
$FileIndex = 0;
$objThemeFiles = new clsThemeFileList($ThemeId);
$NumFiles = TableCount($objThemeFiles->SourceTable,"ThemeId=$ThemeId",0);
$objSession->SetVariable("Missing_ThemeId",$ThemeId);
$objSession->SetVariable("Missing_LangId",$LangId);
}
else
{
$ThemeId = $objSession->GetVariable("Missing_ThemeId");
$table = $objSession->GetSessionKey()."_".$ThemeId."_labels";
$objThemeFiles = new clsThemeFileList($ThemeId);
$LangId = $objSession->GetVariable("Missing_LangId");
$FileIndex = $_GET["File"];
$NumFiles = $_GET["NumFiles"];
}
$l = $objLanguages->GetItem($LangId);
$name = $l->Get("PackName");
$objThemeList = new clsThemeList();
$Theme = $objThemeList->GetItem($ThemeId);
$theme_name = $Theme->Get("Name");
$sql = "SELECT * FROM $table";
$rs = $ado->Execute($sql);
$found = array();
while($rs && !$rs->EOF)
{
$p = $rs->fields["Phrase"];
if(!in_array($p,$found))
$found[] = $p;
$rs->MoveNext();
}
$subtitle = prompt_language("la_prompt_Theme").": ".$theme_name;
$title = prompt_language("la_Text_Scanning")." ".prompt_language("la_Text_Templates");
int_header(NULL,NULL,$title);
?>
<TABLE cellSpacing="0" cellPadding="2" width="100%" class="tableborder">
<?php int_subsection_title($subtitle); ?>
<?php
if($NumFiles==0)
{
$percent=100;
}
else
{
$percent = (int)(($FileIndex/$NumFiles) * 100);
}
if ($percent == 0)
{
echo "<TR>";
echo "<TD BGCOLOR=\"#FFFFFF\" width=\"100%\" >$percent";
echo "%</td></TR>";
}
else if ($percent < 60)
{
echo "<TR><TD BGCOLOR=\"#4682B2\" width=\"".$percent."%\" >";
$row2 = 100-$percent;
echo "</td> <TD BGCOLOR=\"#FFFFFF\" width=\"".$row2."%\" > $percent";
echo "%</td></TR>";
}
else if ($percent == 100)
{
echo "<TR><TD BGCOLOR=\"#4682B2\" align=\"right\" width=\"100%\" ><FONT COLOR=\"#FFFFFF\">$percent%</FONT></td>";
}
else
{
echo "<TR><TD BGCOLOR=\"#4682B2\" align=\"right\" width=\"".$percent."%\" ><FONT COLOR=\"#FFFFFF\">$percent%</FONT>";
$row2 = 100-$percent;
echo "</td> <TD BGCOLOR=\"#FFFFFF\" width=\"".$row2."%\" ></td></TR>";
}
$sql = "SELECT * FROM ".$objThemeFiles->SourceTable." WHERE ThemeId=$ThemeId LIMIT $FileIndex,$FilesPerLoad";
$TemplateRoot = $Theme->ThemeDirectory()."/";
$objTemplate = new clsLangParser($TemplateRoot);
$objTemplate->SkipIncludes=1;
//$ForceLanguage = $LangId;
$LogPhraseLookups = TRUE;
$rs = $ado->Execute($sql);
while($rs && !$rs->EOF)
{
$path = "";
$p = $rs->fields["FilePath"];
if(strlen(trim($p)))
$path .= $p."/";
$path .= $rs->fields["FileName"];
$path = substr($path,0,-4);
//echo "Parsing $path <br>\n";
$html = $objTemplate->ParseTemplate($path);
//echo htmlentities($html)."<br>\n";
$rs->MoveNext();
}
if(is_array($MissingList))
{
for($x=0;$x<count($MissingList);$x++)
{
$next = $x + $FileIndex;
if(!in_array($MissingList[$x],$found))
{
$sql = "INSERT INTO $table (PhraseId,Phrase,Translation,PhraseType,LanguageId) VALUES (";
$sql .= $next.",'".$MissingList[$x]."','',1,$LangId)";
//echo $sql."<br>\n";
$ado->Execute($sql);
}
}
}
if($FileIndex >=$NumFiles)
{
$target = $adminURL."/config/missing_label_edit.php?env=".BuildEnv()."&lpn=1";
}
else
{
$next = $FileIndex+$FilesPerLoad;
$target = $_SERVER["PHP_SELF"]."?env=".BuildEnv()."&File=".$next."&NumFiles=$NumFiles";
}
?>
</TABLE>
<?php int_footer(); ?>
<?php
flush();
print "<script language=\"javascript\">";
print " location.href='$target';";
print " </script>";
//print "<A HREF=\"$target\">$target</A>";
?>
Property changes on: trunk/admin/config/missing_label_search.php
___________________________________________________________________
Modified: cvs2svn:cvs-rev
## -1 +1 ##
-1.4
\ No newline at end of property
+1.5
\ No newline at end of property
Index: trunk/admin/config/missing_label_edit.php
===================================================================
--- trunk/admin/config/missing_label_edit.php (revision 859)
+++ trunk/admin/config/missing_label_edit.php (revision 860)
@@ -1,306 +1,306 @@
<?php
##############################################################
##In-portal ##
##############################################################
## In-portal ##
## Intechnic Corporation ##
## All Rights Reserved, 1998-2002 ##
## ##
## No portion of this code may be copied, reproduced or ##
## otherwise redistributed without proper written ##
## consent of Intechnic Corporation. Violation will ##
## result in revocation of the license and support ##
## privileges along maximum prosecution allowed by law. ##
##############################################################
if(!strlen($pathtoroot))
{
$path=dirname(realpath(__FILE__));
if(strlen($path))
{
/* determine the OS type for path parsing */
$pos = strpos($path,":");
if ($pos === false)
{
$gOS_TYPE="unix";
$pathchar = "/";
}
else
{
$gOS_TYPE="win";
$pathchar="\\";
}
$p = $path.$pathchar;
/*Start looking for the root flag file */
while(!strlen($pathtoroot) && strlen($p))
{
$sub = substr($p,strlen($pathchar)*-1);
if($sub==$pathchar)
{
$filename = $p."root.flg";
}
else
$filename = $p.$pathchar."root.flg";
if(file_exists($filename))
{
$pathtoroot = $p;
}
else
{
$parent = realpath($p.$pathchar."..".$pathchar);
if($parent!=$p)
{
$p = $parent;
}
else
$p = "";
}
}
if(!strlen($pathtoroot))
$pathtoroot = ".".$pathchar;
}
else
{
$pathtoroot = ".".$pathchar;
}
}
$sub = substr($pathtoroot,strlen($pathchar)*-1);
if($sub!=$pathchar)
{
$pathtoroot = $pathtoroot.$pathchar;
}
//echo $pathtoroot;
require_once($pathtoroot."kernel/startup.php");
//admin only util
$rootURL="http://".ThisDomain().$objConfig->Get("Site_Path");
$admin = $objConfig->Get("AdminDirectory");
if(!strlen($admin))
$admin = "admin";
$localURL=$rootURL."kernel/";
$adminURL = $rootURL.$admin;
$imagesURL = $adminURL."/images";
-$pathtolocal = $pathtoroot."in-news/";
+//$pathtolocal = $pathtoroot."in-news/";
require_once ($pathtoroot.$admin."/include/elements.php");
require_once ($pathtoroot."kernel/admin/include/navmenu.php");
-require_once ($pathtolocal."admin/include/navmenu.php");
+//require_once ($pathtolocal."admin/include/navmenu.php");
require_once($pathtoroot.$admin."/toolbar.php");
require_once($pathtoroot.$admin."/listview/listview.php");
$m = GetModuleArray();
foreach($m as $key=>$value)
{
$path = $pathtoroot. $value."admin/include/parser.php";
if(file_exists($path))
{
include_once($path);
}
}
unset($objEditItems);
$objEditItems = new clsPhraseList();
$objEditItems->SourceTable = $objSession->GetEditTable("Language");
//Multiedit init
$en = (int)$_GET["en"];
$objEditItems->Query_Item("SELECT * FROM ".$objEditItems->SourceTable);
$itemcount=$objEditItems->NumItems();
//$c = $objEditItems->GetItemByIndex($en);
$LangId = $objSession->GetVariable("Missing_LangId");
$c = $objLanguages->GetItem($LangId);
$name = $c->Get("PackName");
if($itemcount>1)
{
if ($en+1 == $itemcount)
$en_next = -1;
else
$en_next = $en+1;
if ($en == 0)
$en_prev = -1;
else
$en_prev = $en-1;
}
$action = "m_phrase_edit";
$envar = "env=" . BuildEnv() . "&en=$en";
$section = 'in-portal:missing_lang_labels';
//echo $envar."<br>\n";
$objListToolBar = new clsToolBar();
$objListToolBar->Add("img_save", "la_Save","#","swap('img_save','toolbar/tool_select_f2.gif');", "swap('img_save', 'toolbar/tool_select.gif');","save_labels();","tool_select.gif");
$objListToolBar->Add("img_cancel", "la_Cancel","#","swap('img_cancel','toolbar/tool_cancel_f2.gif');", "swap('img_cancel', 'toolbar/tool_cancel.gif');","window.close();",$imagesURL."/toolbar/tool_cancel.gif");
$objListToolBar->Set("section",$section);
$objListToolBar->Set("load_menu_func","");
$objListToolBar->Set("CheckClass","LangChecks");
//Display header
$sec = $objSections->GetSection($section);
if ( isset($en_prev) || isset($en_next) )
{
$objListToolBar->Add("divider");
if($en_prev>-1)
{
$MouseOver="swap('moveleft','toolbar/tool_prev_f2.gif');";
$MouseOut="swap('moveleft', 'toolbar/tool_prev.gif');";
$onClick= $sec->Get("onclick");
$var="?env=".BuildEnv()."&en=$en_prev";
$link=$_SERVER["PHP_SELF"].$var;
$objListToolBar->Add("moveleft",admin_language("la_ToolTip_Previous")." ".admin_language("la_Text_Theme"),$link,$MouseOver,$MouseOut,"","tool_prev.gif");
}
else
{
$MouseOver="";
$MouseOut="";
$onClick="";
$link="#";
$objListToolBar->Add("moveleft",admin_language("la_ToolTip_Previous")." ".admin_language("la_Text_Theme"),"#","","","","tool_prev_f3.gif");
}
if($en_next>-1)
{
$MouseOver="swap('moveright','toolbar/tool_next_f2.gif');";
$MouseOut="swap('moveright', 'toolbar/tool_next.gif');";
$onClick=$sec->Get("onclick");
$var="?env=".BuildEnv()."&en=$en_next";
$link=$_SERVER["PHP_SELF"].$var;
$objListToolBar->Add("moveright",admin_language("la_ToolTip_Next")." ".admin_language("la_Text_Theme"),$link,$MouseOver,$MouseOut,"","tool_next.gif");
}
else
{
$objListToolBar->Add("moveright",admin_language("la_ToolTip_Next")." ".admin_language("la_Text_Theme"),$link,$MouseOver,$MouseOut,"","tool_next_f3.gif");
}
}
$CurrentLangId = $c->Get("LanguageId");
$title = prompt_language("la_Text_Configuration")." - '".$name."' ".prompt_language("la_Text_Pack")." - ".prompt_language("la_tab_MissingLabels");
int_header($objListToolBar,NULL, $title);
$ThemeId = $objSession->GetVariable("Missing_ThemeId");
$table = $objSession->GetSessionTable("_".$ThemeId."_labels");
$objPhrases = new clsPhraseList();
$objPhrases->SourceTable = $table;
$order = trim($objConfig->Get("Phrase_LV_Sortfield")." ".$objConfig->Get("Phrase_LV_Sortorder"));
$primary = $objLanguages->GetPrimary();
$ptable = GetTablePrefix()."Phrase";
$sql = "SELECT distinct(e.Phrase) as Phrase, ";
$sql .= "concat('<INPUT TYPE=TEXT name=\"Phrase[',e.Phrase,']\" VALUE=\"',e.Translation,'\">') as Translation, ";
$sql .="p.Translation as PrimaryValue, e.PhraseId as PhraseId ";
$sql .= "FROM $table as e LEFT JOIN $ptable as p ON (e.Phrase=p.Phrase AND p.LanguageId=$primary) WHERE e.LanguageId=".$c->Get("LanguageId")." ";
if(strlen($where))
$sql .= "AND ".$where." ";
if(strlen($order))
$sql .= "ORDER BY ".$order." ";
if(isset($_GET["lpn"]))
$objSession->SetVariable("m_Page_Phrase",$_GET["lpn"]);
$sql .= GetLimitSQL($objSession->GetVariable("m_Page_Phrase"),$objConfig->Get("Perpage_Phrase"));
$objPhrases->Query_Item($sql);
$itemcount = TableCount($table, $where,0);
if($objSession->HasSystemPermission("DEBUG.LIST"))
echo htmlentities($sql,ENT_NOQUOTES)."<br>\n";
$objListView = new clsListView($objListToolBar, $objPhrases);
$objListView->IdField = "PhraseId";
$order = $objConfig->Get("Phrase_LV_Sortfield");
$objListView->ColumnHeaders->Add("Phrase",admin_language("la_prompt_Label"),1,0,$order,"width=\"30%\"","Phrase_LV_Sortfield","Phrase_LV_Sortorder","Phrase");
$objListView->ColumnHeaders->Add("Translation",admin_language("la_prompt_Value"),1,0,$order,"width=\"40%\"","Phrase_LV_Sortfield","Phrase_LV_Sortorder","Translation");
$objListView->ColumnHeaders->Add("PrimaryValue",admin_language("la_prompt_PrimaryValue"),1,0,$order,"width=\"30%\"","Phrase_LV_Sortfield","Phrase_LV_Sortorder","PrimaryValue");
$objListView->ColumnHeaders->SetSort($objConfig->Get("Phrase_LV_Sortfield"), $objConfig->Get("Phrase_LV_Sortorder"));
$objListView->PrintToolBar = FALSE;
$objListView->checkboxes = FALSE;
$objListView->CurrentPageVar = "m_Page_Phrase";
$objListView->PerPageVar = "Perpage_Phrase";
$objListView->PageURL = "javascript:setPage({TargetPage});";
$objListView->CheckboxName = "itemlist[]";
$objListView->SearchBar = FALSE;
$objListView->SearchAction="";
$objListView->TotalItemCount = $itemcount;
for($i=0;$i<count($objPhrases->Items);$i++)
{
$objListView->RowIcons[] = $objPhrases->Items[$i]->AdminIcon();
}
?>
<form name="language" ID="language" action="<?php echo $_SERVER["PHP_SELF"]."?".$envar;?>" method=POST>
<table cellSpacing="0" cellPadding="2" width="100%" class="tableborder">
<tbody>
<?php
print $objListView->PrintList();
?>
<input type="hidden" NAME="section" VALUE="<?php echo $section; ?>">
<input type="hidden" name="Action" value="m_config_missing_phrase">
<input type="hidden" name="LangId" value="<?php echo $CurrentLangId; ?>">
<input type="hidden" name="ThemeId" value="<?php echo $ThemeId; ?>">
<input type="hidden" name="MissingLangEditStatus" VALUE="0">
</FORM>
<FORM>
<TR <?php int_table_color(); ?> >
<td colspan="3">
</td>
</tr>
</FORM>
</TABLE>
<!-- CODE FOR VIEW MENU -->
<form ID="viewmenu" method="post" action="<?php echo $_SERVER["PHP_SELF"]."?".$envar; ?>" name="viewmenu">
<input type="hidden" name="fieldname" value="">
<input type="hidden" name="varvalue" value="">
<input type="hidden" name="varvalue2" value="">
<input type="hidden" name="Action" value="">
</form>
<!-- CODE FOR TEMPLATE MENU -->
<form ID="templatemenu" method="post" action="<?php echo $_SERVER["PHP_SELF"]."?".$envar; ?>" name="templatemenu">
<input type="hidden" name="fieldname" value="">
<input type="hidden" name="varvalue" value="">
<input type="hidden" name="varvalue2" value="">
<input type="hidden" name="Action" value="">
</form>
<FORM ID="ListSearchForm" NAME="ListSearchForm" method="POST" action="<?php echo $_SERVER["PHP_SELF"]."?env=".BuildEnv(); ?>">
<INPUT TYPE="HIDDEN" NAME="Action" VALUE="">
<INPUT TYPE="HIDDEN" NAME="list_search">
</FORM>
<FORM NAME="popup" METHOD="POST" ACTION="<?php echo $_SERVER["PHP_SELF"]."?".$envar; ?>" ID="popup">
<INPUT TYPE="HIDDEN" NAME="phrase" value="">
<INPUT TYPE="HIDDEN" NAME="languageid" value="">
<INPUT TYPE="HIDDEN" NAME="phraseid" value="">
<INPUT TYPE="HIDDEN" NAME="phrasetype" value="">
<INPUT TYPE="HIDDEN" NAME="transvalue" value="">
<INPUT TYPE="HIDDEN" NAME="Action" VALUE="m_phrase_edit">
</FORM>
<script src="<?php echo $adminURL; ?>/listview/listview.js"></script>
<script>
initSelectiorContainers();
<?php echo $objListToolBar->Get("CheckClass").".setImages();"; ?>
</script>
<?php int_footer(); ?>
Property changes on: trunk/admin/config/missing_label_edit.php
___________________________________________________________________
Modified: cvs2svn:cvs-rev
## -1 +1 ##
-1.2
\ No newline at end of property
+1.3
\ No newline at end of property

Event Timeline