Jump to content

Ingolme

Moderator
  • Posts

    14,901
  • Joined

  • Last visited

  • Days Won

    177

Everything posted by Ingolme

  1. After switching the startAngle and endAngle values, change the value of the counterClockwise flag to true.
  2. Javascript can't do it, but PHP can list files in a directory and read information from them.
  3. It's a bad idea to edit Wordpress core files directly, don't try to change how Wordpress works. You usually need to make a theme. You'll need to use HTML and CSS to make a theme that's customized for your website. Read here: http://codex.wordpress.org/Theme_Development If there's a plug-in that does what you want then install it.
  4. You can just switch the values of startAngle and endAngle, or change the value of counterClockwise.
  5. Press F12 in Firefox, Chrome or Internet Explorer to open developer tools. Open the HTML tab. Click on a small button that looks like a mouse cursor over a rectangle and the hover over the page looking for an element which has a bounding box outside the right edge of the page.
  6. Usually a website will have both of them. You use Wordpress to write blogs and news articles, but you make a Wordpress theme using HTML, CSS and a bit of PHP. Some sections of the website can be independent of Wordpress and be programmed in plain PHP.
  7. You can pass the input itself to the function using the this keyword: <input type="image" id="myimage" src="img/zoom.png" onclick="doSomething(this)" style="height:30px;width:30px;"/> Inside that function you can create a d3 object, by passing the element to the select() function. (I assume this is how D3 works, I haven't read the documentation) function doSomething(el) { var element = d3.select(el); // "element" is now a D3object // Do what you want with it // ...}
  8. Without any code, we can't know what's causing the problem. It looks like you have a container with a set height which is set to hide content that overflows. You should consider testing your pages in Chrome or Firefox first, then adjusting for other browsers after.
  9. You already made this topic here: http://w3schools.invisionzone.com/index.php?showtopic=52802
  10. Please keep your questions in your own threads. You already have a thread for that here: http://w3schools.invisionzone.com/index.php?showtopic=52802
  11. Javascript is not really object-oriented. There is no native inheritance or polymorphism. If you're just starting to learn object-oriented programming Javascript is the last language I would suggest for it.
  12. I'm not seeing the problem in Firefox. Which browser is it not working in? This might have something to do with the problem: <charset="US-ASCII"> ASCII doesn't have German characters. That's also not valid HTML but some browsers might still be attempting to use it. There are other validation errors. You also can only have one <head> element in your document and it must contain a <title> element. I see more than one <head> and there are <br> elements between them which shouldn't be there. Here's the validator for both pages: http://validator.w3.org/check?uri=http%3A%2F%2Fatheniancorner.comlu.com%2FAtheniancorner%2F%25DCber%2520Politik.html&charset=%28detect+automatically%29&doctype=Inline&group=0 http://validator.w3.org/check?uri=http%3A%2F%2Fatheniancorner.comlu.com%2FAtheniancorner%2FErste%2520S%25e4tze%2520auf%2520Griechisch.html&charset=%28detect+automatically%29&doctype=Inline&group=0&user-agent=W3C_Validator%2F1.3+http%3A%2F%2Fvalidator.w3.org%2Fservices
  13. Here's the list of them: http://www.w3schools.com/tags/default.asp You can count them.
  14. This selector is making all links that are clicked on display as inline-blocks: .jw-3-button-pages a:hover, a:active { -moz-border-bottom-colors: none; -moz-border-left-colors: none; -moz-border-right-colors: none; -moz-border-top-colors: none; background-color: rgba(255, 255, 255, 0.5); border-color: rgba(0, 0, 0, 0.6); border-image: none; border-style: solid; border-width: 0 1px; color: rgba(0, 0, 0, 0.8); display: inline-block; float: left;} I believe the selector you really were trying to do is this: .jw-3-button-pages a:hover,.jw-3-button-pages a:active {
  15. It looks like a jQuery plug-in. It's not HTML, but Javascript.
  16. Wrap each line of the poem in a <div> and give a class to the last line to align it to the right.
  17. I don't think any software will get you to edit an image in just 15 seconds. You might be thinking you'll reduce the amount of time it takes to get things done, but take into account how long it's going to take you to create a drawing program in Javascript. It's not a simple task. One library you can use is jCanvas: http://calebevans.me/projects/jcanvas/index.php There are others, you just have to search for them.
  18. If each row of one table corresponds to a row in the other table, then you can use a JOIN: http://www.w3schools.com/sql/sql_join_inner.asp If both tables have the same kinds of fields and you just want rows from both tables then you can use the UNION operator in SQL: http://www.w3schools.com/sql/sql_union.asp
  19. Many of your variable names are not very descriptive, like myVar4 and myTimer4. You have redundant variables, c, ctx, c1 and ctx1. This setInterval(function(){ myTimer4() }, 275) can be substituted with this: setInterval(myTimer4, 275) I suppose what you want is for the animation to show the arc being drawn. It's a lot to explain, I'll rewrite your code and hopefully you'll see and understand how it works: // Reference to canvas and contextvar canvas = document.getElementById('myCanvas');var context = canvas.getContext('2d');// Center of the arcvar centerX = 23;var centerY = 22;// Radius of the arcvar radius = 9;// Start and end angles// If the startAngle is greater than the end angle then your animation is going to play backwards// So make sure startAngle is smaller than endAngle// Remember that 2PI is a full circle, any higher than that and you'll just be drawing over what you had before.var startAngle = 0* Math.PI;var endAngle = 1.5 * Math.PI;var counterClockwise = false;// Amount complete starts at zero, when it reaches 1 the animation endsvar amountComplete = 0;// Amount per frame is the inverse of how many frames you want it to take before the animation is finished// 0.02 is 1/50, so it will take 50 frames to complete the animationvar amountPerFrame = 0.02;// The angular distance between the start and end anglesvar angleSize = endAngle - startAngle;// Begin running the animationvar timer = setInterval(drawArc, 33);// The drawing functionfunction drawArc() { // Erase everything on the canvas to begin drawing this frame context.clearRect(0, 0, canvas.width, canvas.height); // Add amountPerFrame to amountComplete amountComplete += amountPerFrame; // Get the current angular distance that should be drawn var drawAngle = amountComplete * angleSize; // Draw from startAngle to the current frame's amount context.beginPath(); context.arc(centerX, centerY, radius, startAngle, startAngle + drawAngle, counterClockwise); context.lineWidth = 1; context.stroke(); // Stop the animation when we've reached 100% if(amountComplete >= 1) { clearInterval(timer); }}
  20. If each line is in its own paragraph or if the lines are separated with <br> elements then text-align-last is going to force the last line of each section of text to be aligned to the right. If there is only one line, then it will be aligned to the right.
  21. Yes, I already told you how to do that: You said it wasn't working, so I want you to show me the code you tried to use.
  22. Only through experience can you know all the tiny details you need to make sure things work OK on all browsers. The first thing is to make sure your HTML is valid in the W3C validator: http://validator.w3.org If you're using HTML 5, be sure to use what's called HTML5 shiv to make Internet Explorer recognize the new elements. After that, most of it is about using the right techniques to lay out the page. Use margin, padding, width and float to position things instead of setting position to absolute.
  23. There are some online photo editing and painting programs (for example deviantART Muro). Photoshop is really expensive and GIMP is kind of troublesome to work with. There's still a market for online image editors.
  24. If you're getting errors even with an HTML 4.01 transitional doctype you really should fix them. Transitional is the most forgiving doctype, if you have errors there your page probably is in need of updating. I would recommend using HTML 5. The longer you wait to upgrade the more work it's going to take when you inevitably have to move on. HTML 5 is compatible with old elements, if you're using any HTML 5 elements at all then use the HTML 5 doctype, even if the page isn't validating.
  25. I need more context. More code or an example page is needed to determine why you're encountering a problem.
×
×
  • Create New...