PHPFusion Dynamic Menu System v1.55 PL
|
dex |
Dodany dnia 17.06.2007 00:47:10
|
Początkujący
Postów: 212
Data rejestracji: 16.08.2006 15:18
|
Poniżej zamieszczam spolszczoną wersję dynamicznej nawigacji w PHP-Fusion, dodam na wstępie, że instalacja może przysporzyć problemów świeżym użytkownikom PHP-Fusion, ale o tym później.
Tak jak jest napisane w README, wtyczka pod FireFox'em wyświetla tylko poprawnie pod-menu do 2 poziomu, pod IE w nieskończoność, ale mam nadzieję, że nasz Support upora się z tym problemem.
Dla tych, którzy instalowali wtyczkę ze strony autora info o tym co trzeba poprawić w plikach:
W includes\pfmenu\pfmenu_functions_include.php
Pierwszą linię zamieniamy na:
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">
W infusions\navigation_panel\navigation_panel.php linię 16 zamieniamy na:
$result = dbquery("SELECT * FROM ".$db_prefix."site_links WHERE link_position<='2' ORDER BY link_order" ;
Do folderu locale dogrywamy w katalogu Polish/Admin plik settings.php
Użytkownicy instalujący wtyczkę stąd mają to już gratis zrobione [joke]
EDYCJA THEME.PHP
Musimy w naszym theme.php dodać następujące wpisy:
require_once INCLUDES."pfmenu/pfmenu_functions_include.php";
echo "<link rel='stylesheet' href='".THEME."xxpfmenu.css' type='text/css'>\n";
oraz nad funkcją render_footer:
GenerateMenu();
/* $result = dbquery("SELECT * FROM ".DB_PREFIX."site_links WHERE link_position>='2' ORDER BY link_order");
if (dbrows($result) != 0) {
$i = 0;
while($data = dbarray($result)) {
if (checkgroup($data['link_visibility'])) {
if ($data['link_url']!="---") {
if ($i != 0) { echo " <font color='#2a2a28'>|</font>\n"; } else { echo "\n"; }
$link_target = ($data['link_window'] == "1" ? " target='_blank'" : "");
if (strstr($data['link_url'], "http://") || strstr($data['link_url'], "https://")) {
echo "<a href='".$data['link_url']."'".$link_target." class='white'>".$data['link_name']."</a>";
} else {
echo "<a href='".BASEDIR.$data['link_url']."'".$link_target." class='white'>".$data['link_name']."</a>";
}
}
$i++;
}
}
}
echo ($i == 0 ? " " : "")."*/
echo "</td>\n";
echo "<td align='right' class='header1'>".showsubdate()."</td>\n";
echo "</tr></table>\n";
echo "<table width='100%' cellspacing='0' cellpadding='0'><tr>\n";
Jako drugi gratis dokładam poprawione theme.php dla skórki Similitude06 wraz ze standardowym xxpfmenu.css, który możecie dowolnie zmieniać.
Dynamiczne menu w działaniu można obejrzeć tu:
http://someone.ed...Y/news.php
dex dodał/a następującą plik:
Edytowane przez Pieka dnia 23.10.2007 20:01:30
|
|
|
|
Wścibski Gość |
Dodany dnia 22.11.2024 15:26:12
|
Pan Kontekstualny
Postów: n^x
Data rejestracji: Zawsze
|
|
IP: localhost |
|
|
Pieka |
Dodany dnia 17.06.2007 11:03:46
|
Postów: 19882 Pomógł: 767
v7.02.03 Data rejestracji: 23.02.2005 18:12
|
Rozumiem, ze to jest wersja sprawdzona i w pelni dzialajaca?
Fajnie, ze zajales sie sprawdzaniem, poprawianiem i tlumaczeniem, ale pamietaj, ze ten dzial nie sluzy wstawianiu nowych inf/mod, masz od tego dzial, do ktorego przenosze temat i przyklejma.
Edytowane przez Pieka dnia 17.06.2007 12:39:41
Jestem jaki jestem
|
|
|
|
rokrzy |
Dodany dnia 13.10.2007 13:55:14
|
Przedszkolak
Postów: 16
Data rejestracji: 26.09.2007 14:01
|
Edit:
Spoko , wszystko zrobiłem tak jak było napisane w instrukcji, ale mam nadal problem. Niewiem co mam zrobić by menu to znalazło się na mojej stronie. Czy może mi ktoś wytłumaczyc co mam zrobić by było widoczne?
Edytowane przez rokrzy dnia 13.10.2007 15:25:59
|
|
|
|
tytus |
Dodany dnia 20.10.2007 17:30:37
|
Przedszkolak
Postów: 23 Ostrzeżeń: 6
Data rejestracji: 19.06.2007 18:12
Złamana licencja
|
Wszystko ok ...robilem tak jak mi kazaliscie a nic z tego...Czy znalazlby sie taki uzytkownik ktory bi mi to zrobil ...Hasla admina i do ftp podam na pw...Autor dostanie wpis w sekcji autor na www.lukswola.xx.pl
Edytowane przez Milka dnia 20.10.2007 21:26:11
|
|
|
|
refund |
Dodany dnia 21.12.2007 23:52:58
|
Przedszkolak
Postów: 2
Data rejestracji: 28.11.2007 10:10
|
Witam mam problem z dzialaniem dynamicznego menu na nazwa.pl - pojawia się coś takiego:
110 || $size['1'] > 50) { unlink($way.$buttonimage); } } else { unlink($way.$buttonimage); } } } if (isset($_POST['del_image'])) { $buttonimage = ""; unlink($way.$data['buttonimage']); } $AddQuery = "INSERT INTO ".DB_PREFIX."pfmenu (`menu_id`, `buttonlink`, `buttontarget`, `buttonname`, `buttonimage`, `buttonorder`, `buttonvisibility`, `locale`, `fathermenu`, `menumaster`) "; $AddQuery .= "VALUES "; $AddQuery .= "('$menu_id', '$buttonlink', '$buttontarget', '$buttonname', '$buttonimage', '$buttonorder', '$buttonvisibility', '$lang', '$fatherID', '$menumaster');"; //die($AddQuery); $result = dbquery($AddQuery); redirect(FUSION_SELF."?op="); } function DoMenuEditAction($menu_id) { global $settings,$way; $buttonimage = $_POST['buttonimage']; $buttonlink = $_POST['buttonlink']; $buttontarget = $_POST['buttontarget']; $buttonname = $_POST['buttonname']; $buttonvisibility = $_POST['buttonvisibility']; $lang = $settings['locale']; $fatherID = $_POST['fatherID']; $menumaster = $_POST['menumaster']; $BI_new = $_FILES['buttonimage']; if ($_POST['buttonimage'] == "") {$buttonimage = "";} if ($buttonimage == "" && !empty($BI_new['name']) && is_uploaded_file($BI_new['tmp_name'])) { $buttonimage = ""; $BI_ext = strrchr($BI_new['name'],"."); $BI_name = substr($BI_new['name'], 0, strrpos($BI_new['name'], ".")); if (preg_match("/^[-0-9A-Z_\[\]]+$/i", $BI_name) && preg_match("/(\.gif|\.GIF|\.jpg|\.JPG|\.png|\.PNG)$/", $BI_ext) && $BI_new['size'] <= 30720) { $buttonimage = $BI_name.$BI_ext; move_uploaded_file($BI_new['tmp_name'], $way.$buttonimage); chmod($way.$buttonimage,0644); if ($size = @getimagesize($way.$buttonimage)) { if ($size['0'] > 110 || $size['1'] > 50) { unlink($way.$buttonimage); } } else { unlink($way.$buttonimage); } } } if (isset($_POST['del_image'])) { $buttonimage = ""; unlink($way.$_POST['buttonimage']); } $EditQuery = "UPDATE ".DB_PREFIX."pfmenu SET buttonlink='$buttonlink', buttontarget='$buttontarget', buttonvisibility='$buttonvisibility', buttonname='$buttonname', buttonimage='$buttonimage', locale='$lang', fathermenu='$fatherID', menumaster='$menumaster' WHERE menu_id='".$menu_id."'"; //die($EditQuery); $result = dbquery($EditQuery); redirect(FUSION_SELF."?op="); } function DoMenuDeleteAction($menu_id) { $delrefresh = dbquery("SELECT * FROM ".DB_PREFIX."pfmenu WHERE fathermenu='".$menu_id."'"); if (dbrows($delrefresh) > 0) { redirect(FUSION_SELF."?pf_err=d"); } else { $result = dbquery("DELETE FROM ".DB_PREFIX."pfmenu WHERE menu_id='".$menu_id."'"); DoMenuRefresh(); } } function DoMenuRefresh() { global $settings; $resrefresh = dbquery("SELECT * FROM ".DB_PREFIX."pfmenu WHERE locale='".$settings['locale']."' "); while ($datarefresh = dbarray($resrefresh)) { $key = $datarefresh['fathermenu']; $i = 1; $result2 = dbquery("SELECT * FROM ".DB_PREFIX."pfmenu WHERE fathermenu='$key' AND locale='".$settings['locale']."' ORDER BY buttonorder ASC"); while ($data = dbarray($result2)) { $query = "UPDATE ".DB_PREFIX."pfmenu SET buttonorder='".$i."' WHERE fathermenu='".$key."' AND menu_id='".$data['menu_id']."'"; $resupdate = dbquery($query); echo "QUERY ==> ".$query. "
"; $i++; } } redirect(FUSION_SELF."?op="); } function DoMenuAdd() { global $settings,$locale,$way,$separator,$op; $menu_id = ""; $buttonlink = ""; $buttontarget = ""; $buttonname = ""; $buttonimage = ""; $buttonorder = ""; $buttonvisibility = ""; $lang = $settings['locale']; $fatherID = ""; $menumaster = ""; $user_groups = getusergroups(); $access_opts = ""; $father_list = ""; while(list($key, $user_group) = each($user_groups)){ $sel = ($buttonvisibility == $user_group['0'] ? " selected" : ""); $access_opts .= "".$user_group['1']."\n"; } If ($separator == 'x') { $buttonlink = "SEP"; $sel_sep1 = " selected"; } else { $buttonlink = ""; $sel_sep2 = " selected"; $father_list .= " -- Main Bar -- \n"; } $resfather = dbquery("SELECT * FROM ".DB_PREFIX."pfmenu WHERE menumaster='x' AND locale='".$settings['locale']."'"); while ($datfather = dbarray($resfather)) { $sel = ($fatherID == $datfather['menu_id'] ? " selected" : ""); $father_list .= "".$datfather['menu_id']." -- ".$datfather['buttonname']."\n"; } if( $buttontarget == '') { $sel_None = " selected"; } if( $buttontarget == '_blank') { $sel_blank = " selected"; } if( $buttontarget == '_self') { $sel_self = " selected"; } if( $buttontarget == '_parent') { $sel_parent = " selected"; } if( $buttontarget == '_top') { $sel_top = " selected"; } if( $buttontarget == '_search') { $sel_search = " selected"; } $target_list .= "None\n"; $target_list .= "_blank\n"; $target_list .= "_self\n"; $target_list .= "_parent\n"; $target_list .= "_top\n"; $target_list .= "_search\n"; echo "\n"; echo "\n"; echo "
".$locale['PFM401']."
\n"; echo "\n"; echo "\n"; echo "\n"; If ($separator == 'x') { echo "\n"; echo "\n"; echo "\n"; } else { echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; } echo "\n"; echo "
".$locale['PFM308']." \n"; echo "
\n"; echo " ".$locale['PFM418']."
".$locale['PFM402']." ".$locale['PFM409']."
".$locale['PFM405']."
".$locale['PFM401']." ".$locale['PFM409']."
".$locale['PFM402']." ".$locale['PFM403']."
".$locale['PFM408']." \n"; echo " ".sprintf($locale['PFM415'], parsebytesize(30720))."
\n"; echo "".sprintf($locale['PFM416'], 110, 50)."\n"; echo "
".$locale['PFM405']."
".$locale['PFM410']." ".$locale['PFM414']."
\n"; echo "
\n"; tablebreak();tablebreak(); echo "\n"; echo "\n"; echo "\n"; echo ""; } function DoMenuEdit() { global $settings,$locale,$menu_id,$way; $data = dbarray(dbquery("SELECT * FROM ".DB_PREFIX."pfmenu WHERE menu_id='".$menu_id."'")); $buttonID = $data['menu_id']; $buttonlink = $data['buttonlink']; $buttontarget = $data['buttontarget']; $buttonname = $data['buttonname']; $buttonimage = $data['buttonimage']; $buttonorder = $data['buttonorder']; $buttonvisibility = $data['buttonvisibility']; $lang = $data['locale']; $fatherID = $data['fathermenu']; $menumaster = $data['menumaster']; $user_groups = getusergroups(); $access_opts = ""; $father_list = ""; $target_list = ""; while(list($key, $user_group) = each($user_groups)){ $sel = ($buttonvisibility == $user_group['0'] ? " selected" : ""); $access_opts .= "".$user_group['1']."\n"; } $father_list .= " -- Main Bar -- \n"; $resfather = dbquery("SELECT * FROM ".DB_PREFIX."pfmenu WHERE menumaster='x' AND locale='".$settings['locale']."'"); while ($datfather = dbarray($resfather)) { $sel = ($fatherID == $datfather['menu_id'] ? " selected" : ""); $father_list .= "".$datfather['menu_id']." -- ".$datfather['buttonname']."\n"; } if( $buttontarget == '') { $sel_None = " selected"; } if( $buttontarget == '_blank') { $sel_blank = " selected"; } if( $buttontarget == '_self') { $sel_self = " selected"; } if( $buttontarget == '_parent') { $sel_parent = " selected"; } if( $buttontarget == '_top') { $sel_top = " selected"; } if( $buttontarget == '_search') { $sel_search = " selected"; } $target_list .= "None\n"; $target_list .= "_blank\n"; $target_list .= "_self\n"; $target_list .= "_parent\n"; $target_list .= "_top\n"; $target_list .= "_search\n"; echo "
\n"; echo "\n"; echo "\n"; echo "
A to zbyt wiele dla mnie :(
Edytowane przez Pieka dnia 22.12.2007 00:12:57
|
|
|
|
kraski1 |
Dodany dnia 31.12.2007 19:48:44
|
Początkujący
Postów: 115
Data rejestracji: 25.02.2007 15:02
|
Mi nie chce zadziałać kraski.isx.pl/pship
<?php
/*--------------------------------------------+
| PHP-Fusion v6 - Content Management System |
|---------------------------------------------|
| author: Nick Jones (Digitanium) © 2002-2005 |
| web: http://www.php-fusion.co.uk |
| email: |
|---------------------------------------------|
| Released under the terms and conditions of |
| the GNU General Public License (Version 2) |
+--------------------------------------------*/
/*--------------------------------------------+
| Valencia Theme for PHP-Fusion v6 |
|---------------------------------------------|
| author: PHP-Fusion Themes - Shedrock © 2005 |
| web: http://phpfusion.org |
| email: |
|---------------------------------------------|
| Released under the terms and conditions of |
| the GNU General Public License (Version 2) |
+--------------------------------------------*/
// theme settings
$body_text = "#000000";
$body_bg = "#FFFFFF";
$theme_width = "70%";
$theme_width_l = "180";
$theme_width_r = "180";
function render_header($header_content) {
global $theme_width,$settings;
require_once INCLUDES."pfmenu/pfmenu_functions_include.php";
echo "<link rel='stylesheet' href='".THEME."xxpfmenu.css' type='text/css'>\n";
echo "<table align='center' width='$theme_width' class='bodyline' cellspacing='0' cellpadding='0' border='0'>";
echo "<tr><td>";
echo "<table width='100%' border='0' cellspacing='0' cellpadding='0'><tr>";
echo "<td valign='middle' width='100%' style='background-image:url(".THEME."images/logo_bg.gif)' height='85'>";
// Start banner code
echo "<table width='100%' cellspacing='0' cellpadding='4'>";
echo "<tr><td width='100%'>$header_content</td>";
echo "</tr></table>";
// End banner code
echo "</td></tr></table>";
echo "<table width='100%' border='0' cellspacing='0' cellpadding='0'><tr>";
echo "<td height='24'><table width='100%' border='0' cellpadding='4' cellspacing='0'><tr><td class='nav-header'>\n";
echo showsublinks("<img border='0' src='".THEME."images/divider.gif'>","white")."</td>\n";
echo "<td align='right' class='nav-header'>".showsubdate()."</td></tr></table>";
echo "<table width='100%' cellspacing='5' cellpadding='0'>\n<tr>\n";
}
[color=red]GenerateMenu();
/* $result = dbquery("SELECT * FROM ".DB_PREFIX."site_links WHERE link_position>='2' ORDER BY link_order");
if (dbrows($result) != 0) {
$i = 0;
while($data = dbarray($result)) {
if (checkgroup($data['link_visibility'])) {
if ($data['link_url']!="---") {
if ($i != 0) { echo " <font color='#2a2a28'>|</font>\n"; } else { echo "\n"; }
$link_target = ($data['link_window'] == "1" ? " target='_blank'" : "");
if (strstr($data['link_url'], "http://") || strstr($data['link_url'], "https://")) {
echo "<a href='".$data['link_url']."'".$link_target." class='white'>".$data['link_name']."</a>";
} else {
echo "<a href='".BASEDIR.$data['link_url']."'".$link_target." class='white'>".$data['link_name']."</a>";
}
}
$i++;
}
}
}
echo ($i == 0 ? " " : "")."*/
echo "</td>\n";
echo "<td align='right' class='header1'>".showsubdate()."</td>\n";
echo "</tr></table>\n";
echo "<table width='100%' cellspacing='0' cellpadding='0'><tr>\n";
}[/color]
function render_footer($license=false) {
global $theme_width,$locale,$settings;
echo "</tr>\n</table>\n";
echo "<table align='center' width='$theme_width' cellspacing='0' cellpadding='0'>";
echo "<tr><td>".stripslashes($settings['footer'])."</td></tr></table><br>\n";
echo "<table align='center' border='0' cellpadding='0' cellspacing='0' width='100%'>";
echo "<tr><td width='15'></td>";
echo "<td class='footer' align='left' width='38%'>";
if ($license == false) {
echo "Powered by <a href='http://www.php-fusion.co.uk' target='_blank'>PHP-Fusion</a> © 2003-2006";
}
echo "</td>";
echo "<td class='footer' align='center' width='24%'>Valencia Theme by: <a href='http://www.phpfusion-themes.com' target='_blank'>PHP-Fusion Themes</a>";
echo "</td>";
echo "<td class='footer' align='right' width='38%'>";
echo "<strong>".$settings['counter']." </strong>".($settings['counter'] == 1 ? $locale['140']."\n" : $locale['141']."\n");
echo "</td></tr></table></td></tr></table></td></tr></table>";
}
function render_news($subject, $news, $info) {
global $locale;
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='panel-left3'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td width='100%' class='panel-main3'>$subject</td>";
echo "<td class='panel-right3'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left3'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='news-body'><div style='width:100%;vertical-align:top;'>$news</div><br>";
echo "<div style='margin-top:5px'>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='infobar'>".newsposter($info)."</td>";
echo "<td align='right' class='infobar2'>";
echo openform("N",$info['news_id']).newsopts($info,"·").closeform("N",$info['news_id']);
echo "</td></tr></table></div></td>";
echo "<td class='border-right3'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'>";
echo "</td></tr><tr>";
echo "<td class='border-bleft3'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain3'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright3'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
}
function render_article($subject, $article, $info) {
global $locale;
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='panel-left4'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td width='100%' class='panel-main4'>$subject</td>";
echo "<td class='panel-right4'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left4'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='side-bodyx'><div style='width:100%;vertical-align:top;'>".($info['article_breaks'] == "y" ? nl2br($article) : $article)."</div><br>";
echo "<div style='margin-top:5px'>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='infobar3'>".articleposter($info)."</td>";
echo "<td align='right' class='infobar4'>";
echo openform("A",$info['article_id']).articleopts($info,"·").closeform("A",$info['article_id']);
echo "</td></tr></table></div></td>";
echo "<td class='border-right4'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "</tr><tr>";
echo "<td class='border-bleft4'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain4'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright4'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
}
function opentable($title) {
echo "<table width='100%' cellpadding='0' cellspacing='0'>";
echo "<tr><td class='panel-left2'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td width='100%' class='panel-main2'>$title</td>";
echo "<td class='panel-right2'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left2'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='table-body'>\n";
}
function closetable() {
echo "</td>";
echo "<td class='border-right2'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td></tr>";
echo "<tr>";
echo "<td class='border-bleft2'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain2'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright2'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
}
function openside($title) {
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='panel-left'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td width='100%' class='panel-main'>$title</td>";
echo "<td class='panel-right'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='side-body'>\n";
}
function closeside() {
echo "</td>";
echo "<td class='border-right'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td></tr>";
echo "<tr>";
echo "<td class='border-bleft'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
tablebreak();
}
function opensidex($title,$open="on") {
$boxname = str_replace(" ", "", $title);
$box_img = $open == "on" ? "off" : "on";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='panel-left4'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td class='panel-main4'>$title</td>";
echo "<td align='right' class='panel-main4'><img src='".THEME."images/panel_$box_img.gif' name='b_$boxname' alt='' onclick=\"javascript:flipBox('$boxname')\"></td>";
echo "<td class='panel-right4'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left4'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='side-bodyx'>";
echo "<div id='box_$boxname'".($open=="off" ? "style='display:none'" : "").">\n";
}
function closesidex() {
echo "</div>";
echo "<td class='border-right4'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td></tr>";
echo "<tr>";
echo "<td class='border-bleft4'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain4'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright4'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
}
function tablebreak() {
echo "<table width='100%' cellspacing='0' cellpadding='0'>";
echo "<tr><td></td></tr></table>\n";
}
?>
PW od moderatora:
- Odświeżenie Tematu - Pieka 03.01 - 18:50
Edytowane przez kraski1 dnia 03.01.2008 19:28:35
|
|
|
|
bartek124 |
Dodany dnia 03.01.2008 19:08:13
|
Weteran
Postów: 3264 Pomógł: 236
v7.02.06 Data rejestracji: 26.05.2007 12:25
|
Wywala coś? Błąd?
Nie pomagam na komunikatorach oraz PW!
|
|
|
|
kraski1 |
Dodany dnia 03.01.2008 19:26:25
|
Początkujący
Postów: 115
Data rejestracji: 25.02.2007 15:02
|
Parse error: syntax error, unexpected '}' in /home/kraski/public_html/pship/themes/Valencia/theme.php on line 76
Sory zapomniałem zmienić szablon domyślny.
|
|
|
|
bartek124 |
Dodany dnia 03.01.2008 19:35:38
|
Weteran
Postów: 3264 Pomógł: 236
v7.02.06 Data rejestracji: 26.05.2007 12:25
|
<?php
/*--------------------------------------------+
| PHP-Fusion v6 - Content Management System |
|---------------------------------------------|
| author: Nick Jones (Digitanium) © 2002-2005 |
| web: http://www.php-fu... |
| email: |
|---------------------------------------------|
| Released under the terms and conditions of |
| the GNU General Public License (Version 2) |
+--------------------------------------------*/
/*--------------------------------------------+
| Valencia Theme for PHP-Fusion v6 |
|---------------------------------------------|
| author: PHP-Fusion Themes - Shedrock © 2005 |
| web: http://phpfusion.org |
| email: |
|---------------------------------------------|
| Released under the terms and conditions of |
| the GNU General Public License (Version 2) |
+--------------------------------------------*/
// theme settings
$body_text = "#000000";
$body_bg = "#FFFFFF";
$theme_width = "70%";
$theme_width_l = "180";
$theme_width_r = "180";
function render_header($header_content) {
global $theme_width,$settings;
require_once INCLUDES."pfmenu/pfmenu_functions_include.php";
echo "<link rel='stylesheet' href='".THEME."xxpfmenu.css' type='text/css'>\n";
echo "<table align='center' width='$theme_width' class='bodyline' cellspacing='0' cellpadding='0' border='0'>";
echo "<tr><td>";
echo "<table width='100%' border='0' cellspacing='0' cellpadding='0'><tr>";
echo "<td valign='middle' width='100%' style='background-image:url(".THEME."images/logo_bg.gif)' height='85'>";
// Start banner code
echo "<table width='100%' cellspacing='0' cellpadding='4'>";
echo "<tr><td width='100%'>$header_content</td>";
echo "</tr></table>";
// End banner code
echo "</td></tr></table>";
echo "<table width='100%' border='0' cellspacing='0' cellpadding='0'><tr>";
echo "<td height='24'><table width='100%' border='0' cellpadding='4' cellspacing='0'><tr><td class='nav-header'>\n";
echo showsublinks("<img border='0' src='".THEME."images/divider.gif'>","white")."</td>\n";
echo "<td align='right' class='nav-header'>".showsubdate()."</td></tr></table>";
echo "<table width='100%' cellspacing='5' cellpadding='0'>\n<tr>\n";
}
function GenerateMenu() {
$result = dbquery("SELECT * FROM ".DB_PREFIX."site_links WHERE link_position>='2' ORDER BY link_order");
if (dbrows($result) != 0) {
$i = 0;
while($data = dbarray($result)) {
if (checkgroup($data['link_visibility'])) {
if ($data['link_url']!="---") {
if ($i != 0) { echo " <font color='#2a2a28'>|</font>\n"; } else { echo "\n"; }
$link_target = ($data['link_window'] == "1" ? " target='_blank'" : "");
if (strstr($data['link_url'], "http://") || strstr($data['link_url'], "https://")) {
echo "<a href='".$data['link_url']."'".$link_target." class='white'>".$data['link_name']."</a>";
} else {
echo "<a href='".BASEDIR.$data['link_url']."'".$link_target." class='white'>".$data['link_name']."</a>";
}
}
$i++;
}
}
}
echo ($i == 0 ? " " : "");
echo "</td>\n";
echo "<td align='right' class='header1'>".showsubdate()."</td>\n";
echo "</tr></table>\n";
echo "<table width='100%' cellspacing='0' cellpadding='0'><tr>\n";
}
function render_footer($license=false) {
global $theme_width,$locale,$settings;
echo "</tr>\n</table>\n";
echo "<table align='center' width='$theme_width' cellspacing='0' cellpadding='0'>";
echo "<tr><td>".stripslashes($settings['footer'])."</td></tr></table><br>\n";
echo "<table align='center' border='0' cellpadding='0' cellspacing='0' width='100%'>";
echo "<tr><td width='15'></td>";
echo "<td class='footer' align='left' width='38%'>";
if ($license == false) {
echo "Powered by <a href='http://www.php-fusion.co.uk' target='_blank'>PHP-Fusion</a> © 2003-2006";
}
echo "</td>";
echo "<td class='footer' align='center' width='24%'>Valencia Theme by: <a href='http://www.phpfusion-themes.com' target='_blank'>PHP-Fusion Themes</a>";
echo "</td>";
echo "<td class='footer' align='right' width='38%'>";
echo "<strong>".$settings['counter']." </strong>".($settings['counter'] == 1 ? $locale['140']."\n" : $locale['141']."\n");
echo "</td></tr></table></td></tr></table></td></tr></table>";
}
function render_news($subject, $news, $info) {
global $locale;
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='panel-left3'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td width='100%' class='panel-main3'>$subject</td>";
echo "<td class='panel-right3'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left3'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='news-body'><div style='width:100%;vertical-align:top;'>$news</div><br>";
echo "<div style='margin-top:5px'>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='infobar'>".newsposter($info)."</td>";
echo "<td align='right' class='infobar2'>";
echo openform("N",$info['news_id']).newsopts($info,"·").closeform("N",$info['news_id']);
echo "</td></tr></table></div></td>";
echo "<td class='border-right3'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'>";
echo "</td></tr><tr>";
echo "<td class='border-bleft3'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain3'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright3'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
}
function render_article($subject, $article, $info) {
global $locale;
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='panel-left4'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td width='100%' class='panel-main4'>$subject</td>";
echo "<td class='panel-right4'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left4'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='side-bodyx'><div style='width:100%;vertical-align:top;'>".($info['article_breaks'] == "y" ? nl2br($article) : $article)."</div><br>";
echo "<div style='margin-top:5px'>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='infobar3'>".articleposter($info)."</td>";
echo "<td align='right' class='infobar4'>";
echo openform("A",$info['article_id']).articleopts($info,"·").closeform("A",$info['article_id']);
echo "</td></tr></table></div></td>";
echo "<td class='border-right4'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "</tr><tr>";
echo "<td class='border-bleft4'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain4'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright4'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
}
function opentable($title) {
echo "<table width='100%' cellpadding='0' cellspacing='0'>";
echo "<tr><td class='panel-left2'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td width='100%' class='panel-main2'>$title</td>";
echo "<td class='panel-right2'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left2'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='table-body'>\n";
}
function closetable() {
echo "</td>";
echo "<td class='border-right2'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td></tr>";
echo "<tr>";
echo "<td class='border-bleft2'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain2'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright2'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
}
function openside($title) {
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='panel-left'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td width='100%' class='panel-main'>$title</td>";
echo "<td class='panel-right'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='side-body'>\n";
}
function closeside() {
echo "</td>";
echo "<td class='border-right'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td></tr>";
echo "<tr>";
echo "<td class='border-bleft'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
tablebreak();
}
function opensidex($title,$open="on") {
$boxname = str_replace(" ", "", $title);
$box_img = $open == "on" ? "off" : "on";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='panel-left4'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "<td class='panel-main4'>$title</td>";
echo "<td align='right' class='panel-main4'><img src='".THEME."images/panel_$box_img.gif' name='b_$boxname' alt='' onclick=\"javascript:flipBox('$boxname')\"></td>";
echo "<td class='panel-right4'><img src='".THEME."images/blank.gif' width='6' height='21' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='100%' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left4'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td>";
echo "<td class='side-bodyx'>";
echo "<div id='box_$boxname'".($open=="off" ? "style='display:none'" : "").">\n";
}
function closesidex() {
echo "</div>";
echo "<td class='border-right4'><img src='".THEME."images/blank.gif' width='6' height='1' alt='' style='display:block'></td></tr>";
echo "<tr>";
echo "<td class='border-bleft4'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bmain4'><img src='".THEME."images/blank.gif' width='1' height='16' alt='' style='display:block'></td>";
echo "<td class='border-bright4'><img src='".THEME."images/blank.gif' width='6' height='16' alt='' style='display:block'></td>";
echo "</tr></table>\n";
}
function tablebreak() {
echo "<table width='100%' cellspacing='0' cellpadding='0'>";
echo "<tr><td></td></tr></table>\n";
}
?>
Spróbuj tak. Nie daje pewności że działa, ponieważ nie instalowałem tego. Sprawdzałem na żywca ;).
Edycja posta, spróbuj teraz :)
EDIT2. Teraz?
Edytowane przez bartek124 dnia 03.01.2008 19:54:08
Nie pomagam na komunikatorach oraz PW!
|
|
|
|
kraski1 |
Dodany dnia 03.01.2008 19:41:44
|
Początkujący
Postów: 115
Data rejestracji: 25.02.2007 15:02
|
Nowe dzieło wyszło ale dzięki bartek za zainteresowanie.
Fatal error: Cannot redeclare generatemenu() (previously declared in /home/kraski/public_html/pship/themes/Valencia/theme.php:52) in /home/kraski/public_html/pship/includes/pfmenu/pfmenu_functions_include.php on line 17
Miałem już zabawy z tym dużo wszystkie sposoby próbowałem ale nie działały :/
EDIT 2. Zrobiłem tak i wyszło co innego
Edytowane przez kraski1 dnia 03.01.2008 19:55:31
|
|
|
|
bartek124 |
Dodany dnia 03.01.2008 20:21:18
|
Weteran
Postów: 3264 Pomógł: 236
v7.02.06 Data rejestracji: 26.05.2007 12:25
|
Robimy tak:
Ściągamy paczkę z pierwszego posta i wgrywamy infusiona na nasz server ftp.
Plik xxpfmenu.css wklejamy do folderu głównego naszego thema.
W pliku theme.php naszego thema zaraz pod
require_once INCLUDES."theme_functions_include.php";
dodajemy
require_once INCLUDES."pfmenu/pfmenu_functions_include.php";
echo "<link rel='stylesheet' href='".THEME."xxpfmenu.css' type='text/css'>\n";
I teraz naważniejsze. Nie pod render footer, tylko w render header znajdujemy
".showsublinks()."
i zamieniamy na:
GenerateMenu();
lub jeśli nie działa to
".GenerateMenu();."
Uwaga! Tutaj będą problemy, ponieważ w każdym themie będzie to inaczej wyglądało. Trzeba samemu to dopasować, dlatego jeśli jesteś początkujący, to nie bierz się za to!
W infusions\navigation_panel\navigation_panel.php nic nie zmieniamy. Prawdopodobnie nic nie pominąłem ;).
Nie pomagam na komunikatorach oraz PW!
|
|
|
|
kraski1 |
Dodany dnia 04.01.2008 18:41:50
|
Początkujący
Postów: 115
Data rejestracji: 25.02.2007 15:02
|
Proponuje raczej nie instalować, próbowałem na 2 stylach i na każdym z nich wychodzi taki sam efekt,
|
|
|
|
bartek124 |
Dodany dnia 04.01.2008 20:17:52
|
Weteran
Postów: 3264 Pomógł: 236
v7.02.06 Data rejestracji: 26.05.2007 12:25
|
Przeczytaj pogrubione .
Nie pomagam na komunikatorach oraz PW!
|
|
|
|
kingsor |
Dodany dnia 07.11.2009 09:42:21
|
Przedszkolak
Postów: 4 Ostrzeżeń: 1
Data rejestracji: 31.07.2009 10:30
|
Wszystko pieknie działa tylko nie wiem w którym miejscu zmienić wyglad tego menu? Może mi ktos pomóc? |
|
|