Jump to content

Kevin M

Members
  • Posts

    173
  • Joined

  • Last visited

Everything posted by Kevin M

  1. I'm trying to make a code in PHP that shows your location inside a Div. Rather than having it show the HTML on every single page be different, I want to have 1 code, which I will include. In that code, I want it to make sure that you are on a certain page, and then display the correct location for that page.Some something like this would display:Home->Movies->Harry PotterAnd Harry Potter would be the page you would be on, except they would all be links.I'm pretty sure in JavaScript, you could probably do this with something like this: <script type="text/javascript'>//Display Text on Certain Pageif(location.href.match(/urlhere) {document.write("Location Here")}</script> So, is there anyway I could do this in PHP?Thanks,Kevin
  2. Kevin M

    No File Extension

    I've seen quite a few sites that have no file extensions. So instead of the page being /index.php it's just /indexSo I was wondering, how would I be able to achieve this? I read somewhere about adding something to the .htaccess file, but I can't figure out how to do this.Thanks,Kevin
  3. Kevin M

    Margin and Padding

    I'm a bit confused with the difference between margin and padding. According to W3Schools, margin defines the space around elements, and padding defines the space between the element border and and the element content.So, I don't know if I understand right, but if I set the margin to 10px for one of my DIVs, there wouldn't be anything within 10px of the div right? Even if there was something that was going to overlap it, it would be pushed away?And then I set the padding to 5px, inside the DIV, all the content would be 5px from the top, left, right and bottom?Thanks,Kevin
  4. Ok, I figured it would be something like that.Any links to a site that has a good tutorial on C#? Or would I have to go buy a book to get good info?Thanks,Kevin
  5. My friend and I are considering making some sort of software for Windows over the summer as a sort of ongoing project. Basically, she would design it, and think of the ideas, and I would create it/code it. I don't know if this will actually happen, but I'd like to be prepared if it does. So basically, what sort of language(s) would you use to create a program for Windows? And from personal experience, which do you find more useful and user friendly?I know a fair deal of (X)HTML, CSS, PHP/MySql and JavaScript. So over the next few months, I'm wondering what I should spend my time learning so that I can actually have some sort of idea what I'm doing if we go ahead with this.Any input is appreciated.Thanks,Kevin
  6. That helped a lot actually, thanks.
  7. I made a baisc PHP one a little while ago. <?php$image[0] = '<img src="IMG LINK" alt="ALT TEXT" />';$image[1] = '<img src="IMG LINK" alt="ALT TEXT" />';$image[2] = '<img src="IMG LINK" alt="ALT TEXT" />'; $image[3] = '<img src="IMG LINK" alt="ALT TEXT" />'; echo $image[rand(0,3)]; ?> Then to add more, put another line into the array: And change the bold number to the highest number in the array.
  8. Ok, thanks for the replies. I think I'll try <ul> and <li> tags, and if that doesn't work to my liking, I'll use <br />.
  9. I'm currently coding a layout that has two bars for navigation, a left and right. I am using PHP Includes for the content of the two bars. There are also navigation headers, which are in the CSS.So basically it looks like this in one of the PHP Includes: <div id="siteinto"></div><br />LINK<br />Link<br /><div id="somename"></div><br />LINK <br />Link <br /> Etc.What I was wondering, is there any way to use <p> tages so I wouldn't have to use line breaks so much. So would something like this work? <p><div id="siteinfo"</div>LINKLINK</p><p><div id="somename"></div>LINKLINK</p> Or will I still have to use Line breaks?Also, if that's not possible, could this be done using an unordered list?I'm ok with any way, but I don't really want to have 30 some odd <br /> tags in my code.Thanks,Kevin
  10. Ok, I'll try it. Thanks.
  11. Thanks for the help.I don't know if that JavaScript does this, but I want all links in a certain Div to open in a new window. Would that code only do it for a certain one? Or for every link in the div?Or is there some CSS code like:a {target: _blank;}That would work?
  12. I'm making a web layout in XHTML Strict. According to W3C, the border and target attributes are not valid in Strict XHTML. So, in the CSS, how would I put it so that the images don't have a border, and the links all open in a new window?So I wouldn't have to do something like this: <a href="http://site.com/index.php" target="_blank">Site.com</a> and <img src="http://site.com/image.jpg" border="0" alt="Alt Text" /> Which isn't valid XHTML.Thanks,Kevin
  13. You would probably need to use PHP or some other server side language, along with a database, the most common is probably MySql. It's probably next to impossible to create a forum with only HTML. I'm not 100% sure though.
  14. Thanks. That's what I've been doing, the JavaScript way. What I was wondering, was is there any way to put the javascript function into the CSS, so I could just put <div class="gototop"> </div> instead of having the image linked inside the Div. Maybe this isn't possible.
  15. I'm currently useing that function, except it's an image that goes to the top. I was just wondering if this could be concealed in the CSS somehow, so I wouldn't have to use the <a href and <img src codes.
  16. In the layout I've been working on, I have an image at the bottom that scrolls you to the top of the page useing JavaScript. For all the other images, they are contained in the CSS, but for this one I have to use the HTML to put the image there.So I was wondering, is there any way to have JavaScript and a URL contained in the CSS, so when someone clicks the image, it brings them to the top?Thanks,Kevin
  17. Kevin M

    watermark

    Can you explain a bit better what you want? I have no idea what you are asking to do, other than have a watermark. With a bit more info someone might be able to help you.
  18. My div for the banner is like this: #banner { position : absolute;z-index : -1;background-image: url(/layout2/header.png); background-repeat: no-repeat;height : 200px;width : 800px;top : 0px;} Would that be fine? I don't want to use float. Also, the content doesn't show up either. There's just the background image.
  19. Ya, z-index can be negative numbers.Thanks, I'll try that. I'd rather have it in the CSS, but I don't really care. Do you think if I put a HTML comment in the Div for the banner it might work? That way the div isn't empty, but the text doesn't show? I'll try...The div does have a width and height, the width and height of the banner.
  20. A person I know gave me a screenshot of what they see in FF. Here's what it looks like:The banner and content don't even show at all. Is anyone else getting the same result in FF? I have no idea what might be the problem. If anyone has any idea I would really appreciate it. Thanks.
  21. Ok, so the background image isn't lining up right with the banner. Thanks a ton, this really helps. :)EDIT: I figured out that's it's probably the background image positioning. I changed it. Does it all line up now?Thanks for all the help.
  22. I edited some bits in the CSS, but I have no idea if it's working or not. Can someone take a look for me?Here's the link again: LinkIt's supposed to look like this: Thanks,Kevin
  23. Some people I know are having trouble viewing my layout in FF. They say that the banner doesn't show up, and all they can see is the 3 content sections. It works fine for me in IE. I don't have FF so I don't know what it looks like. According to W3C it's all valid XHTML and CSS, so I don't know where the problem is. Here's a link: LinkHere's the coding:CSS body, td, th { font-family : Verdana, Arial, Helvetica, sans-serif;font-size : 11px;color : #ffffff;} body { background-color : #000000;background-position : top center;background-image: url(/layout2/bg.png); background-repeat: repeat-y;margin: 0px;} a { color : #ffffff;text-decoration : none;} a:hover, a:active { color : #ffffff;text-decoration : underline;} #container { position : absolute;z-index : -2;background-color: #000000;width : 800px;top : 0;} #banner { position : absolute;z-index : -1;background-image: url(/layout2/header.png); background-repeat: no-repeat;height : 200px;width : 800px;top : 0px;}#navigation { position: absolute;z-index : 1;width : 175px;left : 13px;top : 200px;text-align : center;} #content { position: absolute;z-index : 1;width : 382px;left : 210px;top : 212px;text-align: center;} #extras { position: absolute;z-index : 1;width : 175px;left : 612px;top : 200px;text-align : center;} .center { text-align : center;margin-left : auto;margin-right : auto;} XHTML <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /><link rel="stylesheet" type="text/css" href="styles.css" /><title>Harry Potter Layout by Kevin of forums.dervish-banges.com and rahponline.com</title></head><body><div id='container'><div id='banner'></div> <div id='navigation'>Navigation Here</div> <div id='content'>SITE CONTENT, SITE CONTENT,SITE CONTENT, SITE CONTENT,SITE CONTENT, SITE CONTENT,SITE CONTENT, SITE CONTENT,SITE CONTENT, SITE CONTENT</div> <div id='extras'>Extras Here</div></div></body></html> Is anyone having this problem in FF. And if so, do you have any ideas as to how I could change the layout so it works in both browsers, I would greatly appreciate it.Thanks,Kevin
×
×
  • Create New...