Spacing

deadfingersdeadfingers Senior MemberThe Royal RAM
Alright well i need to know how to space a table or a 'cell' slightly off from the edges or slightly away from the middle or whatnot. I used it a while ago, it was like <hspace="#"> or something but i cant remember! what is it? and where does it go? i read somewhere it goes like in the code like <td hspace="10"></td> but it doesnt work, are there any other ways to space things out like this? not a lot just like some PX or something, like if i wat a pic or a table to move 10 px to the right or left or whatnot. I know u can use like <div></div> or something but ive never really used any spacing type codes much so. any help is appreciated :)
sig.jpg

Comments

  • ForgeForge Senior Member The Royal RAM
    ok
    soo like? You dont want the content to be touching the edges? If so, in the table tag, you need an attribute such as...
    cellpadding=2
    2 is equal to 2 pixels, so keep that in mind.
    Can fat people Go skinny Dipping?
  • deadfingersdeadfingers Senior Member The Royal RAM
    lol yeah i know bout that, no i mean if i wanted to space something in a certain spot, like 15px to the right of the center. cellpadding and cellspacing is just for tables, and thats not what i mean, how would i separate like pictures or other things like say i want them near the center yet not on the left/right of the center. get me?
    sig.jpg
  • pfgannonpfgannon Moderator Administrator
  • deadfingersdeadfingers Senior Member The Royal RAM
    heh well im sticking to HTML, anyone know? not that i dont want to learn CSS but i just rather learn another 'language' like PHP or something else instead. besides i know theres a way to space out stuff like this in HTML, come on guys! lol but seriously help please!
    sig.jpg
  • PythonPython Forum Leader The Royal RAM
    i think css would be the only way...unless you used a layer...

    The Royal Ram

  • CannonBallGuyCannonBallGuy Moderator Shared Hoster
    Uss CSS
    use this code: "top:50px;left:15px;"
    ie.
    <img src="link" style="top:50px;left:15px;" />
    That would put the image 50px down from the top and 15px across from the left.
    You can also do stuff like <div style="top:10px;left:35px;"> Whatever you put here wil be 10px down and 35px across.</div>
    
  • deadfingersdeadfingers Senior Member The Royal RAM
    oh alright kewl, ive used those codes before just never though they were CSS lol so yeah thanx a lot guys :)
    sig.jpg
  • CannonBallGuyCannonBallGuy Moderator Shared Hoster
    Yo' Welcome. :P
  • kinkkink serious member VPS - Virtual Prince of the Server
    cbg is right if you want an inline deal try
    <div id="position:absolute; top:20px; left:20px; width:200px; height: 200px:">

    (your stuff)
    </div>
  • deadfingersdeadfingers Senior Member The Royal RAM
    hmm alright well i used those 'codes' for once and they dont work at all, i tried this

    <div id="position:absolute; top:20px; left:20px; width:200px; height: 200px:"><i>Sincerely,

    <br>CEO/Owner<br>Digital Ebay</i></b></font></div>


    and it just sits there, why does it do that? if i use &nbps; it moves it like 1px at a time so thats not wat i want to use id have like a page of those just to move them over. so any other things?

    ok i used the wyiwyg part of the editor i use to move it and i look at the code and it did this

    <i>    ;  
    Sincerly,

    <br>   nbsp;  
    CEO/Owner<br>   sp;    
     Digital Ebay</i></b></font>

    wtf? i would have thought it would use something more effective than that, but eh ill just leave it like that for now. but if anyone knows of any good code that i can use to precisely space out that would be great, or tell me wat im doing wrong wit the <div></div> tags thanx
    :D :rog: *i edited it since u needed to scroll some because it had too many ' " but i cut it down, u get the idea of wat im saying so.
    sig.jpg
  • CannonBallGuyCannonBallGuy Moderator Shared Hoster
    Your code is messed up.
    You ended a CSS thing with : where it should be a ; ...
    And you have closed two tags you didnt even open.
    Plus, NEVER EVER let me see you use <b>, <i> or <font> again.
    Do this:

    <div id="position:absolute;top:20px;left:20px;width:200px;height:200px;font-style:oblique;">
    Sincerely,
    <br>CEO/Owner<br>
    Digital Ebay</div>

    The "font-style:oblique" will make that text inside the div italic. :)
  • deadfingersdeadfingers Senior Member The Royal RAM
    Your code is messed up.
    You ended a CSS thing with : where it should be a ; ...
    And you have closed two tags you didnt even open.
    Plus, NEVER EVER let me see you use <b>, <i> or <font> again.
    Do this:

    <div id="position:absolute;top:20px;left:20px;width:200px;height:200px;font-style:oblique;">
    Sincerely,
    <br>CEO/Owner<br>
    Digital Ebay</div>

    The "font-style:oblique" will make that text inside the div italic. :)

    I always use <B></B> and <i></i> and <font></font> and they always work so why no? i dont use CSS so thats wat i use. Oh and i did close the tags, the beginning of the tags are in the beginning of this paragraph. I tried that one u posted and still nothing, i put it in a new page to see if it would work and it just puts it in the top left like normal, i know this is the normal position because i tried it without the <div> tags and its in the same place like if the tags had no effect on them. do i need to save the file as a certain file? or do i save as HTML? im using an HTML editor (Allaire Homesite 4.5) this is kinda weird that nothing seems to work
    :confused:
    sig.jpg
  • CannonBallGuyCannonBallGuy Moderator Shared Hoster
    wait. I just noticed somehting else that is messing up your code...
    you have <div id="blah...
    Should be <div style="blah...

    And <b>, <i>, <u> and <font> don't always work.
    Its a pretty basic rule to just avoid them at all costs.
    If you use a css style sheet do this:
    .b {font-weight:bold;}

    and then:
    <span class="b">bold</span>
  • deadfingersdeadfingers Senior Member The Royal RAM
    well im starting to use more CSS in my files, as for the <div id="blah"> u told me to put that so i did, then the part for the bold and stuff i put

    .b{font-weight:bold;} and the bold text goes here? or do i need this also

    <span class="b">bold</span>? thanx
    sig.jpg
  • tonytony Moderator Administrator
    you put .b{font-weight:bold;} in your style sheet

    then on your page you put the <span class="b">text here</span>
Sign In or Register to comment.