celeron55 mockup version

master
Rubenwardy 2013-02-20 15:42:56 +00:00
parent d9bcffb711
commit 2d0c97dc63
6 changed files with 263 additions and 241 deletions

View File

@ -32,6 +32,8 @@ That is why, I am making a new one, for c55 to possibly implement <br />
<li>Mod entry adding and editing</li>
</ul>
<h2>News</h2>
<?php

206
index.php
View File

@ -1,161 +1,101 @@
<?php
include "scripts/setup.php";
function writeList($tag,$handle){
$qu_str="SELECT * FROM mods WHERE tags LIKE '%$tag%' AND tags NOT LIKE '%dns%'";
$res = mysql_query($qu_str." ORDER BY likes DESC LIMIT 10",$handle) or SQLerror("MySQL Query Error","Error on searching database.mods.tags for '$query'");
while ($hash = mysql_fetch_assoc($res)){
// Owner name from id (by Phitherek_)
$name="";
$q=0;
$q = mysql_query("SELECT name FROM users WHERE id=".$hash['owner']);
if ($q){
$qr = mysql_fetch_array($q) or print("");
$name=$qr['name'];
}
// End of Phitherek_' s code
// Owner name instead of id (by Phitherek_)
echo "<li><a href=\"viewmod.php?id={$hash['mod_id']}\">{$hash['name']}</a> by $name</li>\n";
}
}
function seperator($cols){
echo "<tr style=\"background-color:#000000;\" height=2><td colspan=$cols></td></tr>";
}
$page_title="Mods, Texture packs and Sound packs - the best mod listing and reviewing website";
$dnd_intro_message = true;
$dnw_content=true;
include "scripts/pageheader.php";
?>
<div id="content">
<div class="constrain" style="max-width:1000px;width:975px;">
<div style="clear: both;"></div>
<div id="mod_bar">
<div id="bar_download">
<a href="viewmod.php?id=random">Random Extension</a>
</div>
<p class="bar_p">
Why dont you try something new?
</p>
<p class="bar_p">
Click the above link to go randomly to one of our extensions, whether that be a mod, texture pack or a sound pack.
</p>
<p class="bar_p">
or you can <a href="listing.php">view the categories</a>.
</p>
<?php
function tabCol($title,$msg){
echo "<tr><td><b>".$title.":</b></td><td>$msg</td></tr>\n";
}
echo "<div class='bar_title'>\n";
echo "Statistics\n";
echo "</div>\n";
echo "<p class=\"bar_p\">\n77 <b>users</b> contributing ".getNoTopics("",$handle)." <b>extensions</b>\n</p>\n";
echo "<p><table id='bar_stat'><tbody>\n";
tabCol("Mods",getNoTopics("mod",$handle));
tabCol("Games",getNoTopics("game",$handle));
tabCol("Code Mods",getNoTopics("code",$handle));
tabCol("Texture Packs",getNoTopics("texture",$handle));
tabCol("Visiters","380 a week");
tabCol("Extension Views","unknown");
tabCol("Downloads","unknown");
echo "</tbody></table></p>\n";
?>
<div class='bar_title'>
This Project
</div>
<p class="bar_p">
Minetest Extensions was created completely in code by Andrew "rubenwardy" Ward.
</p>
<p class="bar_p">
<a href="help/about.php">Read More</a>
</p>
<p class="bar_p">
<b>Help us by telling us what you think about this interface! <a href="http://tinyurl.com/mtmdfrm">Tell us</a></b>
</p>
</div>
<div id='mod_main'>
<div class="slider" id="3">
<div id="slide_1" class="slideItem" style="background-image:url('http://mesecons.net/screenshots/1.png');">
<div class="slideTitle">
<div style="float:left;">
<img src="icon/mesecon.png" alt="icon">
</div>
<a href="viewmod.php?id=2">Mesecons</a><br>
Adds electrics and mechanics (Similar to Minecraft's Redstone)
</div>
</div>
<div id="slide_2" class="slideItem" style="background-image:url('http://multa.bugs3.com/minetest/my_mods/food/banner.png');display:none;">
<div class="slideTitle">
<div style="float:left;">
<img src="icon/food.png" alt="icon">
</div>
<a href="viewmod.php?id=12">Food</a><br>
Adds many different types of food to the game. Drinks, Food, Desserts.
</div>
</div>
<div id="slide_3" class="slideItem" style="background-image:url('http://www.zimg.eu/i/944678586');display:none;">
<div class="slideTitle">
<div style="float:left;">
<img src="icon/farming.png" alt="icon">
</div>
<a href="viewmod.php?id=16">Farming</a><br>
Adds farming and plants.
</div>
</div>
<div id="slideLeft" onClick="buttonClick(1);"></div>
<div id="slideRight" onClick="buttonClick(2);"></div>
</div>
<script src="http://code.jquery.com/jquery-1.8.3.min.js"></script>
<script src="slider.js"></script>
<div id="itemBar">
<ul>
<li><a href="listing.php?id=mod">Mods</a></li>
<li><a href="listing.php?id=texture">Texture Packs</a></li>
<li><a href="search.php?id=sound">Sound</a></li>
<?php
if (is_logged_in()==true){
echo "<li>|</li>\n";
echo "<li><a href=\"addentry.php\">Add an Extension</a>\n";
}
?> </ul>
</div>
<div style="float:left;">
<img src="images/chest.png" width="256">
</div>
<h2>Welcome to Minetest Extensions</h2>
<p>
Here, at Minetest Extensions, you will find everything you will need to make Minetest perfect for you.
Welcome to Minetest Extensions, the Mod, texture pack, sound pack and other things database.
</p>
<p>
If you have any questions at all, do not hesitate to contact us on <a href="http://tinyurl.com/mtmdfrm">this project's forum topic</a>
</p>
<p>
Please, have a look round.
</p>
</div>
</div>
<div id="home_reco">
<div class="constrain">
<div style="clear: both;"></div>
<h3>Featured</h3>
<table>
<tr>
<td style="background-image:url('http://mesecons.net/screenshots/1.png');"><a href="viewmod.php?id=2">Mesecons</a></td>
<td style="background-image:url('http://multa.bugs3.com/minetest/my_mods/food/banner.png');"><a href="viewmod.php?id=12">Food</a></td>
<td style="background-image:url('http://www.zimg.eu/i/944678586');"><a href="viewmod.php?id=16">Farming</a></td>
</tr>
</table>
</div>
</div>
<div id="hotlist">
<div class="constrain">
<div style="clear: both;"></div>
<h3>Hottest Extensions</h3>
<table style="border-spacing: 0; margin: 0; padding: 0; border: 0; width: 100%;">
<tr>
<td width="33%" valign="top" style="padding-right: 1em;">
<h4>Mods</h4>
<p>
<ul>
<?php writeList("mod",$handle);?>
<li><a href="listing.php?id=mod">More...</a></li>
</ul>
</p>
</td>
<td width="33%" valign="top" style="padding-right: 1em;">
<h4>Texture Packs</h4>
<p>
<ul>
<?php writeList("texture",$handle);?>
<li><a href="listing.php?id=texture">More...</a></li>
</ul>
</p>
</td>
<td width="33%" valign="top" style="padding-right: 1em;">
<h4>Sound Packs</h4>
<p>
<ul>
<?php writeList("sound",$handle);?>
<li><a href="search.php?id=sound">More...</a></li>
</ul>
</p>
</td>
</tr></table>
<?php
include "scripts/pagefooter.php";
?>

View File

@ -7,7 +7,7 @@
else
$icon="images/topicicon_read.jpg";
echo "<tr><td width=16><img width=16 height=16 src=\"$icon\" /></td><td>";
echo "<tr><td width=32><img width=32 height=32 src=\"$icon\" /></td><td>";
echo "<a href=\"search.php?id=$query\">$title</a></td>";
echo "<td>$description</td>";

View File

@ -22,7 +22,6 @@
</head>
<body>
<div id="navbar" class="navbar">
<div class="constrain">
<span class="inbar_main">
@ -76,12 +75,25 @@ echo "<li class=\"navlink_special\"><a href=\"".FORUM_ROOT."register.php\">Regis
<input type="text" placeholder="search" name="id" size=20> <input type="submit" value="Search">
</form>
</div>
<span class="bigheader">
<h1>Minetest</h1>
<h2>Extensions</h2>
<h2>Extensions</h2>
</span>
<div id="modbar">
<div class="constrain">
<div class="inbar_main">
<ul>
<li class="navlink_normal"><a href="<?php echo $serverpath;?>/listing.php">All</a></li>
<li class="navlink_normal"><a href="<?php echo $serverpath;?>/listing.php?id=mod">Mods</a></li>
<li class="navlink_normal"><a href="<?php echo $serverpath;?>/listing.php?id=texture">Texture Packs</a></li>
<li class="navlink_normal"><a href="<?php echo $serverpath;?>/search.php?id=sound">Sound Packs</a></li>
</ul>
</div>
</div>
</div>
</div>
</div>
<script type="text/javascript">

275
style.css
View File

@ -1,185 +1,252 @@
.inbar_login {
float: right;
float: right;
}
#logo{
height: 143px;
}
#modbar{
height: 32px;
background-color:#333333;
bottom: 0;
width:550px;
float:right;
}
#modbar ul {
list-style-type: none;
padding: 0;
margin: 0;
border: 0;
}
#modbar ul li {
display: inline-block;
padding: 0px 7px 0px 7px;
padding-top: 4px;
font-size: 18px;
}
#modbar ul li a {
color: #cccccc;
display: block;
text-decoration: none;
}
#modbar ul li a:hover {
color: #ffffff;
}
#notice_bar {
background: #FACF73;
color: #000000;
display: block;
width: auto;
margin: 0px;
padding: 1em 0 1em 0;
border: 0px;
background: #FACF73;
color: #000000;
display: block;
width: auto;
margin: 0px;
padding: 1em 0 1em 0;
border: 0px;
}
#review td
{
vertical-align:top;
padding-left:10px;
vertical-align:top;
padding-left:10px;
}
#mod_main{
max-width:640px;
max-width:640px;
}
#mod_bar{
float:right;
width:300px;
background-color:#E8E8E8;
text-align:center;
padding-bottom:10px;
float:right;
width:300px;
background-color:#E8E8E8;
text-align:center;
padding-bottom:10px;
}
.bar_title{
width:100%;
height:42px;
background-color: #333333;
padding-top:12px;
color: #cccccc;
font-size:x-large;
width:100%;
height:42px;
background-color: #333333;
padding-top:12px;
color: #cccccc;
font-size:x-large;
}
#bar_download{
width:100%;
height:42px;
padding-top:12px;
font-size:x-large;
width:100%;
height:42px;
padding-top:12px;
font-size:x-large;
color:white;
margin-bottom:0;
background-color:#61AD6D;
color:white;
margin-bottom:0;
background-image: url('images/feather.png');
background-position: bottom;
background-repeat: repeat-x;
}
#bar_download a {
color: #ffffff;
font-size:x-large;
display: block;
text-decoration: none;
color: #ffffff;
font-size:x-large;
display: block;
text-decoration: none;
}
#bar_download a:hover {
color: #cccccc;
color: #cccccc;
}
#bar_stat{
margin-left:20px;
margin-left:20px;
}
#mod_bar td {
text-align:left;
text-align:left;
}
.bar_p {
text-align:left;
padding-left:20px;
padding-right:20px;
text-align:left;
padding-left:20px;
padding-right:20px;
}
.bar_p ul {
text-align:left;
text-align:left;
}
.bar_p ul li {
text-align:left;
text-align:left;
}
.slider {
width:640px;
height:280px;
position:relative;
background-color:black;
overflow:hidden;
width:640px;
height:280px;
position:relative;
background-color:black;
overflow:hidden;
}
.slideItem {
position:absolute;
left:0px;
top:0px;
width:100%;
height:100%;
max-width:640px;
min-height:480px;
background-size: cover;
background-position: center;
position:absolute;
left:0px;
top:0px;
width:100%;
height:100%;
max-width:640px;
min-height:480px;
background-size: cover;
background-position: center;
}
.slideTitle {
position:absolute;
left:0px;
top:0px;
width:630px;
min-height:32px;
padding:5px;
padding-left: 10px;
color:white;
background: rgba(97, 173, 109, 0.4);
position:absolute;
left:0px;
top:0px;
width:630px;
min-height:32px;
padding:5px;
padding-left: 10px;
color:white;
background: rgba(97, 173, 109, 0.4);
}
.slideTitle a {
color: #cccc00;
text-decoration: none;
color: #cccc00;
text-decoration: none;
}
.slideTitle a:hover {
color: #ffffff;
color: #ffffff;
}
.slideTitle img {
width: 16px;
height: 16px;
width: 16px;
height: 16px;
}
#slideLeft {
position:absolute;
left:0px;
top:124px;
width:32px;
height:32px;
background: rgba(97, 173, 109, 0.6);
position:absolute;
left:0px;
top:124px;
width:32px;
height:32px;
background: rgba(97, 173, 109, 0.6);
}
#slideRight {
position:absolute;
left:608px;
top:124px;
width:32px;
height:32px;
background: rgba(97, 173, 109, 0.6);
position:absolute;
left:608px;
top:124px;
width:32px;
height:32px;
background: rgba(97, 173, 109, 0.6);
}
#itemBar {
width:620px;
min-height:42px;
color:#ffffff;
padding-top:5px;
padding-left:20px;
background-color:#61AD6D;
background-image: url('images/feather.png');
background-position: bottom;
background-repeat: repeat-x;
width:620px;
min-height:42px;
color:#ffffff;
padding-top:5px;
padding-left:20px;
background-color:#61AD6D;
}
#itemBar ul {
list-style-type: none;
padding: 0;
margin: 0;
border: 0;
list-style-type: none;
padding: 0;
margin: 0;
border: 0;
}
#itemBar ul li {
display: inline-block;
padding: 0 7px 0 7px;
padding-top: 4px;
font-size: 20px;
display: inline-block;
padding: 0 7px 0 7px;
padding-top: 4px;
font-size: 20px;
}
#itemBar ul li a {
color: #ffffff;
display: block;
text-decoration: none;
color: #ffffff;
display: block;
text-decoration: none;
}
#itemBar ul li a:hover {
color: #cccccc;
color: #cccccc;
}
#home_reco{
font-size: 90%;
margin: 0;
padding: 1em 0 2em 0;
background: #61ad6d;
color: #ffffff;
}
#home_reco table{
width:100%;
}
#home_reco td{
width:33%;
height:180px;
background-size: cover;
background-position: center;
vertical-align:top;
margin:20px;
padding:20px;
}
#home_reco td a{
color:#ffffff;
font-size:large;
}
#hotlist {
font-size: 90%;
margin: 0;
padding: 1em 0 2em 0;
background: #ffffff;
}

View File

@ -151,6 +151,7 @@ echo "<h1>Similar Code Part of 0.4.4</h1>Only use this for versions before this.
<script src="http://code.jquery.com/jquery-1.8.3.min.js"></script>
<script src="slider.js"></script>
</div>
<?php