background-image

Hide or display none for backgroundImage using jquery

痴心易碎 提交于 2019-12-13 03:35:56
问题 $('.arrow').backgroundImage="url('../img/arrow.png').style.display = 'none'"; I am using an animate.css plugin to hide the down arrow on scroll down. `$( document ).ready(function() {
 console.log( "ready!" );
 $("h1").animate({color:"#ffffff"}, 600); $('.arrow').backgroundImage="url('../img/arrow.png')";` if (direction == "up") { $("h1").animate({color:"#ffffff"}, 600); $('.arrow').backgroundImage="url('../img/arrow.png')"; } else if (direction == "down") {
 $("h1").animate({color:"#444444"}

3D effect with image as a background of another image

懵懂的女人 提交于 2019-12-13 02:14:05
问题 I'm trying to add a 3D effect to an image, the final result should look like the following: (illustrated in Photoshop) I've tried playing with the css3 property box-shadow but it doesn't provide a real 3D effect, as you can see in the following image: (I know I can set blur to 0 and change sides, but as you can see - there's a difference in the corners between what I'm trying to achieve to the box-shadow result) After not finding a only-CSS solution - I've created the following image and set

Change div Background jquery

非 Y 不嫁゛ 提交于 2019-12-12 21:27:26
问题 I'm not sure what I'm doing wrong. I'm trying to get the background image of my div to change over time. I got the jQuery function from this site but its not working for me. Any clue what I'm doing wrong. jQuery $(window).load(function () { var images = ['wave_01.png', 'wave_02.png']; var i = 0; function changeBackground() { $('main').css('background-image', function () { if (i >= images.length) { i = 0; } return 'url(' + images[i++] + ')'; }); } // Call it on the first time changeBackground(

$(body).css({'background-image':'url'}) not working

别来无恙 提交于 2019-12-12 20:36:27
问题 Shall I assume that I can't apply .css() to the body tag? Because if I do it on $("#div") ... it works? 回答1: $(document.body).css(...) or $('body').css(...) 回答2: how about $("body").css("background-image","url('/my/image.jpg')"); 来源: https://stackoverflow.com/questions/5253718/body-cssbackground-imageurl-not-working

How to apply equivalent of linear-gradient with opacity on edges of non-repeated image

杀马特。学长 韩版系。学妹 提交于 2019-12-12 19:59:24
问题 Like How to do equivalent of a linear-gradient with opacity on a seamless background image in CSS, but instead of a seamless background image , just a regular old image. How to do the same thing? Right now when I try it on a non-repeated background image the whole image is covered in the gradient. div { width: 1000px; height: 1000px; background: linear-gradient(to bottom, #fff, transparent) top/5% 32px no-repeat, linear-gradient(to top, #fff, transparent) bottom/5% 32px no-repeat, url(https:/

Android/ phonegap - Stretching my background image to fit screen

一个人想着一个人 提交于 2019-12-12 18:28:34
问题 I have tried various differnt things however none of them seem to work. I am using inline CSS and simply want to add a background which stetches to the screen size. I am currently using the following code within my body tag: <body onLoad="onBodyLoad();" style="background:url(images/blue_bg.png);"> My image is 400 x 300, but need to be streched to as far as 1200 x 1000. Hope someone can help (have tried background-size:100%). Thanks, 回答1: You can try this CSS3 code: body{ background: url

How to add background image to JTextField?

僤鯓⒐⒋嵵緔 提交于 2019-12-12 18:18:41
问题 I know how to add background image to JPanel (creating ImagePanel class that extends JPanel and overload it's paintComponent() method), BUT this trick with JTextField not working properly: Displays image, but not text. So, how to add background image to JTextField properly? 回答1: You need to add the text field to the label. Something like: JTextField textField = new JTextField(10); textField.setOpaque( false ); JLabel label = new JLabel( new ImageIcon(...) ); label.setLayout( new BorderLayout(

Outlook 2013 HTML Signature with Image Background

主宰稳场 提交于 2019-12-12 17:24:35
问题 I have found another thread (Outlook 2013 background image broken) however I can't comment as I am a new user of Stack Overflow. Here's my code: <table width="695" height="194" border="0" cellpadding="0" style="background-image:url('http://champ.website-admin.net/files/2014/12/email.jpg'); padding:24px;"> <tbody> <tr> <td><h3>Emma Woolward</h3></td> </tr> <tr> <td><p><a href="mailto:operations@champresources.com.au">operations@champresources.com.au</a></p></td> </tr> <tr> <td><p>1300 GO CHAMP

hotspots on full-screen backgrounds with background-position: center

时间秒杀一切 提交于 2019-12-12 17:16:40
问题 I recently ran into a problem when trying to position hotspots on top of a full-screen background image with the focal point being at the center of the image (I looked into using inline images with image-maps, but unfortunately that will not work due the the authoring environment of the site). Although I successfully have the hotspots being put into the DOM, and they position themselves correctly when the images rendered ratio matches that of the original file dimensions, when the image

Set a fix background image for all my pages in PDF iText ASP C#

℡╲_俬逩灬. 提交于 2019-12-12 15:10:55
问题 On Button Click, I generate 4 pages on my PDF, i added this image to provide a background image string imageFilePath = parent + "/Images/bg_image.jpg"; iTextSharp.text.Image jpg = iTextSharp.text.Image.GetInstance(imageFilePath); jpg.ScaleToFit(1700, 1000); jpg.Alignment = iTextSharp.text.Image.UNDERLYING; jpg.SetAbsolutePosition(0, 0); document.Add(jpg); It works only with 1 page, but when i generate a PDF that contains many records and have several pages, the bg image is only at the last