What is the best way to set a default image for every API? I also want to prevent users from uploading their own images.
Well it really depends on exactly what you want to do it and what version of API Manager you are running. For example, if the image is clickable and how big the image is to be. So I would recommend using google chrome and right click on the things you want to change and go down to inspect element. That way you can view the files and code you want to alter.
To change default image
I went to [APIM]/repository/deployment/server/jaggeryapps/store/site/themes/wso2/libs/theme-wso2_1.0/css/ directory and edited the theme-wso2.css file. I edited the element style of line 9681 (right below Thumbnail icon customizations in API Manager 2.1.0) here is the code
.thumbnail.icon {
position: relative;
content: url(link to image); --Added this line
max-width: 100% --Added this line
}
Do the same thing in the publisher directory.
To remove option to upload image
Go to [APIM]/repository/deployment/server/jaggeryapps/publisher/site/themes/wso2/libs/theme-wso2_1.0/css/ and edit the theme-wso2.css. Edit line 1495 like below
.col-sm-offset-3 {
margin-left: 25%;
visibility: hidden; -- added line
}
This could be achieve by using sub-theme rather than modifying theme files directly as suggested above cause and it is better you can mention the version of API Manager that you are using.
Adding a New API Store Theme
Related
I'm on day three of learning web development and I'm struggling with getting things where I want them. I want my little logo (slothw.png) to lign up better with my nav links. I want it to line up in the exact same way that the logo of a website lines up with the name you give it on the bookmark bar in Chrome. I hope that makes sense and thanks for the help.enter image description here
That’s a job for css :).
You case use the flex display mode and them set the align-items property to center.
.myClassWithCenteredChildren { display: flex; align-items: center; }
Anyone know how to change color of the header in Distill in Rmarkdown? I can change the color in the rendered HTML, but then everytime it re-renders, it overrides. Is there a way to change the header color with Rmarkdown when using the Distill framework?
Cool, glad it worked! I also faced a similar issue. The entire default CSS that can be tweaked can be found in the Theming section here:
https://rstudio.github.io/distill/website.html
And then you can add this with:
output:
distill::distill_article:
css: styles.css
Found my answer, added a .css file in the main index.Rmd, used the rendered html file and web browser to inspect the element to find the distill-site-nav element and changed the css that way. here is my .css file
.distill-site-nav {
color: #000000;
background-color: #FFA500;
}
Is there a django wysiyg editor I can control its image?
I want to set a default image size and use the image as a thumbnail as well.
all wysiyg contents are represent like {{content}} since in model it's set like
content=some Wysiyg field()
The one I want to do is {{content.image}} and play around with that image.
Is there any way I can do that? right now this is the one I'm using, but I'm willing to change to the one I can control image with.
try django-ckeditor, redactor it's more simple but redactor itself isn't free and i think ckeditor is more flexible in the configuration
This appears to be a SharePoint 2013 bug.
One of the exciting features of SharePoint 2013 is the Callout. When you have a list of documents, and you want to learn more about the document without having to open it, you can click the three dots Callout button to get a popup that shows pertinent information about the document.
The problem is this information is being cut off when you apply a fixed height to the webparts properties and the height is not enough to accommodate the popup.
It appears to be due to the webpart being converted to an iFrame when a specific height is applied to it. I have been unable to find a CSS fix for this.
You can view an image of the issue here: http://www.pixelwonders.com/fixed-height-webpart.jpg
Anyone know how to fix this?
Thank you in advance for your help!
I had a very similar issue. I have a Google Map web part with fixed height and width in a two column layout, with a list on the right. The filter drop down menu would cut off just like what your image shows.
I was able to correct it by adding a script editor to modify the CSS with overflow: visible !important on both columns. In your image it looks like you have one web part above another, I would think the same rules would apply.
<style>
#WebPartWPQ3{
overflow: visible !important;
}
#WebPartWPQ2{
overflow: visible !important;
}
</style>
MediaWiki has a great built-in way for finessing the display of images, e.g. from http://www.mediawiki.org/wiki/Help:Images :
[[File:MediaWiki:Image sample|thumb|50px]]
[[File:MediaWiki:Image sample|border|50px]]
However, unfortunately, the MediaWiki repository I have to work with has disabled image uploads.
I'm wondering if there's a way I can apply the above convenience shortcuts to an externally hosted image URL, e.g. ideal would be:
[[File:http://somewhere.com/image.jpg|thumb|50px]]
Is what I'm trying to do impossible?
Yes, can't be done. From the MediaWiki manual:
For resizing images in mediawiki they need to have a row in image table of database containing dimensions and other information of image so you can't resize external images.
If those images have been uploaded in another mediawiki or if they are somewhere in your site and you want to let mediawiki make thumbnail of them you can set $wgUseSharedUploads to true and set $wgSharedUploadPath and $wgSharedUploadDBname instead of enabling external images.
If client-side resizing is sufficient, you could probably whip something up with CSS...
Wrap the image you want to resize in a div or span and give it a particular class like:
<div class="image100px">http://example.com/path/to/image.jpeg</div>
And in the [[MediaWiki:Common.css]] page on the wiki add an entry like this:
.image100px img { width: 100px; }
(Note that due to caching of the CSS you might have to force a reload to see the update.)
If you need to serve out server-resized images, then the easiest way will be to just resize the images and upload them on your external server. (Alternatively you could write a MediaWiki extension that will rescale external images, but if you can't even turn on uploads this won't help you much!)