473,383 Members | 1,795 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,383 software developers and data experts.

Align Right

Hello,

I have a paragraph where I want to add one word at the end. I want this word
to be aligned right but I want it to appear on the same line as the last
line of the paragraph. So I don't want to use <p align="right"because that
drops it down to the next line. Also, I am modifying an online third party
html so I can't use CSS.

Is there an html solution to right justifying one word on the same line as
the last line of a paragraph?

Thanks,

Bob
Jul 14 '06 #1
6 2626
Hymer <ergobob@sonic[REMOVE].netscripsit:
I have a paragraph where I want to add one word at the end. I want
this word to be aligned right but I want it to appear on the same
line as the last line of the paragraph.
You need CSS for that, and it isn't quite trivial CSS code that you need.
Also, I
am modifying an online third party html so I can't use CSS.
Then stop trying. There's no point in trying to simulate such relatively
complicated issues in HTML. If you have prevented from using CSS, there's
little point in trying to achieve nice presentational features.

Instead, think about the intended _meaning_ of putting the word there, and
express that meaning using the tools you have. Such as words.

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

Jul 15 '06 #2
In message <I1*******************@reader1.news.jippii.net>, Jukka K.
Korpela <jk******@cs.tut.fiwrites
>I have a paragraph where I want to add one word at the end. I want
this word to be aligned right but I want it to appear on the same
line as the last line of the paragraph.
>Instead, think about the intended _meaning_ of putting the word there,
and express that meaning using the tools you have. Such as words.
Like this:

<p>Lorem ipsum [...] and then they all went home to have their
tea. (Dear reader, this next bit should be on the right) The
end.</p>

;-)
--
Andy Mabbett
Say "NO!" to compulsory ID Cards: <http://www.no2id.net/>

Free Our Data: <http://www.freeourdata.org.uk>
Jul 15 '06 #3
On 2006-07-14, Hymer wrote:
Hello,

I have a paragraph where I want to add one word at the end. I want this word
to be aligned right but I want it to appear on the same line as the last
line of the paragraph. So I don't want to use <p align="right"because that
drops it down to the next line. Also, I am modifying an online third party
html so I can't use CSS.
Use a CGI script to insert CSS.
Is there an html solution to right justifying one word on the same line as
the last line of a paragraph?
This uses CSS: <http://cfaj.freeshell.org/www/br.html>

--
Chris F.A. Johnson, author <http://cfaj.freeshell.org>
Shell Scripting Recipes: A Problem-Solution Approach (2005, Apress)
===== My code in this post, if any, assumes the POSIX locale
===== and is released under the GNU General Public Licence
Jul 16 '06 #4
>Hello,
>>
I have a paragraph where I want to add one word at the end. I want this
word
to be aligned right but I want it to appear on the same line as the last
line of the paragraph. So I don't want to use <p align="right"because
that
drops it down to the next line. Also, I am modifying an online third
party
html so I can't use CSS.

Use a CGI script to insert CSS.
>Is there an html solution to right justifying one word on the same line
as
the last line of a paragraph?

This uses CSS: <http://cfaj.freeshell.org/www/br.html>

Thanks everyone. I wasn't sure how complicated something like that would be.
I will simply allow it to be left justified.

Bob
Jul 16 '06 #5
This can be fudged!

<p>
<table align="right" border="0" cellpadding="0" celspacing="0">
<tr>
<td>Fudged to the right</td>
</tr>
</table>
Last line of paragraph
</p>

Though the others are correct years of laying out complicated designs
before CSS 1 led to some serious fudging practice.

Jul 21 '06 #6
On 2006-07-14, Hymer <ergobob@sonicwrote:
Hello,

I have a paragraph where I want to add one word at the end. I want this word
to be aligned right but I want it to appear on the same line as the last
line of the paragraph. So I don't want to use <p align="right"because that
drops it down to the next line. Also, I am modifying an online third party
html so I can't use CSS.

Is there an html solution to right justifying one word on the same line as
the last line of a paragraph?
What you need ideally here is a float. Before the days of CSS, tables
(and not much else) floated, so you could try:

<table align="right">
<td>word</td>
</table>

in the last line of your paragraph. Might work, depending on what
particular combination of bugs your browser(s) has/have.

Otherwise, when you say you can't use CSS, do you just mean you can't
add a stylesheet? If you can do inline styles just do:

<span style="float: right">word</span>

On the last word.

It should appear on the same line as the last line of text; but if there
isn't room for it, it will bump down to the next line. Firefox will
currently put it on the next line anyway even if there is room (this is
a known bug).
Sep 15 '06 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Phil Powell | last post by:
Code: <!-- script src="/js/val_header.js"></script --> <style> <!-- BODY { scrollbar-3d-light-color:#eeeedd; scrollbar-arrow-color:#000000; scrollbar-base-color:#000000;...
7
by: Stan Brown | last post by:
http://www.acad.sunytccc.edu/instruct/sbrown/stat04/qz05_.htm A table comes near the beginning of the page. I have the <td> of row 1 column 1 styled in line with border-top:none and...
12
by: Ted Mencini | last post by:
When I replaced older <IMG ALIGN=RIGHT ...> tags with a CSS definition <IMG class=right ...> xxx.css: IMG.right { BORDER: 0; align: right } I notice that the effect is NOT the same....
10
by: Markus Ernst | last post by:
Hi I have a strange problem with vertical-align. The case can be viewed at http://www.brainput.info/geschichte.html. HTML code: <div id="bild"><img src="geschichte.gif" width="274"...
8
by: André Hänsel | last post by:
Hi! When I put a table into a table and try to align it right, it works in IE but not in Firefox. Simplest code to reproduce: <html> <body> <table style="width: 100%"> <tr>
1
by: Astra | last post by:
Hi All This has been bugging me for months and I just can't my finger on why it won't work in Safari/FireFox (IE lets me off cos it's nice liek that). In essence, the offending code is as...
3
by: kai | last post by:
Hi, All When I place a label on a Web form, label text is always left align, I cannot find the property to set right align. Any way to set align property for the label text to right align? ...
3
by: acunnon | last post by:
I am trying to put together an login page my problem is getting the three items aligned to the middle verticaly without specifing a height to anything on the page. CSS html{ height:100%;...
13
by: Roderik | last post by:
Hi, I am wondering why (half of the) squared images are not aligned on the right of the text in Internet Explorer (using <img ... align="right" />. I thought this was supported even in IE. In FF...
3
by: happyse27 | last post by:
Hi All, I wanted to align the text box for user registration but the code just wont budge... Kindly advise what is wrong? Cheers... Andrew <HTML>
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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...

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.