Non-threaded

Forums » Advanced Editor Forum » Read Thread

Get help from the experts on variables, scripts, items, and other scary things.

Centering an image?

one year ago

How do I center my image in the advanced editor? Tried <p style="text-align:center">[myimage]</p> but upon "save changes" it just removes it and makes it a basic paragraph.

Centering an image?

one year ago
You are trying too hard.

[center]
[/center]

Replace the brackets with <>

Centering an image?

one year ago

Lol

Centering an image?

one year ago

I tried that and I can't get it to work.

 

$PAGETEXT := "<center>

     body { background: url('https://chooseyourstory.com/resources/images/user/58745?58745');

}

</center>" + $PAGETEXT

I want to make my background one picture, but it keeps doing more than one. Or could you tell me how to make the background one color?

Centering an image?

one year ago

$PAGETEXT := $PAGETEXT + "<center>  body {Background: url('https://chooseyourstory.com/resources/images/user/58745?58745')}</center>"

Centering an image?

one year ago
^Basically, you got the order backwards.

Centering an image?

one year ago

I copy and paste the code you send, but unfortunately, it did not work. The background was still white and part of the code ended up in the text where the story went.

Centering an image?

one year ago
You need to turn off the RTE to use HTML I'm pretty sure.

Centering an image?

one year ago

This might be a stupid question, but how do you do that? :-}

Centering an image?

one year ago
Go into your profile and uncheck the box for the Rich Text Editor.

Centering an image?

one year ago

Still didn't change anything

Centering an image?

one year ago
The above code has Unicode characters in it, so it won't work with copy/paste. You will need to type it out yourself by hand or change the greater and less than signs back manually if you paste it in.

Also, I didn't really bug-check the code, just put it up there to show the proper order to use with $PAGETEXT...

Centering an image?

one year ago

still multiply images of the same image instead of one.

Centering an image?

one year ago
If they're setting a tiny image as the background (like one that was uploaded to the site instead of an actual image host) would this make it show up tiled by default?

Centering an image?

one year ago

Speaking purely in terms of the CSS background property…

If you want your background not to repeat, add "no-repeat".

If you want your background be positioned in the center, add "center center".

If you want your background to scale to fit the available area, add "/ contain"; if you want it to scale to fill the area, add "/ cover". (If you're setting a scale, you have to include a position, followed by a slash, followed by the scale.)

e.g.

Centered only
Scaled to fit
Scaled to fill