mirror of
https://github.com/e107inc/e107.git
synced 2025-07-30 19:30:25 +02:00
PHP Warning Fixes.
This commit is contained in:
@@ -359,7 +359,7 @@ class eurl_admin_ui extends e_admin_controller_ui
|
||||
$admin = $obj->admin();
|
||||
$labels = vartrue($admin['labels'], array());
|
||||
|
||||
$this->prefs['url_main_module']['writeParms'][$module] = vartrue($section['name'], eHelper::labelize($module));
|
||||
$this->prefs['url_main_module']['writeParms'][$module] = eHelper::labelize($module); // vartrue($section['name'], eHelper::labelize($module));
|
||||
}
|
||||
|
||||
ksort($this->prefs['url_main_module']['writeParms']);
|
||||
@@ -882,7 +882,7 @@ class eurl_admin_form_ui extends e_admin_form_ui
|
||||
}
|
||||
*/
|
||||
$selected = varset($obj->current[$module]) == $location ? "selected='selected'" : '';
|
||||
$opt .= "<option value='{$location}' {$selected} >".$diz.": ".$exampleUrl[0]."</option>";
|
||||
$opt .= "<option value='{$location}' {$selected} >".$diz.": ".varset($exampleUrl[0])."</option>";
|
||||
|
||||
$info .= "<tr><td>".$label."
|
||||
|
||||
@@ -909,10 +909,10 @@ class eurl_admin_form_ui extends e_admin_form_ui
|
||||
<td><select name='eurl_config[$module]' class='form-control input-block-level'>".$opt."</select></td>
|
||||
<td>";
|
||||
|
||||
$bTable = ($admin['generate']['table']);
|
||||
$bInput = $admin['generate']['input'];
|
||||
$bOutput = $admin['generate']['output'];
|
||||
$bPrimary = $admin['generate']['primary'];
|
||||
$bTable = varset($admin['generate']['table']);
|
||||
$bInput = varset($admin['generate']['input']);
|
||||
$bOutput = varset($admin['generate']['output']);
|
||||
$bPrimary = varset($admin['generate']['primary']);
|
||||
|
||||
|
||||
$text .= (is_array($admin['generate'])) ? $frm->admin_button('rebuild['.$bTable.']', $bPrimary."::".$bInput."::".$bOutput,'delete', LAN_EURL_REBUILD) : "";
|
||||
|
@@ -147,7 +147,7 @@ elseif(isset($_POST['fp_dec']))
|
||||
}
|
||||
*/
|
||||
|
||||
if (isset($_POST))
|
||||
if (!empty($_POST))
|
||||
{
|
||||
|
||||
// avoid endless loop.
|
||||
|
@@ -73,6 +73,7 @@ $meta_copyright = vartrue($pref['meta_copyright'], array());
|
||||
$meta_author = vartrue($pref['meta_author'], array());
|
||||
|
||||
|
||||
|
||||
$text = "
|
||||
<form method='post' action='".e_SELF."' id='dataform'>
|
||||
<fieldset id='core-meta-settings'>
|
||||
@@ -86,32 +87,32 @@ $text = "
|
||||
<tr>
|
||||
<td>".LAN_DESCRIPTION."</td>
|
||||
<td>";
|
||||
$text .= $frm->textarea('meta_description',$tp->toForm($meta_diz[e_LANGUAGE]),3,80, array('size'=>'xxlarge'));
|
||||
$text .= $frm->textarea('meta_description',$tp->toForm(varset($meta_diz[e_LANGUAGE])),3,80, array('size'=>'xxlarge'));
|
||||
// $text .= "<textarea class='tbox textarea e-autoheight' id='meta_description' name='meta_description' cols='70' rows='4'>".$tp->toForm(varset($meta_diz[e_LANGUAGE]))."</textarea>";
|
||||
$text .= "</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>".LAN_KEYWORDS."</td>
|
||||
<td>";
|
||||
$text .= $frm->tags('meta_keywords',$tp->toForm($meta_keywords[e_LANGUAGE]));
|
||||
$text .= $frm->tags('meta_keywords',$tp->toForm(varset($meta_keywords[e_LANGUAGE])));
|
||||
// $text .= "<textarea class='tbox textarea e-autoheight' id='meta_keywords' name='meta_keywords' cols='70' rows='4'>".$tp->toForm(varset($meta_keywords[e_LANGUAGE]))."</textarea>";
|
||||
|
||||
$text .= "</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>".LAN_COPYRIGHT."</td>
|
||||
<td><input class='tbox form-control input-xxlarge' size='70' type='text' name='meta_copyright' value=\"".$meta_copyright[e_LANGUAGE]."\" /></td>
|
||||
<td><input class='tbox form-control input-xxlarge' size='70' type='text' name='meta_copyright' value=\"".varset($meta_copyright[e_LANGUAGE])."\" /></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>".LAN_AUTHOR."</td>
|
||||
<td><input class='tbox form-control input-xxlarge' size='70' type='text' name='meta_author' value=\"".$meta_author[e_LANGUAGE]."\" /></td>
|
||||
<td><input class='tbox form-control input-xxlarge' size='70' type='text' name='meta_author' value=\"".varset($meta_author[e_LANGUAGE])."\" /></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>".METLAN_1."</td>
|
||||
<td>";
|
||||
$text .= $frm->textarea('meta',str_replace("<","<",$tp->toForm($meta[e_LANGUAGE])),5,100,'size=block-level');
|
||||
$text .= $frm->textarea('meta',str_replace("<","<",$tp->toForm(varset($meta[e_LANGUAGE]))),5,100,'size=block-level');
|
||||
|
||||
$text .= "<span class='field-help'>".METLAN_2."</span>";
|
||||
|
||||
@@ -141,4 +142,3 @@ $ns->tablerender(METLAN_00." (".e_LANGUAGE.")", $mes->render().$text);
|
||||
|
||||
require_once("footer.php");
|
||||
|
||||
?>
|
@@ -831,7 +831,7 @@ class theme_admin_online_tree_model extends e_tree_model
|
||||
'thumbnail' => $r['thumbnail'],
|
||||
'url' => $r['urlView'],
|
||||
'author' => $r['author'],
|
||||
'website' => $r['authorUrl'],
|
||||
'website' => varset($r['authorUrl']),
|
||||
'compatibility' => $r['compatibility'],
|
||||
'description' => $r['description'],
|
||||
'price' => $r['price'],
|
||||
@@ -958,6 +958,8 @@ class theme_admin_form_ui extends e_admin_form_ui
|
||||
$version = $tp->filter(e_VERSION,'version');
|
||||
$compat = $tp->filter($theme['compatibility'], 'version');
|
||||
|
||||
|
||||
|
||||
$disabled = '';
|
||||
$mainTitle = TPVLAN_10;
|
||||
|
||||
@@ -1066,8 +1068,10 @@ class theme_builder extends e_admin_ui
|
||||
|
||||
e107::getMessage()->addDebug("Disable debug to save generated files. ");
|
||||
|
||||
|
||||
$this->themeName = $tp->filter($_GET['newtheme'],'w');
|
||||
if(!empty($_GET['newtheme']))
|
||||
{
|
||||
$this->themeName = $tp->filter($_GET['newtheme'],'w');
|
||||
}
|
||||
|
||||
if(!empty($_GET['src']))
|
||||
{
|
||||
|
@@ -7079,7 +7079,7 @@ var_dump($select_options);*/
|
||||
{
|
||||
$key = strtoupper($k);
|
||||
$fields[$v]['grid'] = true;
|
||||
$vars[$key] = $this->renderValue($v,$data[$v],$fields[$v],$id);
|
||||
$vars[$key] = $this->renderValue($v, varset($data[$v]), $fields[$v], $id);
|
||||
}
|
||||
|
||||
$cells[] = "<div class='".$cls." admin-ui-grid'>". $tp->simpleParse($template,$vars). '</div>';
|
||||
|
@@ -984,17 +984,18 @@ class e_library_manager
|
||||
$library['installed'] = false;
|
||||
|
||||
// Check whether the library exists.
|
||||
if(!isset($library['library_path']))
|
||||
if(!isset($library['library_path']) && !empty($library['machine_name']))
|
||||
{
|
||||
$library['library_path'] = $this->detectPath($library['machine_name']);
|
||||
}
|
||||
|
||||
$libraryPath = e107::getParser()->replaceConstants($library['library_path']);
|
||||
if($library['library_path'] === false || (!file_exists($libraryPath) && substr($libraryPath, 0, 4) != 'http'))
|
||||
$libraryPath = !empty($library['library_path']) ? e107::getParser()->replaceConstants($library['library_path']) : '';
|
||||
|
||||
if(empty($library['library_path']) || (!empty($libraryPath) && !file_exists($libraryPath) && substr($libraryPath, 0, 4) != 'http'))
|
||||
{
|
||||
$library['error'] = LAN_NOT_FOUND;
|
||||
|
||||
$replace_with = array($library['name']);
|
||||
$replace_with = array($name);
|
||||
$library['error_message'] = e107::getParser()->lanVars(LAN_LIBRARY_MANAGER_03, $replace_with, true);
|
||||
|
||||
return $library;
|
||||
|
@@ -2248,7 +2248,7 @@ class mailoutAdminClass extends e107MailManager
|
||||
$text .= "<tr>
|
||||
<td><label for='smtp_keepalive'>" . LAN_MAILOUT_57 . "</label></td><td>\n";
|
||||
|
||||
$text .= $frm->radio_switch('smtp_keepalive', $pref['smtp_keepalive']) . "
|
||||
$text .= $frm->radio_switch('smtp_keepalive', varset($pref['smtp_keepalive'])) . "
|
||||
</td>
|
||||
</tr>";
|
||||
|
||||
|
@@ -1397,7 +1397,7 @@ i.e-cat_users-32{ background-position: -555px 0; width: 32px; height: 32px; }
|
||||
//XXX && !is_numeric($act) ???
|
||||
if (($active_page == (string) $act)
|
||||
|| (str_replace("?", "", e_PAGE.e_QUERY) == str_replace("?", "", $act))
|
||||
|| e_REQUEST_HTTP === $e107_vars[$act]['link']
|
||||
|| e_REQUEST_HTTP === varset($e107_vars[$act]['link'])
|
||||
)
|
||||
{
|
||||
$temp = $tmpl['button_active'.$kpost];
|
||||
|
@@ -830,6 +830,7 @@ class e_theme
|
||||
// print_a($lays);
|
||||
$themeArray['legacy'] = true;
|
||||
$themeArray['html'] = false;
|
||||
$themeArray['compatibility'] = '1';
|
||||
|
||||
return $themeArray;
|
||||
}
|
||||
|
@@ -47,6 +47,33 @@ class e107_user_extended
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$constants = array(
|
||||
'EUF_CATEGORY' => 0,
|
||||
'EUF_TEXT' => 1,
|
||||
'EUF_RADIO' => 2,
|
||||
'EUF_DROPDOWN' => 3,
|
||||
'EUF_DB_FIELD' => 4,
|
||||
'EUF_TEXTAREA' => 5,
|
||||
'EUF_INTEGER' => 6,
|
||||
'EUF_DATE' => 7,
|
||||
'EUF_LANGUAGE' => 8,
|
||||
'EUF_PREDEFINED' => 9, // should be EUF_LIST IMO
|
||||
'EUF_CHECKBOX' => 10,
|
||||
'EUF_PREFIELD' => 11, // should be EUF_PREDEFINED => useful when creating fields from e.g. plugin XML
|
||||
'EUF_ADDON' => 12, // defined within e_user.php addon @todo
|
||||
'EUF_COUNTRY' => 13, // $frm->country()
|
||||
'EUF_RICHTEXTAREA' => 14, // $frm->bbarea()
|
||||
);
|
||||
|
||||
foreach($constants as $def => $val)
|
||||
{
|
||||
if(!defined($def))
|
||||
{
|
||||
define($def, $val);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
@define('EUF_CATEGORY', 0);
|
||||
@define('EUF_TEXT',1);
|
||||
@define('EUF_RADIO',2);
|
||||
@@ -61,7 +88,7 @@ class e107_user_extended
|
||||
@define('EUF_PREFIELD',11); // should be EUF_PREDEFINED, useful when creating fields from e.g. plugin XML
|
||||
@define('EUF_ADDON', 12); // defined within e_user.php addon @todo
|
||||
@define('EUF_COUNTRY', 13); // $frm->country()
|
||||
@define('EUF_RICHTEXTAREA', 14); // $frm->bbarea()
|
||||
@define('EUF_RICHTEXTAREA', 14); // $frm->bbarea()*/
|
||||
|
||||
$this->typeArray = array(
|
||||
'text' => EUF_TEXT,
|
||||
|
@@ -469,7 +469,8 @@ class user_class
|
||||
if(is_array($extra_js))
|
||||
{
|
||||
$options = $extra_js;
|
||||
unset($extra_js);
|
||||
$extra_js = '';
|
||||
|
||||
}
|
||||
|
||||
$class = "tbox form-control";
|
||||
|
@@ -150,7 +150,7 @@ class news_sitelink // include plugin-folder in the name.
|
||||
'link_order' => '',
|
||||
'link_parent' => '',
|
||||
'link_open' => '',
|
||||
'link_class' => intval($row['news_class'])
|
||||
'link_class' => 0
|
||||
);
|
||||
|
||||
|
||||
|
@@ -419,7 +419,7 @@ class social_ui extends e_admin_ui
|
||||
<tr>
|
||||
<td><label for='".$text_label."'>".LAN_SOCIAL_ADMIN_11." ".$var['label']." ".LAN_SOCIAL_ADMIN_12."</label></td>
|
||||
<td>
|
||||
".$frm->text($keypref, $pref['xurl'][$k], false, $opts)."
|
||||
".$frm->text($keypref, varset($pref['xurl'][$k]), false, $opts)."
|
||||
<div class='field-help'>".LAN_SOCIAL_ADMIN_13." ".$var['label']." ".LAN_SOCIAL_ADMIN_12." (".$def.")</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
Reference in New Issue
Block a user