Sliding not working in HTML5 web page - javascript

I have web page in which i want to slide the images from right to left it works fine on jsFiddle but when i edit that code in my web page it does not slide i don't know what is the problem.
Below is the online code which works fine but when i add this in my code it does not work.
http://jsfiddle.net/WM5tA/7/

My number one suggestion would be checking that your jquery file is included in your code, because jsFiddle does it for you.

Related

Javascript and CSS not working after uploading the website online but they are working fine locally

Here is the site in question http://www.rfindings.net/
I have uploaded the code to github - https://github.com/Shaivik7/rfindings
Now the home page has 2 images that should be switching every 4 secs which is not happening online but working fine offline.
If you see any missing semicolons I have fixed them and tried again but nothing changes.
And for CSS part I have wrote the media query according to resized browser but the site looks completely different on mobile, I used media query for anything less than 768px but still on mobile it looks completely different.
I am beginner so I hope my code isn't too messy if it is I apologize in advance.
I am hosting this site at namecheap
If you have to time please take a look.. Thanks

Owl Carousel displaying different and wrong on refresh

I have an owl.carousel on my website displaying testimonials. I didn't have any issues with this until about a month or two ago. I have no idea what happened that now I have this problem but i'll try to explain as best as I can.
I'm getting two different views of the carousel on the firefox and chrome. On firefox, it looks perfectly fine and displays correctly. On chrome how ever, it seems like after the browser cashes the page, the carousel decides to align all the text to the right (I know this is confusing so ill put picture in so you guys can see). The reason I say after it cashes the page is because, when I load the page with no cashe on chrome, it looks perfectly fine as it does on firefox, but as soon as I go to another page and then come back or refresh the page, the carousel all shifts to the right.
Here is what it looks like on chrome:
https://gyazo.com/2466dc69c470851122693d622975c018 --> Chrome
Here is also a link to the website for who ever that wants to read the code them selves (scroll down the home page and you will see the testimonials section):
http://ecocertificates.com.au
Any help would be greatly appreciated guys!
Thanks in advance :)

HTML Button Highlight With Jquery Not Working

I am currently in the process of building a web app. I am trying to get an image when clicked to change image source and then hide one div and show another. This seems to work fine when viewing within a browser but when viewed on an iPad the button image change doesn't work. An example of what I am currently doing is below:
$("#pg3rgt_en_GB").click(function(){
$(this).css("background-image","url(images/right-button-down.jpg)");
setTimeout(function(){
$("#introduction_en_GB").hide();
$("#pg3rgt_en_GB").css("background-image","url(images/right-button.jpg)");
$("#customerinput_en_GB").show();},250);
I hope that this is something simple I am missing. I appreciate any help and thanks in advance!
Safari doesn't recognise the show and hide features that jQuery has to offer. The best way around this would be to assign different css classes - which safari does recognise!

Images are streatched in the blog

I have a blog which has few posts with images. Recently a few weeks ago, I found that the images of the home page are streatched as follows which were absolutely fine before.
Is this a problem with CSS3? I am not much aware of that. How can I edit CSS and Solve this issue? My blog is http://insiderattack.blogspot.com/
Thank you.
Your images are initially fine and not related with css, instead it's because of some javaScript file that you have probably added recently, try to disable JavaScript and load the page with JavaScript disabled, it looks fine. Here is an image of your site, i've loaded it with JavaScript disabled from Google Chrome browser.

Loading JWplayer dynamically

Hi and thanks for looking into this.
I have a code I've been working on to add videos to my site. All videos are from youtube. Once a user has clicked on submit, a link becomes visible. When clicking on it the user can preview the video.
One week ago I used the following to achieve this:
$("#result").html('<a href="javascript:initPlayer(\'http://www.youtube.com/watch?v=kXhy7ZsiR50\')>Preview video</a><br>');
Everything worked fine. But today I was trying the script and the link doesn't appear anymore. The link works however fine if I do something like:
Preview video
Somewhere on the page.
I don't know why the call with jQuery doesn't work anymore. It worked fine when I was developing the website. I tried it on different browsers, but with the same result in the end.
Anyone any idea how to solve this? I'm starting to pull out my hair. :)
Thanks in advance.
This seems to work fine:
$("#result").html("<a href='javascript:initPlayer(\"http://www.youtube.com/watch?v=kXhy7ZsiR50\")'>Preview video</a><br>");
I think it's a double/single quotes problem. Everything is back to normal.

Categories