SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    Non-Member hyperimage's Avatar
    Join Date
    Dec 2003
    Location
    Croatia
    Posts
    259
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Style problem!!!

    hi!
    i have a php output:
    PHP Code:
    <?php 
    $result
    mysql_query("select * from wt_style_design_body order by 'id' desc limit 1"); 
    while(
    $row mysql_fetch_array($result)) { 
    echo 
    "<body style='background : $row[6];  font-size : $row[9]; font-family:$row[7]; color : $row[8]; background-image : url($xpath/$row[5])' leftmargin='$row[1]' topmargin='$row[2]' marginwidth='$row[3]' marginheight='$row[4]'>\n"

    mysql_free_result$result ); 
    ?>
    which give me this html value into my page:
    HTML Code:
    <body style='background : #FFCC99;  font-size : 14px; font-family:Times New Roman, Times, serif; color : #993333; background-image : url(/)' leftmargin='' topmargin='' marginwidth='' marginheight=''>
    everything works perfectly of this above instead font-size and font-family!!!
    so i decided to write to this forum to have an response if this output is wrong or not!!!
    becouse this 2 values wont give any effect on my page!!!
    any suggestion about how to make this style work??
    thanx in advance!!!

  2. #2
    Starting to-digg-in ********* jamesxv7's Avatar
    Join Date
    Oct 2003
    Location
    Island of Puerto Rico @ the Caribbean
    Posts
    873
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by hyperimage
    HTML Code:
    <body style='background : #FFCC99;  font-size : 14px; font-family:Times New Roman, Times, serif; color : #993333; background-image : url(/)' leftmargin='' topmargin='' marginwidth='' marginheight=''>
    The right output should be:
    HTML Code:
    <body style=[COLOR=Red]"[/COLOR]background : #FFCC99;  font-size : 14px; font-family:Times New Roman, Times, serif; color : #993333; background-image: url(...);[COLOR=Red] margin-left:2px; margin-top:2px; margin-right:2px; margin-botom:2px;"[/COLOR]>
    Or if you want the same margin for all the element you can use only:
    HTML Code:
     ... margin:2px; ...
    James: Ecodig - My Blog - My Gallery
    Validate your sites: CSS - HTML/XHTML
    Without faith you are lost.

  3. #3
    SitePoint Guru
    Join Date
    Feb 2004
    Location
    Oregon
    Posts
    686
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    using single quotes doesn't make a difference.

    but you should make it look like this

    font-family: 'Times New Roman', Times, serif;

    all family names that are multi words should have quotes around them.

    but if it doesn't work I hav eno clue as it looks like it should.

    but your best bet is to stick thsoe into a extrenal css style sheet.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •