• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

More Image/stylesheet issues

Guest
May 31, 2011 May 31, 2011

Copy link to clipboard

Copied

Hello again,

Just wondering if anyone could give me some quick style sheet issues, have an img class that looks a little something like this:

img {

border: 5px solid #adadad ! important ;

padding: 5px ! important ;

margin: 4px, 4px, 4px, 4px ! important ;

-moz-border-radius: 15px;

-webkit-border-radius: 15px;

border-radius: 15px;

}

Which works like magic for getting me a nice curved border in most modern browsers.

Now there are one or two small icon type images that I need to not have a border as they are actually within the text - can anyone think of a way of setting up RH9 so that I can have an image that doesn't follow these styles?

I am sure it will be to do with over riding these styles but not sure how to do this because it is not like I am selecting a style for the image files - they are just getting their styles from the img selector...

Anyone got any suggestions?

much 'preciated.

Views

513

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 31, 2011 May 31, 2011

Copy link to clipboard

Copied

Hi,

You can use a classname or create a different selector. The best way to go depends on the way your toipcs are set up.

The easiest may be to create a new style:

img.noborder {

     border: none !important;

}

In HTML, add the class "noborder" to the image:

<img src="myimage.png" class="noborder" />

The !important from the selector is overwriting inline styling, as RoboHelp automatically disables borders for images. If I remember correctly, this was done to save you the trouble of manually setting the border on a few hundred images. You can also create a class for images with borders, but you will need to add that class to all images which need a border.

Greet,

Willam

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
May 31, 2011 May 31, 2011

Copy link to clipboard

Copied

Ahh ok, this is helpful, so basically the answer is it has to be done in HTML? If this is so, then so be it, but it's slightly annoying as there is probably one or two "info" icons per topic.

C'est la vie. Thanks for your help again, Willam.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 31, 2011 May 31, 2011

Copy link to clipboard

Copied

Hi,

Unless you can create a unique selector for both images, I'm afraid it will be some HTML work. A selector may be an image in a paragraph with a specific class or an image in a list item.

Greet,

Willam

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 31, 2011 May 31, 2011

Copy link to clipboard

Copied

Hi there

One way you could simplify things would be to declare a variable to store the image in. Then edit the HTML for the image. Then when you need to use it, you just drag it from the Variables pod to where it should be in the topic and all formatting, special classes and whatnot would sail along for the ride.

Cheers... Rick

Helpful and Handy Links

RoboHelp Wish Form/Bug Reporting Form

Begin learning RoboHelp HTML 7, 8 or 9 within the day!

Adobe Certified RoboHelp HTML Training

SorcerStone Blog

RoboHelp eBooks

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
May 31, 2011 May 31, 2011

Copy link to clipboard

Copied

Ahh, Rick, that's a brill idea. I'm going to do that.

thanks both.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 31, 2011 May 31, 2011

Copy link to clipboard

Copied

Hi,

Just a little follow up on Rick's idea: If you add the image in a variable, be sure to check the path to the image. If you have a relative path, the image must be accessible from all topics. Best to use a full path, such as http://www.image.com/myimage.png. That way you won't have lots of pesky broken images.

Greet,

Willam

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 31, 2011 May 31, 2011

Copy link to clipboard

Copied

Hi Willam

I'm a bit confused by what you suggested. You seem to be implying that this won't work and the image paths will break. But I've not found this to be the case. I just tested by creating an image and later creating some nested subfolders and using the variable in topics in each of the subfolders. I then generated WebHelp and viewed and I had no broken images at all. RoboHelp was able to manage the relative pathing to the image without issue.

Have you noticed otherwise?

I'm a believe in erring on the side of caution, but it would seem that (for me anyway) the worry is unfounded.

Cheers... Rick

Helpful and Handy Links

RoboHelp Wish Form/Bug Reporting Form

Begin learning RoboHelp HTML 7, 8 or 9 within the day!

Adobe Certified RoboHelp HTML Training

SorcerStone Blog

RoboHelp eBooks

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 31, 2011 May 31, 2011

Copy link to clipboard

Copied

LATEST

Hi Rick,

Mea culpa. It was a worry and I didn't tested it. Luckily, you proved me wrong. An image in a variable works like a charm in Robo 8.

Thanks for the vigilance.

Greet,

Willam

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
RoboHelp Documentation
Download Adobe RoboHelp