473,395 Members | 1,987 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

How to put blank spaces between buttons?

So, if you have two buttons side by side how do you create space between them? I've tried the 'SPACER' tag, however this did not work?

Expand|Select|Wrap|Line Numbers
  1. <input type="button" id=""  value=" " onclick="">
  2. <input type="button" id=""  value=" " onclick="">
Ta.

Divina
Aug 23 '07 #1
9 100199
drhowarddrfine
7,435 Expert 4TB
I've tried the 'SPACER' tag, however this did not work?[/HTML]
There is no such thing as a 'spacer' tag.

Always use margin or padding for spacing. In CSS:
Expand|Select|Wrap|Line Numbers
  1. <input type="button" id=""  value=" " onclick="" style="margin-right: 30px">
Aug 23 '07 #2
...and how about if I only have one button and I wanted that Tabbed in?

Ta.
Aug 23 '07 #3
Expand|Select|Wrap|Line Numbers
  1. style="margin-left:30px;"
Aug 24 '07 #4
you can use margin

see the below code:
Expand|Select|Wrap|Line Numbers
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>Page Title</title>
  5. </head>
  6. <body>
  7. <input type="button" id="" value="reset" onclick=""  style="margin-right: 30px">
  8. <input type="button" id="" value=" submit" onclick="" "> 
  9. </body>
  10. </html>
Apr 4 '19 #5
AjayGohil
83 64KB
Hello,You can use &nbps; in HTML and also you can use margin property of CSS in style tag.
Below code for &nbps;

Expand|Select|Wrap|Line Numbers
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>Page Title</title>
  5. </head>
  6. <body>
  7. <input type="button" id="" value="reset" onclick="">&nbsp;
  8. <input type="button" id="" value=" submit" onclick="" ">
  9. </body>
  10. </html>
Below code for margin property
Expand|Select|Wrap|Line Numbers
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>Page Title</title>
  5. </head>
  6. <body>
  7. <input type="button" id="" value="reset" onclick="" >
  8. <input type="button" id="" value=" submit" onclick="" style="margin-left:20px;">
  9. </body>
  10. </html>
  11.  
Jan 20 '20 #6
gits
5,390 Expert Mod 4TB
using the 'nonbreakingspace' = &nbsp is the worst solution to use. Layout should always be done by css - thats what it is for.
Jan 20 '20 #7
Ishan Shah
47 32bit
Hello! You can use margin to give the space between to buttons and you can also use the margin-left to the button for the same.

Expand|Select|Wrap|Line Numbers
  1. <!DOCTYPE html>
  2. <html lang="en">
  3.  
  4. <head>
  5.     <meta charset="UTF-8">
  6.     <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7.     <meta http-equiv="X-UA-Compatible" content="ie=edge">
  8.     <title>Title</title>
  9.     <style>
  10.         .btnSubmit {
  11.             margin: 25px;
  12.         }
  13.  
  14.         .btnCancel {
  15.             margin: 25px;
  16.         }
  17.     </style>
  18. </head>
  19. <body>
  20.     <input class="btnSubmit" type="button" name="btnSubmit" value="Submit" />
  21.     <input class="btnCancel" type="button" name="btnCancel" value="Cancel" />
  22. </body>
  23. </html>
Jan 29 '20 #8
If you want to blank space so you should to use this &nbsp;
Jan 29 '20 #9
gits
5,390 Expert Mod 4TB
If you want to blank space so you should to use this &nbsp;
in post #7 i did touch on explaining why that is a very bad, if not the worst, solution.
Jan 29 '20 #10

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: Jean-Marc Molina | last post by:
Hello, I can't find a way to execute a Windows application, whose directory path contains blank spaces, from a PHP script. I also wonder if the problem happens under Linux and other OS. ...
1
by: Danny | last post by:
Given this: "*" the pattern to remove the htnl code between brackets, how can I remove a series of spaces and just make one space. like here is a series of blank...
2
by: Nimmy | last post by:
Hi, How can I print blank spaces with printf() I want something like printf("%6d %2d", lcVar1, lcVarb); Printout should be: 123123 34 12 spaces in between 123123 and 34 and 15...
1
by: BethanyBez | last post by:
Is there any way when doing a merge with an Access Query and a columned Word doc that I can avoid blank spaces where the field is blank? I am creating a columned contact sheet with the contacts...
3
by: ShaeMills via AccessMonster.com | last post by:
In my table I imported from .txt, one of my columns has blank spaces. The column is as follows, how do I eliminate the blank spaces in between the second and third, and fifth and sixth digits? ...
1
by: abhilash12 | last post by:
validating blank spaces. The input box should accept the value - for eg "JOHN SMITH" but it should not allow two blank spaces.
1
by: maryanncanor | last post by:
Hi everyone, My problem is whenever I export a report to a textfile. The output textfile have blank spaces. Here is my query: SELECT ( & '|' & & '|'...
1
KeredDrahcir
by: KeredDrahcir | last post by:
I have some values in an array and I need to remove the blank spaces before them. I've used array_walk($context_array, 'trim_value');To trim the spaces using the function: function...
9
by: madhuriks | last post by:
hi, i tried to delete an element in xml..for that i used servlet coding...it is getting deleted but blank spaces are remaining i dont want that blank spaces..can any one do me needfull..here is my...
2
by: SwapnilD | last post by:
I'm implementing a feature which reads comma separated txt file from server(one line at a time). Format of file is fixed, There are 3 columns on each row. After reading the row from file I...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.