FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


my new site... :)





tingkagol
I just got back into coding a website. Don't really know that much about html or css cept for those bits and pieces I found on the web. Site is about done... I think. But I need suggestions.

You can view the site here:
francoreyes.tk

I don't really like how the navigation menu looks (the one on the left). It looks better sitting on a pure black background without that huge background picture - which I'm also undecided about keeping on the site (not to mention it's 40kb and is going to eat large chunks of bandwidth). Should I keep the picture? Should I change how the nav menu looks?

I'm also uncomfortable with the transparent content DIV which does not work in IE (background-color: rgba (x,x,x,0.5);). Should I just get rid of transparency?

Thanks.
tingkagol
I think I'm satisfied with the way it looks now. Please leave any suggestions or constructive criticisms... Thanks for checking. I'll try setting up a subdomain for the site when i get home. Seems google HATES dot TK forwarded sites.

www.francoreyes.tk
adri
A few suggestions:


You have to many titles that are asking to be read, you can leave the News & Stuff title away and replace it with an active li in the navigation.

It is not really obligatory but most of time the navigation is coded as a list:
Code:
<ul id="nav">
<li><a href="#">home</a></li>
<li><a href="#">news</a></li>
<li><a href="#">about</a></li>
<li><a href="#">contact</a></li>
</ul>


Also maybe spreading the navigation elements a little bit more (line height should have a bigger value) so the navigation looks lighter (and also the whole top left). Smile

You could also give the subtitle of a post (the "posted by ..." line) a margin-left (for the hierarchy). Smile


Still a nice lay-out though,


adri Wink
tingkagol
Thanks for the suggestions, adri.

Now that you mention it, yeah, the narrow line-height of the nav div was kind of intentional. I'll try changing it up and see what happens.

Quote:
You have to many titles that are asking to be read, you can leave the News & Stuff title away and replace it with an active li in the navigation.

You mean replacing it with a horizontal active nav li? Yeah, I think that actually makes it look better, but I want to keep the left column nav for future purposes. If I opt for a horizontal nav in the content box, I'm afraid I won't have anything to put in the left column. lol.

*edit*

hmmm... this left column is really beginning to be a pain. lol. I tried changing things but ended up exactly where I started. You are right though. I really think I need to do something about it.
adri
tingkagol wrote:

You mean replacing it with a horizontal active nav li? Y


No, I mean you leave the News & Stuff title away and in stead of that you make some extra lines of code that will give the vertical navigation a color if you are on that page.

Like this (if you are on the News & stuff page)




adri
tingkagol
That's a great idea. But I don't know how to do that. Smile

My nav div is currently set up as an include php for each page...

by the way, I decided to just go all out with the nav font-size. lol. But less letters.
adri
I'm quite a PHP-noob too but here is an idea how it could work...

You give your index.php file a var, let's say $page ='index' . (You change the value of this var for each page ofcourse...)

Then in your nav-page (where your html of the navigation is located), you add the class="" attribute to the a-tags:
Code:
<a href="#" class="">Home</a>


Now between the class "" you can add some php (if else) that if $page = index then give me back the text "active", if not give me back nothing. Do this for every class...

This will give this code if the page is the index page:
Code:
<a href="#" class="active">Home</a>


and give this code if it isn't the index page or for all the other a-tags.
Code:
<a href="#" class="">Home</a


Then you just have to style the .active in css and it should work.

There are probably much shorter or more efficient ways to this but like I said in the beginning my PHP knowledge is pretty limited so I take the long but easy way. Razz


adri
tingkagol
Seems like alot of work for something almost unnoticable... Smile

I actually haven't used any other php function besides include. The last time I used an if/else function was on Basic. lol. Well, a bit in Turbo C and MS Excel too. Yep. I guess I'm an extremely outdated programmer. lol

...so if I'm not mistaken:
Code:
<a href="#" class=" <?php if ($page='index') { active } ?> ">Home</a>

I honestly don't know how to return the value "active" for the class. Should I use echo "active" ?

Thanks alot.
adri
tingkagol wrote:
Seems like alot of work for something almost unnoticable... Smile

I actually haven't used any other php function besides include. The last time I used an if/else function was on Basic. lol. Well, a bit in Turbo C and MS Excel too. Yep. I guess I'm an extremely outdated programmer. lol

...so if I'm not mistaken:
Code:
<a href="#" class=" <?php if ($page='index') { active } ?> ">Home</a>

I honestly don't know how to return the value "active" for the class. Should I use echo "active" ?

Thanks alot.


Indeed, use the echo function. Smile Some things just require a little bit more work, but make your webpage just that little bit better. Very Happy


adri
tingkagol
Noted. One more question... how do I assign a var to my pages? (i.e. $page='index') Where do I put it? Between the head tags?

*nevermind. I think I figured it out. Laughing

Other than that, thanks for everything man. Really appreciate it.

Corrections made to the above code:
Code:
<a href="#" class="<?php if ($page=='index') {echo "active";}?>">Home</a>
adri
tingkagol wrote:
Noted. One more question... how do I assign a var to my pages? (i.e. $page='index') Where do I put it? Between the head tags?

*nevermind. I think I figured it out. Laughing

Other than that, thanks for everything man. Really appreciate it.


You put it on your page where all your includes are. I think the best place is just before the includes, like this:

Code:
<?php
$page = 'index';
include(header.html);
?>


Quote:
Other than that, thanks for everything man. Really appreciate it.

No problem. Wink


adri
tingkagol
That's more like it. Smile
tingkagol
Adri? You still here? I need help anew... I am trying to assign multiple link css styles on my pages.

Basically, I want to apply this link style for ALL links:
Code:
a {text-decoration: none; color: white;}
a:hover {text-decoration: none; color: #00ffff;}


BUT I want to apply this specific link style to my navigation div:
Code:
#navigation a {text-decoration: none; color: #000000;}
#navigation a:hover {text-decoration: none; color: #00ccff;}


It does override the global link style (the former), but here is the problem: it renders my in-line class assignment moot. The "active" class style no longer works for the ff code:
Code:
<div id="navigation">
<a href="home.php" class="<?php if ($page=="home"){echo "active";}?>">HOME</a>
</div>


where:
Code:
.active {color: #00ffff;}


...it does not apply the #00ffff color when $page="home".

What should I do?
animasyonokulu
not bad
tingkagol
Thanks. Smile
adri
tingkagol wrote:
Adri? You still here?


Yeah, I'm still here. Smile

Change this line of code:
Code:
.active {color: #00ffff;}


with this line:
Code:
#navigation a.active {color: #00ffff;}


My test piece of code. Smile
Code:
<html>
<head>
<title></title>
<style type="text/css">
a {text-decoration: none; color: black;}
a:hover {text-decoration: none; color: #00ffff;}
#navigation a {text-decoration: none; color: #ccc;}
#navigation a:hover {text-decoration: none; color: #00ccff;}
#navigation a.active {color: #00ffff;}
</style>
</head>
<body>
<?php $page = 'home'; ?>
<!-- This is a normal hyperlink -->
<a href="#">Normal link</a>
<ul id="navigation">
    <li><a href="#" class="<?php if ($page=='somethingelse') echo 'active'; ?>">Link in nav</a>
    <li><a href="#" class="<?php if ($page=='home') echo 'active'; ?>">Link in nav - THE ONE</a>
    <li><a href="#" class="<?php if ($page=='somethingelsethanthefirstsomethingelse') echo 'active'; ?>">Link in nav</a>
</ul>
</body>
</html>


(Notice the simplified php if else, the { } are not needed. Smile )


adri
tingkagol
Thanks. It's working now.

I also cleaned up the {}'s of my if-else statements. Smile
sam-jam
looks good! The only thing that would make it better is if i wanted to post a comment on the clips it would take me to a page with the same background as ur homepage not all white... overall good job!!
menino
The site looks nice to me.

Keep up the good work.
tingkagol
sam-jam wrote:
The only thing that would make it better is if i wanted to post a comment on the clips it would take me to a page with the same background as ur homepage not all white...

I'm having a hard time editing the comment template. By default, it's a confusing whirlpool of html tables, and it's been so long since I've worked with TRs and TDs and whatnot... But, affirmative - right now the comment pop-up page is quite ugly, I admit.

Anyway, thanks for the compliments.
Related topics
Reply to topic    Frihost Forum Index -> Webmaster and Internet -> Advertise Your Website

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.