Jump to content

cssfreakie

Staff Alumni
  • Posts

    1,674
  • Joined

  • Last visited

Everything posted by cssfreakie

  1. what do you mean with the word works? You show us some code and say it doesn't work... What doesn't? the inline css the external css only the div itself the inner elements? Do you maybe have an online example of this and a more precise description of what you expect to happen (and don't say you want it to work) And i totally agree with Jaysonic, that a tool like firebug (for firefox) or the IE9 and Chrome developer tools are perfect for testing out where your styles come from.
  2. no it doesn't look like it so i still recommend that you get those addons for firefox and try them out. or get any programme like inkscape, gimp, photoshop, illustrator and use the colorpicker.
  3. Edit: in the above setting it should be vertical-align:top for the image.
  4. this last link doesn't work. As far as your first link and code a few notes: I would use an unordered list instead of a paragaph for your form values. Besides that i would not use <strong> but <label> further more i would add vertical-align:bottom; to the image. Also a good trick to vertical align sigle line elements is to set the line-height to the same amount as the element containing them. So i would suggest for instance to use a <li> with a height of 20px and than set the line-height also to 20px. that way you get perfectly vertical aligned text inside it. so for example: <style type="text/css"> #formwrapper{list-style: none;} #formwrapper li{margin:10px 0; height:20px; line-height: 20px;} #formwrapper li label{width: 80px;display:block;float:left;text-align: right;} #formwrapper li img{vertical-align: bottom;} </style> <form action="" method="post"> <ul id="formwrapper"> <li> <label for="name">Name:</label> <input id="name" type="text" name="name"/> <img src="" alt="" width="" height="" /> </li> <li> <label for="password">password:</label> <input id="password" type="password" name="password"/> <img src="" alt="" width="" height="" /> </li> </ul> </form>
  5. well as said if it is not done properly (as in invalid) run it through a validator. Ones you fixed that it should just work. IE9 is a great browser, and i have a feeling IE gets blamed for no reason at all by people. The days of IE 6 are over and there only a few little things in IE7 and IE8 but mostly it's the coder that screwed up. As for my hint: google for conditional comments: here you go: http://www.google.nl/#hl=en&xhr=t&q=conditional+comments&cp=14&pf=p&sclient=psy&site=&source=hp&aq=0&aqi=g5&aql=&oq=conditional+co&pbx=1&bav=on.2,or.r_gc.r_pw.&fp=6dd8290d696847c9&biw=1280&bih=676 any of the first links. Rather use that instead of messing up your php scripts. (what if there is a version IE10 11 etc) But again, if i were you, validate your code. If it doesn't work properly in IE9 the coder did a bad job and that should be corrected instead of getting bandages to camouflage the code. It will save you time in the end. EDIT: if you have a link to the website i can give it a small glimpse to see some often made mistakes
  6. This topic has been moved to CSS Help. http://www.phpfreaks.com/forums/index.php?topic=338925.0
  7. So to compress your question. The images on your page are not loading, what to do... this has nothing to do with php. the path to your image is incorrect. for example. this #contentmain { background-image: url("images/contentback.png"); background-repeat: repeat-y; float: left; height: 975px; width: 705px; } should be: #contentmain { background-image: url("../images/contentback.png"); /* see the ../ ? */ background-repeat: repeat-y; float: left; height: 975px; width: 705px; } You need to use the correct path from your stylesheet to the images folder. by using ../ you can go 1 level up -www | | +---images | +---------contentback.png | +---css | +-----------stylesheet | index.php
  8. get color picker for firefox and see if you can match it. Or get firebug and inspect the element and yes there is also something called rgba, which allows to add transparency for modern browsers.
  9. cssfreakie

    CSS help

    When i Looked (in firefox) they were both the same. It might be wise to combine the logo's in a special container div and position that inside the page.
  10. If it was made properly for firefox, it should run perfect in IE9. If not run it through a validator and read the sticky besides that you could use conditional comments (google that) to target specific versions of IE. But as said if you did a good job, it should just run good in IE9
  11. cssfreakie

    CSS help

    i am pretty sure if you would be less brief in describing your problem you probably would have solved this yourself... So if i understand you correctly you want your image to be a link. Although your image is missing an alt= attribute the stuff below should just work. unless.....we are missing some code. So your might not showing us all the code that is influencing the stuff above. Do you maybe have a link to an online example of what your doing/trying? if not i recommend to install firebug, and inspect the elements and see where they get there styles from.
  12. that is definitely better for a production site
  13. and what has a $_GET variable to do with that..?
  14. Could you give a definition of what you mean with position? i can think of at least 4 things it could mean when it comes to sport. Could you maybe also give an example. like 3 rows of how you want it to look so we can have a better understanding of what you mean with position. Make it as practical as possible. or do you maybe mean The rank, as in the first row is first place second row is second place et cetera? if that is the case do the following: <?php $counter = 1; // set a counter value while($row = mysql_fetch_assoc($result)) { ?> <tr class="teams"> <td width="50"><?php echo $counter; //output the counter ?></td> <td width="250"><?php echo $row['forename']; ?> <?php echo $row['surname']; ?></td> <td width="250"><?php echo $row['teamname']; ?></td> <td width="50"><?php echo $row['SUM(teams.points)']; ?></td> </tr> <?php $counter++; //increase the value of the counter with 1 } ?>
  15. if you know the column-name of the 'position' (not sure what you mean with a generic description as position though) it's pretty much the same as the other variables your outputting in the while loop.so have a look at your tables ones you know the name of the column fetch it just like you did with the other variables. So make sure your selecting that value in your query. <table width="350" border="0" cellpadding="0" cellspacing="0" class="myteams"> <tr class="title"> <td width="50">Position</td> <td width="250">Name</td> <td width="250">Team Name</td> <td width="50">Points</td> </tr> <?php $query = "SELECT privateleague.privateleagueid, privateleague.privateleaguename, user_leagues.privateleagueid, user_leagues.userid, login.userid, login.forename, login.surname, login.teamname, selections.userid, SUM(teams.points) FROM privateleague, user_leagues, login, selections, teams WHERE privateleague.privateleaguename = '$league_name' AND privateleague.privateleagueid = user_leagues.privateleagueid AND user_leagues.userid = login.userid AND login.userid = selections.userid AND selections.groups = teams.groups GROUP by login.userid ORDER by SUM(teams.points) DESC"; $result = mysql_query($query) or die(mysql_error()); while($row = mysql_fetch_assoc($result)) { ?> <tr class="teams"> <td width="50"><?php echo $row['position']; ?></td> <td width="250"><?php echo $row['forename']; ?> <?php echo $row['surname']; ?></td> <td width="250"><?php echo $row['teamname']; ?></td> <td width="50"><?php echo $row['SUM(teams.points)']; ?></td> </tr> <?php } ?> </table>
  16. cssfreakie

    site width

    you need to set a fixed width to the container holding the elements which are part of the website. for instance. css: #wrapper{width:1024px;margin:0 auto; overflow:hidden;} html: <div id="wrapper"> website content inside here </div>
  17. as far as i know this is not directly possible. But you could put a div inside a div and than put a box-shadow on the inner div and than give the outer div the same padding as you gave as a width for the shadow. But this will look pretty ugly. have a look here: http://www.css3.info/ for what is possible. as an example of what i mean: <!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" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled Document</title> <style type="text/css"> .outer{border:1px solid #eee;padding:0 0 3px 3px;} .inner{box-shadow:#eee -3px 3px 3px;padding:5px;} </style> </head> <body> <div class="outer"> <div class="inner"> moo says the cow </div> </div> </body> </html>
  18. have a read here: http://www.w3.org/TR/CSS2/media.html anyway to set stuff to print when printing you can use div.printOnly { display:none; } @media print { div.printOnly { display: block; } } although I rather make a separate stylesheet for printing and than include it. most people are not very happy with printing out a colorful design. <link rel="stylesheet" type="text/css" media="print" href="print.css">
  19. This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=338632.0
  20. well you require javascript (using the jquery library would be easiest) for that and a hint of css where the property of that menu is position absolute also have a read on the property z-index. just a small note, we are not here to create code for you we are here to help you with your code and/or point you in the right direction. That said I moved this topic to javascript. Make sure you read some stuff about the bold marked keywords.
  21. good to see you used the original image (as sprite). Most people would have broken it up in to more than one.
  22. you could maybe provide the vendor with some solution, which if i were them have already used. A very simple example. <?php if(isset($_GET['user'])){ $url = basename($_GET['user']).'.css'; //probably want to set this as a session variable to allow it to be used between pages. echo '<link type="text/css" rel="stylesheet" href="css/'.$url.'" />'; } // in a real life example you might want to add an ifclause to see if the file really exists before including it. ?> If you place that in the <head> and the a client get redirected as folows http://www.domain.com/index.php&user=1234 An stylesheet is loaded with the name of 1234.css and other iwise if you use an iframe use javascript to alter the css.
  23. well your description is a bit unclear to be honest. Where does this piece of software run, are you able to alter it? or are you able to add for instance javascript in it. we have no idea what this piece of software is where it is run, which is allowed, do you run it in an iframe et cetera. We have no idea and so we can't say anything more than that.
  24. Keep in mind that there are 3 ways to apply css [*]An external stylesheet [*]between style tags [*]as inline style In this order style can be overwritten. So yes you can easily change the style. I understand what they say, but if they serve there clients like you should they could have atleast mentioned the stuff above. On the other hand any book you would read about css, will mention that within the first 10 pages.
  25. I'd like to make a quick update. I was mistaken with the version of IE that wasn't working. IE8 actually works. It's IE7 that doesn't work. I know IE7 is old but I'm still getting a considerable amount of traffic coming to my site who use IE7. Does this change the advice you gave me? Is there a simple IE7 fix? Sorry for mixing that up. No it doesn't change my advice. IE7 is still being used by quite some people, not to mention IE 6. making sure stuff works cross browser requires you to start with a clean template. (check the sticky for some other tips) Keep it simple and efficient. and simple doesn't mean lame, it means the right amount of difficulty for the right situation. In fact it's really fun ones you made a the template to look through it and see if you are declaring things double, try combine stuff, make it as efficient as possible.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.