This should be simple task but i am not been able to find the answer of it.
I am using CKEditor in my aspx pages and i want to display full URL path when user select any image there. Right now, when user select the path it shows like
<img alt="" src="/XXX/ckeditor/images/Desert.jpg" style="width: 960px; height: 720px; " />
i want to display it like
<img alt="" src="http://www.abc.com/XXX/ckeditor/images/Desert.jpg" style="width: 960px; height: 720px; " />
Any help will be much appreciated.
Thanks
one changes in code of imagebrowser.aspx since i am using the custom version of ckeditor with file upload functinality and i am good for now
Related
I'm confronted in integrating a pdf to my project with some css.
But there it comes that I need to actually add an image.
I saw that there is KnpSnappyBundle available, but my css actually works without it as I can add colors and everything. My only question is how can I add an image without using any bundle ?
I tried with a twig link in the html like this
<img class="logo" src="{{ asset('images/logo.png') }}">
I tried with an absolute path like this
<img class="logo" src="{{ asset('images/logo.png', absolute = true) }}">
I tried to add it in the css too:
.logo {
background: url('images/logo.png');
background-size: cover;
height: 100px;
width: 100px;
}
the pdf opens but there is no logo.
So does anyone have an idea on how to do it?
The usual problem with Snappy package which internally uses wkhtmltopdf
tool, is domain name referencing. You should convert all your relative resource paths to absolute paths , and it will work for you. You should look at this or this to convert all css/image links
When I use the content editor to edit html to display an image nothing is shown? Below is the markup.
<p><img style="width: 304px; height: 228px;" title="" src="$ThemeDir/images/image1.jpg" alt="image1" /></p>
use themes/theme-name/images/image1.jpg instead
$ThemeDir is removed from SilverStripe 4.0 so used src="themes/theme-name/images/3.png"
QUESTION 1: I want to use a specific url if the user is visiting the page with a specific language
<div class="homepage-footer">
<img id="imgHomepageFooter" runat="server"
usemap="#videomap" alt="Video" meta:resourcekey="imgHomepageFooter" />
<map name="videomap">
<area shape="rect" id="youtubeVideo" coords="43,0,560,56" href="http://www.youtube.com/watch?v=Q2QsjVCapjs" target="_blank" alt="Youtube Video"
/>
</map>
</div>
I need to replace href with a specific url because the for spanish peoplo the video could be in youtube, but for english in www.google.com how could I redirect the page depending on my metaresources
QUESTION 2: I am using css for this page, but if I put the css separatly I don't know how to use inside the meta:resourcekey, so I put it as a part of my page and still I don't know the combination, I need to replace the background-image with a specific resources if I am using a specific language(that is the scenario)
style type="text/css">
div.countdown-image
{
background-image: url(../images/homepage/countdown-image-ENG-2015.png);
background-repeat: no-repeat;
height: 150px;
}
</style>
<!-- Countdown -->
<div id="countdown-container">
<div class="countdown-image">
<div id="countdown-timer" class="countdown-bottom">
</div>
</div>
<input id="DeadlineDateTime" value="" runat="server" type="hidden" />
</div>
One option is to handle the request server-side changing the values of the HTML controls as you need, based on the user's language. The answer of #All Blond follows this approach.
Another option is do the same but client-side, using JavaScript (jQuery recommended). You can locate the relevant HTML objects (using the jQuery selector $) and replace / update its properties based on the user's language as you need.
If you are on C#/ASP.net side then basically you should use in your main or onInit function
string userLang = HttpContext.Request.UserLanguages.ToString();
// I would prefer do switch based on userLang but it could be as simple as:
if (userLang = "en-CA")
{
// here you can do switch for your content anyway you want to.
// including changing your assign CSS or images - as a string or InnnerHTML content
// it is depend on solution you implement in your code.
}
Values "en-CA" you can look up on Google for example for each needed language.
I'v made some charts using Google Charts Api that i want to display in NopCommerce Amin Panel. However i want to follow the existing layout but it dosn't work for me. Tried using tables, tr's td's, changing class on different tags but none of this works.
How would i go about displaying my charts with default admin layout?
This is what i want to display, just 4 simple divs:
<div id="chart_div1" style="width: 900px; height: 500px;">
</div>
<div id="chart_div2" style="width: 900px; height: 500px;">
</div>
<div id="chart_div3" style="width: 900px; height: 500px;">
</div>
<div id="chart_div4" style="width: 900px; height: 500px;">
</div>
The admin panel is showing it's just that i want the same coloured tables around my charts.
This is what it looks like now:
Thx
The central tables used in nopcommerce admin area are built with telerik controls.
Direct control over their editing is very limited.
Your best bet would be to imitate the tables styles in your own admin stylesheet to create the appearance of tables that look like the telerik theme.
DUPLICATE TELERIK STYLES
If you are using the default theme as you image indicates you can open:
\Content\2013.2.611\telerik.default.min.css
Copy the table styles you desire into your admin styles.css
\Administration\Content\styles.css
Any tables you add to the admin area will then look the same as the telerik grid.
i have a problem
On my website i got iframe
<iframe src="www.blog.com" style="height: 340px; width: 491px"></iframe>
www.blog.com is outside page that contains user posts. I need to change some words (like swearing) into "#$%#"
is that possible and how? thank you.
or just how to remove that div or a like adBlock.. AdBlock removes:
<A class="slick_grey bolded subscribeToNewspaper" href="javascript:;" >
and also
A id="2291109" class="vote_1" href="javascript:;"
Thanks
You could use a div instead of a iframe and load the data through ajax that whay you could manipulate the content before you show it to the user
something like
$.get('ajax/test.html', function(data) {
data = data.replace("Luck","#$%#");
$('.result').html(data);
});