Skip to content
Snippets Groups Projects
Commit 4d9bf750 authored by philipp's avatar philipp
Browse files

Merge branch 'master' of /media/TBmyBook/marvin

Conflicts:
	webroot/index.php
parents 3e70c672 87a156a2
No related branches found
No related tags found
No related merge requests found
.widget { .widget_wide {
border: 1px solid #F2EFE5; border: 1px solid #F2EFE5;
background-color:#75695E;
font-family:Verdana;
color:#000000;
position:absolute;
width:800px;
height:380px;
}
.widget_narrow {
border: 1px solid #F2EFE5;
background-color:#75695E;
font-family:Verdana;
color:#000000;
position:absolute;
width:380px;
height:800px;
}
.widget_square {
border: 1px solid #F2EFE5;
background-color:#75695E;
font-family:Verdana;
color:#000000;
position:absolute;
width:380px;
height:380px;
}
.widget_smallwide {
border: 1px solid #F2EFE5;
background-color:#75695E;
font-family:Verdana;
color:#000000;
position:absolute;
width:380px;
height:170px;
}
.widget_smallnarrow {
border: 1px solid #F2EFE5;
background-color:#75695E;
font-family:Verdana;
color:#000000;
position:absolute;
width:170px;
height:170px;
}
body, h1, h2 {
font-family:Verdana; font-family:Verdana;
color:#ffffff;
background-color:#261C13; background-color:#261C13;
color:#ffffff;
} }
a { a {
......
<head> <head>
<link rel="stylesheet" type="text/css" href="css/widget.css" /> <link rel="stylesheet" type="text/css" href="css/widget.css" />
<script src="js/jquery-1.4.4.js" type="text/javascript"></script> <script src="js/jquery-1.4.4.js" type="text/javascript"></script>
<title>Marvin</title>
</head> </head>
<body> <body>
<h1>Marvin</h1>
<h2>Warpzone's widgetcenter</h2>
<?php <?php
$widgets = array( $widgets = array(
array( array(
"ZoneOffen", // widget name "ZoneOffen", // widget name
16,16, // position 16,16, // position
320,320 // size "widget_square" // css-class
) )
); );
foreach ($widgets as $widgetconfig) foreach ($widgets as $widgetconfig)
{ {
$widgetname = $widgetconfig[0]; $widgetname = $widgetconfig[0];
$widgetpositionx = $widgetconfig[1]; $widgetposx = $widgetconfig[1];
$widgetpositiony = $widgetconfig[2]; $widgetposy = $widgetconfig[2];
$widgetwidth = $widgetconfig[3]; $widgetclass = $widgetconfig[3];
$widgetheight = $widgetconfig[4];
include "widgets/$widgetname/$widgetname.php"; include "widgets/$widgetname/$widgetname.php";
$widget = new $widgetname($widgetwidth,$widgetheight); $widget = new $widgetname($widgetwidth,$widgetheight);
$widgetoutput = $widget->giveOutput(); $widgetoutput = $widget->giveOutput();
print( print("<div class='$widgetclass' id='$widgetname' style='left:".$widgetposx."px;top:".$widgetposy."px;'>");
"<div
class='widget'
id='$widgetname'
style='
position:absolute;
left:".$widgetpositionx."px; top:".$widgetpositiony."px;
width:".$widgetwidth."px; height:".$widgetheight."px;'
>");
print($widgetoutput); print($widgetoutput);
print("</div>"); print("</div>");
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment