Title: Align right
Last modified: August 20, 2016

---

# Align right

 *  Resolved [zep101](https://wordpress.org/support/users/zep101/)
 * (@zep101)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/)
 * I want to make a link align right, this is the link:
 * `<a href="#"> Back to top </a>`
 * I can do it by doing:
 * `<p style="text-align: right;"><a href="#"> Back to top </a></p>`
 * The issue I have is that when it has <p> </p> it puts an added space in the text
   that I don’t want. Is there another way to do this?

Viewing 15 replies - 1 through 15 (of 19 total)

1 [2](https://wordpress.org/support/topic/align-right-1/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/align-right-1/page/2/?output_format=md)

 *  [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * (@wpyogi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673339)
 * Depending on where you are putting it, you could use span or div. Or you could
   code out the p spaces — but that’s pretty clunky as you’d have to modify the 
   CSS to do so. You really should be putting all styles (like the text-align) in
   the CSS stylesheet, not inline.
 * BTW, if you are modifying the php files, are you using a child theme?
 *  Thread Starter [zep101](https://wordpress.org/support/users/zep101/)
 * (@zep101)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673341)
 * Not 100% up on all the terminology I am using Flexibility 3 theme. Putting this
   code in between paragraphs on wordpress page
 *  [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * (@wpyogi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673343)
 * What page — where are you modifying the code?
 *  Thread Starter [zep101](https://wordpress.org/support/users/zep101/)
 * (@zep101)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673344)
 * Dashboard/all pages/page/edit page
 * Doing all this in page editor
 *  [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * (@wpyogi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673345)
 * That’s going to create a real mess for you when you update WP or your theme —
   as all your changes will be lost.
 * All styles should be done in the external CSS stylesheets — to avoid the same
   problem.
 * You really should go to the Codex and read about [theme development](http://codex.wordpress.org/Theme_Development)
   and [Child Themes](http://codex.wordpress.org/Child_Themes).
 *  Thread Starter [zep101](https://wordpress.org/support/users/zep101/)
 * (@zep101)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673346)
 * thanks I will do that
 *  [mediabros](https://wordpress.org/support/users/mediabros/)
 * (@mediabros)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673356)
 * Seems like a margin or padding issue to me.
 * `<p style="text-align: right;width:100%;margin:0;padding:0;"><a href="#"> Back
   to top </a></p>`
 *  Thread Starter [zep101](https://wordpress.org/support/users/zep101/)
 * (@zep101)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673390)
 * WPyogi, I am a newb and am very unclear about your previous statement. where 
   are the CSS stylesheets? Is is Dashboard/Appearance/Editor ?
 * Also I thought the page editor was the place where you modified everything for
   that page, it has html capability.
 * I also looked through the CSS stylesheets editor and don’t see any of my articles
   in there so how would I edit/modify formatting and linking for a given page if
   not through the page editor?
 * I thought the templates were so that you did not have to be an html wizard.
 * Any help is appreciated, this is my first web site and I want to get it right.
   Thanks.
 *  [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * (@wpyogi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673409)
 * Yes, you can edit CSS in the Dashboard.
 * Did you read the two articles I referenced above?? Do that before you do anything
   else.
 * Read this [one](http://codex.wordpress.org/CSS) too.
 *  Thread Starter [zep101](https://wordpress.org/support/users/zep101/)
 * (@zep101)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673419)
 * Thanks WPyogi, I read your suggested articles and have to admit that most of 
   it is over my head but I am still learning.
 * You asked before if I am using a child theme and I am not sure. I am using a 
   template, is that the same as a child theme?
 * (Gotta take my son to little league, be back in a few hours)
 *  [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * (@wpyogi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673424)
 * No, using a template is not a child theme. You CREATE a child theme from a regular
   theme. Basically, a child theme is a modified version of the regular theme — 
   so that when you update the regular theme or WP (which you will have to do at
   some point and will want to do sooner than that), your modifications won’t get
   overwritten. It’s all explained in the Codex, but trying to make it very simple
   here — a child theme has “your” versions of whatever php and css files you create—
   the ones you want to be different from the standard theme. When WP uses the child
   theme — it looks first in the child theme directory for the necessary files —
   and uses them first — and then uses whatever files it still needs (to render 
   the site) from the regular theme. So it uses both the child files and the regular
   files. It’s pretty cool that way. The crucial thing is that the directory structure
   is set up correctly on your server so that WP can find and connect the child 
   files and regular theme files properly.
 * Yes, it can seem a bit technical and confusing. But what you are doing is defeating
   the very purpose of WP. You need to learn a bit more about how WP works — how
   the php files work with the database and css files to render what users see when
   they visit a website. There are some excellent books if that’s easier for you
   than online info — though the Codex is the most up-to-date info.
 * If I understand it right, if you want a “back to top” link at the bottom of all
   of your posts, you would want to code that into the php file that is used for
   that type of web page. If you want that link to appear on more than one type 
   of php file (i.e. archive page, different column pages, different layouts), you’d
   probably want to code a php function to add those links and include that function
   in all the php pages. Or you could modify that function that calls the posts.(
   Hopefully, someone else will chime in if I am confused here as I am somewhat 
   new to php as well).
 * Also, I just looked up this theme and it is unclear whether it has a GPL license.
   The fact that that is not clearly stated on their website is a problem. And if
   it’s not, WP forums do not support those themes. Did you pay for the commercial
   version?
 *  Thread Starter [zep101](https://wordpress.org/support/users/zep101/)
 * (@zep101)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673436)
 * No it was a free version. Also I am probably not explaining this to you correctly.
   My site is more of a traditional website with several pages that also has a blog
   page, I am not trying to do anything with the blog or posts. Rather on a couple
   of my pages they are long and cover a lot of topics, so I have a table of contents
   on those pages at the top and several links throughout the length of the page
   that will return you to the top.
 * Thanks for all your info, I will spend some more time reading the references 
   that you gave me.
 * I made my site live so you can check it out if you want, keep in mind that still
   need to do my headers, footer,sidebars, etc as well as SEO stuff. I am concentrating
   on getting the content done now.
    [http://www.lowermyglucose.com](http://www.lowermyglucose.com)
   Please let me know if you have any comments or suggestions.
 *  [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * (@wpyogi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673437)
 * If you were talking about editing static, conventional non-WP HTML pages — that’s
   completely irrelevant to WP and this forum…
 * But my answer to your first question is still relevant to your initial question.
 * BTW, IMHO, you’d be much better off in the long run, making your entire site 
   on WP — It would be much more functional for you and users, and save you tons
   of time and work if you set it up right in the first place.
 * Good luck — it’s a much-needed subject – too bad I can’t get my sister to read
   it as she badly needs it! LOL.
 *  Thread Starter [zep101](https://wordpress.org/support/users/zep101/)
 * (@zep101)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673441)
 * I am making all of this in wordpress aren’t I?? WordPress is all that I have 
   used unless I am still not getting something???
 *  [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * (@wpyogi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/#post-2673449)
 * OOOOOH! Okay, so sorry I keep misunderstanding you! You just meant that most 
   of your site is pages (in the WP sense)! So then what I said earlier holds — 
   you want to modify the actual php files that are being used in the pages with
   the long content (for example content-page.php).
 * And the best way to insert something like what you want is to define a function
   that does that and then call that function in the php files. Functions are in
   the functions.php file.
 * If you look at the code for those pages, you’ll see why you can save a TON of
   work doing it that way.
 * I know this all sounds quite technical and complicated…which it is. But it’s 
   doable if you are motivated to learn a lot. Best of luck with it.

Viewing 15 replies - 1 through 15 (of 19 total)

1 [2](https://wordpress.org/support/topic/align-right-1/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/align-right-1/page/2/?output_format=md)

The topic ‘Align right’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 19 replies
 * 4 participants
 * Last reply from: [zep101](https://wordpress.org/support/users/zep101/)
 * Last activity: [14 years, 1 month ago](https://wordpress.org/support/topic/align-right-1/page/2/#post-2673455)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
