I was using the SCM music player for my tumblr page and a couple of other pages on the internet. But the SCM website went down. I found the player source files and loaded them onto my server. The script works fine on the website that the files are hosted on, but when I try to use the script on web pages that aren't on my server it seems that it just won't work.
I tried looking in the script file to see if there was something I could fix, but no luck. Is there something wrong with the code below?
<script type="text/javascript" src="http://www.itsnotch.com/tumblr/SCMmusic/script.php" ><!--
//--></script>
<script type="text/javascript"><!--
SCMMusicPlayer.init("{'skin':'http://itsnotch.com/tumblr/SCMmusic/skins/cyber/skin.css','playback':{'autostart':'true','shuffle':'true','volume':'50'},'playlist':[{'title':'Dam-Funk','url':'http://itsnotch.com/music/10_west.mp3'}],'placement':'bottom','showplaylist':'false'}");
//--></script>
I figured it out. For anybody who would still like to use the SCM music player.
You will have to download the files from a site (forgot which one, just google it). Then you'll have edit the script.php file.
There a line of code that reads like this.
"this.url =" and then a php method follows it. Erase the and everything between it and replace it with the actual container.php url path.
ANd it should work
Related
I have downloaded the p5js file on my windows computer but can't find a way to install it
Have you installed p5js on your pc if yes then please help me
It's a zip file so I extracted it using Winrar but in the extracted files there is one called MacOSX and i suppose that's for mac users even though I clicked on download for Windows button on the official website
p5js does not require an install. The javascript libraries can be downloaded and accessed locally or can be pulled in from a CDN.
The question mentions the MacOSX folder that is included with the source. You can ignore or even delete this folder. The MacOSX folder contains a _DS_Store file which helps Mac operating systems know how to display folder contents. See the DS_Store wiki article for more info.
p5js get-started has a nice introduction and some minimal examples.
function setup() {
}
function draw() {
ellipse(50, 50, 80, 80);
}
<script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.8.0/p5.min.js"></script>
If you downloaded a copy of p5.js the complete HTML of the example could look like this
<html>
<body>
<script src='p5.js'></script>
<script>
function setup(){}
function draw(){
ellipse(50,50,80,80);
}
</script>
</body>
</html>
A sketch like the one above can be simply saved with an html extension in the same folder as the p5.js file and opened with a web browser.
One thing to note is that as you write more complex sketches that require resources such as images or data files you may need to host your projects on a server. This is also very simple to do. Get more information on simple web servers here: local-server
In order to use P5js include CDN
<html>
<head>
<script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.7.2/p5.js">
</script>
</head>
<body>
</body>
</html>
As others have said, p5.js is a JavaScript library, so you don't really have to install anything for it to work.
If you're looking for a p5.js editor, I recommend using the p5.js web editor which handles everything for you.
Shameless self-promotion: here is a tutorial on using p5.js in various editors, and here is a tutorial on including the script in an HTML file.
We don’t need to install anything, just use the CDN…
<script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.7.2/p5.js"></script>
You don't need to install anything, as you can use the web editor or you can install the processing editor and add p5.js mode, and it will conveniently set up everything for you.
My recommendation is to use an IDE with P5.JS
https://code.visualstudio.com/
after that install the extension
and then create a folder and name it what ever you want
then hit CTRL SHIFT P and type
"Create p5.js Project"
then select your folder and click on
Sketch.js
Denar All!
I tried to add to my mail download attribute to download a picture to recipient pc/cell Phone, (right Click, inspect code, Edit html), and it accepts simple codes to "play with", but it just ignores 3 line w3schools code with download attribute. Do I Use the wrong pc or wrong doma in and what should it be like?
Just to add, I tried both options: with an internet photo/seems this would not work either, and with the picture from my own pc. For easy peasy code no result at all, makes me already desperated, is anyone willing to help, thanks in advance!
Using Chrome 84
This is most likely a cross-domain or local resource issue. You can verify this by going to DevTools (Menu -> More Tools -> Developer Tools) and checking for errors in the Developer Console.
Try running a server locally, hosting an html page and image, and pointing the image to the URL that this server is also hosting. Here is one way to do it:
Install node
Node.js quick file server (static files over HTTP)
Within that folder set up the following folder structure:
directory
index.html
image.jpg
Create index.html to have the code you want and point at "./image.jpg" with your w3 code like so:
<a href="./image.jpg" download>
<img src="./image.jpg" alt="W3Schools" width="104" height="142">
</a>
Hit your locally running server and try again: http://localhost/index.html
I'm having a weird problem with Laravel application which has been at Linux Server previously and was working fantastic but while moving to a new IIS Server, I faced alot of problems and the last problem here is some problems in view, while css and JS files are loaded and there is no error in console.
I have posted this question previously, now I'm re-posting it again with more details.
e.g. In local and previous host the fonts are good and everything works correctly, but in IIS server the fonts are bigger than normal and in local and previous server,The Pop Ups are Shown and the fonts are fine As shown in this photo, but, in IIS server, The background gets dark but the popup is not shown and the fonts are bigger Like this photo.
When I check it via Inspect elements from Chrome no error is there and all CSS and JS files are loaded correctly, while everything works but all fonts are bigger and some designs are ruined.
What I have tried:
I tried php artisan dump-autoload and php artisan serve.
Updated the composer.
Cleared the cache.
rewrited the mod and removed index.php from the link.
However, none of them works. I'm loading CSS and JS Files this way: <link rel="stylesheet" href="{{ URL::asset('assets/css/mystyle.css') }}"> and <script src="{{ URL::asset('assets/js/main.js') }}"></script>.
It looks like a very strange and weird problem, I don't know what is wrong while every CSS and JS files as well as every option works fine, but the fonts are bigger, some padding are ignored and some designs are ruined, while in localhost and previous server it was fine.
Can anybody help? and say what is wrong with this?
your problem is not familiar but any way here some tips :
in IIS server you should use URL::secure to connect with assets
post some code so we can find something wrong
use firefox developer edition to find your css problems in production
find the css selectors that effects your font in production
So I'm using CKEditor (4.4.7) through a Redmine plugin for my project. I've spent 2 whole days now searching this issue and have tried a bunch of things to no avail, so I am tapping out and asking for help. What is happening is that when I attempt to use the "file://" syntax for a link in the editor, it appears to break the HTML href operation.
This is what I have written:
My Drive Link
This is what the CKEditor ends up generating for my page:
<a>My Drive Link</a>
If I replace the "file://" with say "http://", then it works fine:
Link to Google
Result:
Link to Google
Just to make sure I am writing this correctly, using Chrome's developer tool, I change the line of HTML on my page with exactly what I have written and the link now works beautifully. It seems CKEditor doesn't know what to do with the "file://" part. Can anyone shed some light on this?
I have tried a number of customization tricks with the editor config file to force the "< a>" to have an 'href', but nothing has worked so far.
Are include files, such as server side include SSI, files necessary in an html website?
I recently tried to host my simple html website through GoDaddy. I used Dreamweaver CC to upload my files and encountered a problem. Some of my pages were not displaying images or css. I checked to see if the images and css were on the server and in the correct places and they were. Confused, I called GoDaddy's customer service, waited 35 minutes, and talked to one of their customer service reps. He basically told me that it may be my code and that I need 'include' files.
I have looked all over the web and I'm still not entirely sure what an include file is... I got from my research that they are snips of code that call images/files without having to write out the same thing on every page. If I have copied and pasted the same thing on every page, why then would I need an 'include' file? I previously had my website hosted through Hostmonster, still do now, and I have never had to alter my code...
I am still new to the world of coding, so please be kind. If anyone knows of a good resource to help explain the use of 'include' files please post it or correct me if I am wrong. Thank you.
I think the GoDaddy "support" guy was talking about the include operation in your html files that you need to fetch your css files.
Presumably your web pages work correctly when you display them locally on your development machine -- the machine where you run Dreamweaver. If not, fix them. They'll probably need css files in some subdirectory (or maybe in the same directory as the html) and image files in some other subdirectory.
Open up your page, on the server, in a browser, and then do View Source. Look for your css file download commands ... which may look something like this ... in your source.
<link href="styles.css" rel="stylesheet" type="text/css" />
Are the links (the href items) what you thought they should be? Sometimes you'll find that they are absolute links like
file:\\d\myfiles\website\dreamweaver\some_other_junk\styles\foo.css
If they are you need to change them to
styles/foo.css
The same goes for images.
And, no, you don't need server-side include files to put up a working static web site.