Riuppo il topic...Sono andato avanti con il layout.. dpo averlo lasciato in sospeso lo ho ripreso... ho fatto dei passi avanti, ora diciamo che va sostanzialmente bene ma ho un ultimo problema.
La parte dei contenuti non si affianca ai blocchi. Cioè va a capo. Vi metto l'immagine.
Come vedete il blocco con scritto "benvenuti in phpnuke" dovrebbe stare affianco ai blocchi di sinistra e invece ci sta sotto... se risolvo sto problema penso di essere a posto.
I file html dovrebbero essere corretti e anche il css, credo vada modificato il file php, ma io non so come fare... mi potete dare una mano?
Il file php del tema è theme.php
Codice PHP:
<?php
/************************************************************/
/* Definizione Colori Tema */
/************************************************************/
$bgcolor1 = "#efefef";
$bgcolor2 = "#cfcfbb";
$bgcolor3 = "#efefef";
$bgcolor4 = "#cfcfbb";
$textcolor1 = "#000000";
$textcolor2 = "#000000";
include("themes/DIV2/tables.php");
/************************************************************/
/* Function themeheader() */
/************************************************************/
function themeheader()
{
global $user, $banners, $sitename, $slogan, $cookie, $prefix, $db; cookiedecode($user);
$username = $cookie[1];
if ($username == "") { $username = "Anonymous"; }
echo "<body>"; //bgcolor=\"#505050\" text=\"#000000\" link=\"#363636\" vlink=\"#363636\" alink=\"#d5ae83\"
if ($banners == 1)
{ include("banners.php"); }
$topics_list = "<select name=\"new_topic\" onChange='submit()'>\n";
$topics_list .= "<option value=\"\">Tutti i Topics</option>\n";
$toplist = $db->sql_query("select topicid, topictext from ".$prefix."_topics order by topictext");
while(list($topicid, $topics) = $db->sql_fetchrow($toplist))
{$topicid = intval($topicid);
if ($topicid==$topic)
{ $sel = "selected "; }
$topics_list .= "<option $sel value=\"$topicid\">$topics</option>\n";
$sel = "";
}
if ($username == "Anonymous")
{ $theuser = "<a href=\"modules.php?name=Your_Account&op=new_user\">Crea un Account"; }
else { $theuser = "Benvenuto $username!"; }
$public_msg = public_message();
$tmpl_file = "themes/DIV2/header.html"; // Inclusione header.html
$thefile = implode("", file($tmpl_file));
$thefile = addslashes($thefile);
$thefile = "\$r_file=\"".$thefile."\";";
eval($thefile);
print $r_file;
blocks(left);
$tmpl_file = "themes/DIV2/left_center.html"; // Inclusione left_center.html
$thefile = implode("", file($tmpl_file));
$thefile = addslashes($thefile);
$thefile = "\$r_file=\"".$thefile."\";";
eval($thefile);
print $r_file;
}
/************************************************************/
/* Function themefooter() */
/************************************************************/
function themefooter()
{
global $index, $foot1, $foot2, $foot3, $copyright, $totaltime;
if (defined('INDEX_FILE')) {
$tmpl_file = "themes/DIV2/center_right.html"; // Inclusione center_right.html solo se $index==1 (blocchi destra visibili )
$thefile = implode("", file($tmpl_file));
$thefile = addslashes($thefile);
$thefile = "\$r_file=\"".$thefile."\";";
eval($thefile);
print $r_file;
blocks(right);
}
$footer_message = "$foot1
$foot2
$foot3
$copyright
$totaltime";
$tmpl_file = "themes/DIV2/footer.html"; // Inclusione footer.html
$thefile = implode("", file($tmpl_file));
$thefile = addslashes($thefile);
$thefile = "\$r_file=\"".$thefile."\";";
eval($thefile);
print $r_file;
}
/************************************************************/
/* Function themeindex() */
/************************************************************/
function themeindex ($aid, $informant, $time, $title, $counter, $topic, $thetext, $notes, $morelink, $topicname, $topicimage, $topictext)
{
global $anonymous, $tipath;
$ThemeSel = get_theme();
if (file_exists("themes/$ThemeSel/images/topics/$topicimage"))
{ $t_image = "themes/$ThemeSel/images/topics/$topicimage"; }
else { $t_image = "$tipath$topicimage"; }
if ($notes != "")
{ $notes = "
[b]"._NOTE."[/b] [i]$notes[/i]\n"; }
else { $notes = ""; }
if ("$aid" == "$informant")
{ $content = "$thetext$notes\n"; }
else { if($informant != "")
{$content = "<a href=\"modules.php?name=Your_Account&op=userinfo&username=$informant\">$informant</a> "; }
else { $content = "$anonymous "; }
$content .= ""._WRITES." [i]\"$thetext\"[/i]$notes\n";
}
$posted = ""._POSTEDBY." ";
$posted .= get_author($aid);
$posted .= " "._ON." $time $timezone ($counter "._READS.")";
$tmpl_file = "themes/DIV2/story_home.html"; // Inclusione story_home.html
$thefile = implode("", file($tmpl_file));
$thefile = addslashes($thefile);
$thefile = "\$r_file=\"".$thefile."\";";
eval($thefile);
print $r_file;
}
/************************************************************/
/* Function themearticle() */
/************************************************************/
function themearticle ($aid, $informant, $datetime, $title, $thetext, $topic, $topicname, $topicimage, $topictext)
{
global $admin, $sid, $tipath;
$ThemeSel = get_theme();
if (file_exists("themes/$ThemeSel/images/topics/$topicimage"))
{ $t_image = "themes/$ThemeSel/images/topics/$topicimage"; }
else { $t_image = "$tipath$topicimage"; }
$posted = ""._POSTEDON." $datetime "._BY." ";
$posted .= get_author($aid);
if ($notes != "")
{ $notes = "
[b]"._NOTE."[/b] [i]$notes[/i]\n"; }
else { $notes = ""; }
if ("$aid" == "$informant")
{ $content = "$thetext$notes\n"; }
else { if($informant != "")
{ $content = "<a href=\"modules.php?name=Your_Account&op=userinfo&username=$informant\">$informant</a> "; } else { $content = "$anonymous "; }
$content .= ""._WRITES." [i]\"$thetext\"[/i]$notes\n";
}
$tmpl_file = "themes/DIV2/story_page.html"; // Inclusione story_page.html
$thefile = implode("", file($tmpl_file));
$thefile = addslashes($thefile);
$thefile = "\$r_file=\"".$thefile."\";";
eval($thefile);
print $r_file;
}
/************************************************************/
/* Function themesidebox() */
/************************************************************/
function themesidebox($title, $content)
{
$tmpl_file = "themes/DIV2/blocks.html"; // Inclusione blocks.html
$thefile = implode("", file($tmpl_file));
$thefile = addslashes($thefile);
$thefile = "\$r_file=\"".$thefile."\";";
eval($thefile);
print $r_file;
echo "
";
}
?>
Vi posto anche il file tables.php
Codice PHP:
<?php
/************************************************************/
/* OpenTable Functions */
/************************************************************/
function OpenTable() {
global $bgcolor1, $bgcolor2;
echo "<div style=\"width: 70%; float: right; border: #000 1px solid; display: inline;\">\n";
}
function CloseTable() {
echo "</div>\n";
}
function OpenTable2() {
global $bgcolor1, $bgcolor2;
echo "<div align=\"center\" style=\"width: 70%; float: right; border: #F00 1px solid; display: inline;\">\n";
}
function CloseTable2() {
echo "</div>\n";
}
?>
PS: I file left_center.html e center_right.html sono completamente vuoti, poichè la spaziatura si verifica già con le mie impostazioni del css, e un div in + farebbe solo casini...