• Hi,

    my blog here….
    https://www.solaceincinema.com

    I was wondering if I can edit the ‘Post Upload and Paste’ plugin i’m using so that when I click ‘insert image into post’ it will automatically add ‘class=”alignleft’ into the html.

    I don’t mind doing it by hand, but one of my other contributors (who’s just set as an ‘author’)tried to add it by hand and it wouldn’t work for him… it wouldn’t save it.

    plus if I could get all images I upload to automatically have ‘class=”alignleft” ‘ it would make it a lot easier for all the other contributors…

    any help would be appreciated…. Thanks

    Ce

Viewing 5 replies - 1 through 5 (of 5 total)
  • I believe you can specify this in your CSS – something like

    img {
    float: left;
    }

    Just make sure you add ‘float: left;’ to the EXISTING img classification, rather than creating a new and duplicate one.

    Thread Starter culturalelite

    (@culturalelite)

    yeah its just that I don’t want all the images on the page to float:left, just the images in the post.

    I tried doing ‘float:left’ in the css, but it made all my meta icons move position….

    what about putting in under the post class?

    like, img.post {…}

    Thread Starter culturalelite

    (@culturalelite)

    I tried that, but it shifts all the images (including the little icons in the post meta) over to the left…

    I just want to left align the uploaded image, I guess that means defining a seperate new class for the meta images in the CSS?

    well if you don’t designate it in the css file to do it automatically, you’re going to have to create a class for what you want it to do and then edit the HTML by hand to include that class attribute with pictures individually if you don’t want it to do it “blanketly”…

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Editing upload plugin, to add a class to an image automatically’ is closed to new replies.