Jump to content

Leaderboard


Popular Content

Showing most liked content since 07/23/2017 in all areas

  1. 1 point
    Maybe you didn't do the port fowarding thingy correctly, or maybe your ISP is just blocking incoming traffic on port 80.
  2. 1 point
    Instead of printing your own error message, print the actual error message from MySQL. http://php.net/manual/en/mysqli.error.php
  3. 1 point
    Which IP address? 127.0.0.1 (localhost) or the ip address of network o/s hosting the web site? check out https://stackoverflow.com/questions/9682262/how-do-i-connect-to-this-localhost-from-another-computer-on-the-same-network
  4. 1 point
    You had wrongly referenced a JavaScript function, and wrongly named a css selector so very important position: relative was not applied. <!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style> * {box-sizing:border-box} body {font-family: Verdana,sans-serif;margin:0} .mySlides {display:none; width: 100%;} /* Slideshow container */ .slideshow { /*NOT slideshow-container*/ max-width: 1000px; position: relative; margin: auto; } /* Next & previous buttons */ .prev, .next { cursor: pointer; position: absolute; top: 50%; width: auto; padding: 16px; margin-top: -22px; color: white; font-weight: bold; font-size: 18px; transition: 0.6s ease; border-radius: 0 3px 3px 0; } /* Position the "next button" to the right */ .next { right: 0; border-radius: 3px 0 0 3px; } /* On hover, add a black background color with a little bit see-through */ .prev:hover, .next:hover { background-color: rgba(0,0,0,0.8); } /* Caption text */ .text { color: #f2f2f2; font-size: 15px; padding: 8px 12px; position: absolute; bottom: 8px; width: 100%; text-align: center; } /* Number text (1/3 etc) */ .numbertext { color: #f2f2f2; font-size: 12px; padding: 8px 12px; position: absolute; top: 0; } /* The dots/bullets/indicators */ .dot { cursor:pointer; height: 13px; width: 13px; margin: 0 2px; background-color: #bbb; border-radius: 50%; display: inline-block; transition: background-color 0.6s ease; } .active, .dot:hover { background-color: #f44336; } /* Fading animation */ .fade { -webkit-animation-name: fade; -webkit-animation-duration: 1.5s; animation-name: fade; animation-duration: 1.5s; } @-webkit-keyframes fade { from {opacity: .4} to {opacity: 1} } @keyframes fade { from {opacity: .4} to {opacity: 1} } /* On smaller screens, decrease text size */ @media only screen and (max-width: 300px) { .prev, .next,.text {font-size: 11px} } </style> </head> <body> <div id="wrapper"> <div class="slideshow w3-container w3-half"> <div class="w3-content w3-display-container"> <img class="mySlides fade" src="https://www.w3schools.com/howto/img_nature_wide.jpg"> <img class="mySlides fade" src="https://www.w3schools.com/howto/img_fjords_wide.jpg"> <a class="prev" onclick="plusDivs(-1, 0)">&#10094;</a> <a class="next" onclick="plusDivs(1, 0)">&#10095;</a> <!-- Extra plusDivs parameter refers to first (0) slideshow (start from 0) --> </div> <br> <div style="text-align:center"> <span class="dot" onclick="currentDiv(1, 0)"></span> <span class="dot" onclick="currentDiv(2, 0)"></span> </div> </div> <hr> <div class="slideshow w3-container w3-half"> <div class="w3-content w3-display-container"> <img class="mySlides fade" src="https://www.w3schools.com/howto/img_nature_wide.jpg"> <img class="mySlides fade" src="https://www.w3schools.com/howto/img_fjords_wide.jpg"> <a class="prev" onclick="plusDivs(-1, 1)">&#10094;</a> <a class="next" onclick="plusDivs(1, 1)">&#10095;</a> <!-- Extra plusDivs parameter refers to second (1) slideshow (start from 0) --> </div> <br> <div style="text-align:center"> <span class="dot" onclick="currentDiv(1, 1)"></span> <span class="dot" onclick="currentDiv(2, 1)"></span> </div> </div> <script> var slideIndex = 1; var z = document.getElementsByClassName("slideshow"); for (i = 0; i < z.length; i++) { //set custom data attribute to first current image index z[i].setAttribute("data-currentslide", 1); showDivs(z[i].getAttribute("data-currentslide"), i); } function plusDivs(n, j) { //get custom data attribute value of current image index to slideshow class index j slideIndex = parseInt(z[j].getAttribute("data-currentslide")[0]); showDivs(slideIndex += n, j); } function currentDiv(n, j) { showDivs(slideIndex = n, j); /* showDivs Not showSlides*/ } function showDivs(n, j) { var i; var z = document.getElementsByClassName("slideshow")[j]; var x = z.getElementsByClassName("mySlides"); var dots = z.getElementsByClassName("dot"); if (n > x.length) { slideIndex = 1 } if (n < 1) { slideIndex = x.length; } //set custom data attribute to current image index z.setAttribute("data-currentslide", slideIndex); for (i = 0; i < x.length; i++) { x[i].style.display = "none"; } for (i = 0; i < dots.length; i++) { dots[i].className = dots[i].className.replace(" active", ""); } x[slideIndex - 1].style.display = "block"; dots[slideIndex - 1].className += " active"; } </script> </div> </body> </html>
  5. 1 point
    You need to add the second parameter when you call currentDiv, like you did with plusDivs. In order for the function to highlight the correct dot, each of those dot elements needs to specify which slide show it belongs to, so that showDivs can get the correct set of dots. One way would be to add a class name or data attribute to the dot container elements, or to the dot elements themselves.
  6. 1 point
    Its shorthand, but your PHP has to be permitted to allow it through PHP settings file under "short open tag" , else problems will occur.
  7. 1 point
    Yes. <?= ?> is a shortcut for <?php echo ""; ?> All of the above will translate as follows: <?php echo ++$a; ?> <?php echo ++$b; ?> <?php echo $private_id; ?> <?php echo session_id(); ?>
  8. 1 point
    Do you actually have! A mail server installed and setup? They are not usually supplied by default with local server installation, but you could use 'TestMailServerTools' (google), it will listen for email being sent at a port, and show in your o/s email program, while also storing the email in question.
  9. 1 point
    If you want to look into it, figure out which router you have and look up how to configure it (there should be a web page GUI), and then you need to set up port forwarding, to forward traffic on port 80 to your server's IP address. You'll also want to make sure that computer uses a static IP from the router instead of getting a dynamic IP every time so you don't have to change the port forwarding rules.
  10. 1 point
    Yes! its possible, bit complicated, The idea is to get the previous image, and place it as a background using position: absolute with low z-index, then fade in what will be next image with higher z-index, because this image is layered above the bg image it will give effect that both are cross fading, but only the top layered image is.
  11. 1 point
    Use percentages, along with fill mode /* Fading animation */ .fade { -webkit-animation-name: fade; -webkit-animation-duration: 1.5s; animation-name: fade; animation-duration: 1.5s; animation-fill-mode: forwards; } @-webkit-keyframes fade { 0% {opacity: .4} 50% {opacity: 1} 100% {opacity:0.4} }
  12. 1 point
    var a = ["123", 123, "1a2b3c", 122.222, "A"]; for(var i=0 ; i<a.length ; i++){ if(isNaN(a[i])){ alert('a['+i+'] is not a number (nan)'); } }
  13. 1 point
    IF the values in the array are taken from text type input, the numbers in array will be a string/text, it is precautionary to make sure when used in math operations that 16 + "4" don't equal "164", but 20.
  14. 1 point
    Because the string "A" cannot be converted to a number.
  15. 1 point
    The RSS item has a <link> field specifically for the URL of the resource you're sharing. An RSS reader may not necessarily parse HTML, so you should make use of the proper RSS fields. You can't send POST variables from RSS, but a link can contain a query string from which PHP can create $_GET variables.
  16. 1 point
    I don't know where there's a list. Generally you should never develop for specific devices, you should just make your layout flexible enough (with help of media queries) to wotk on any screen regardless of size. This is usually achieved by testing your page in the responsive mode of your browser and resizing the viewport until it breaks, then you add a media query to correct the layout. But for reference, I start off with a design for the following devices, then make extra adjustments later: Small mobile (iPhone 4):Up to 374px (I usually use this just for specific elements that didn't fit) Mobile or small mobile in landscape): Up to 767px Tablet portrait: 768px Tablet landscape: 1024px (breakpoint usually between 800px and 900px) Desktop: 1025px and above Some people make designs for large desktop computers (1440px and above), but that's up to you. In general, there isn't one specific strategy for responsive design, this is just the approach from the companies I work with.
  17. 1 point
    1st media rule The child dive elements are still doing what block elements do, fit to the width available to them, and using column just reiterates this, full width and stacked as column, no bunching together or wrapping will take effect anyway because it is direction of column and not a row. The Images will just be a 150px width inline element on the left by default of full width parent element div. 2nd onwards produce wrap row version Note the body element has a default margin of approx 8px, also scrollbars appear just before 1st media rule kicks in, meaning the combined width of left, middle, right etc exceeds 1st media rule width of 980px. To test when media queries kick-in use identifiable background-color: for body element on each.
  18. 1 point
    Its discussed here https://stackoverflow.com/questions/3366529/wrap-every-3-divs-in-a-div an example would be $(function() { var target_divs = $('.panel-grid-cell'); for (var i = 0; i < target_divs.length; i += 3) { target_divs.slice(i, i + 3).wrapAll("<div class='container'></div>"); } });
  19. 1 point
    The page itself opens, but the developer tools show a 404 on one of the Javascript files I think.
  20. 1 point
    If you just want people to all edit the same email and send it back, that's fine, but you can't do this with nothing but an email client: If you want to add authentication and authorization, then you need to use an actual programming language and not just a text email. It would be better to centralize everything on one web page also so that you don't end up with people editing the thing at the same time and all sending it out and now you have multiple versions of the table that you need to try and synchronize. If you need a group to collaborate like that then use the right tool for the job, which is a single web page that everyone goes to so that everyone can see the same data and everyone can be authenticated and authorized to enter data in the appropriate places.
  21. 1 point
    How can I? I don't know what or how it is replacing the checkbox? it is not necessarily bootstrap on its own, could include jQuery. I can only give exact answer by seeing the problem in action by link to the page in question, to identify what element/class needs to be targeted.
  22. 1 point
    That looks like a customized checkbox, not your ordinary plain checkbox. Its probably a created element with an awesome font character, so it depends on how this replacement is identified, styled and placed, not how the actual checkbox is identified, styled and placed.
  23. 1 point
    Have you tried this? <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <title> HTML5 page </title> </head> <body> <div class="form-group"> <label class="col-sm-4 control-label">Checkbox inputs</label> <div class="col-sm-8"> <div class="checkbox check-transparent"> <label for="opt01">Option 1</label> <input type="checkbox" value="1" id="opt01" checked> </div> <div class="checkbox check-transparent"> <label for="opt02">Option 2</label> <input type="checkbox" value="1" id="opt02"> </div> <div class="checkbox check-transparent"> <label for="opt03">Option 3</label> <input type="checkbox" value="1" id="opt03"> </div> </div> <div> </body> </html>
  24. 1 point
    Yes, if you are only communicating via the internet, and not using a browser, but each language is different. You would not use the same code or probably even the same language in Windows as you would in Linux.
  25. 1 point
    You have a program written in what? It seems to me that this is either an Android Java question or an iOS Swift question. Or is it Javascript that was loaded from a website which it has now lost connectivity to? Which is it?
  26. 1 point
    There's plenty of documentation online about localstorage, check MDN for plenty of info. e.g.: https://developer.mozilla.org/en-US/docs/Web/API/Storage/LocalStorage I don't give out my phone number, sorry. I'm happy to help you here.
  27. 1 point
    It's the same basic theory. You need a way to detect if there is a connection, and a place to store the data until there's a connection. If it's running in a browser then you can use localstorage to store the data until you detect a connection.
  28. 1 point
    Are you making an app, like those? If it was me, I would test for a connection to the app's servers and, if there is not one, then I would probably start by using a buffer to keep messages that are pending to be sent. If the app gets closed then I would write the buffer to permanent storage which I would check the next time it starts up.
  29. 1 point
    Are you sure you used enough tags for this post? If you want to know if something will work offline, it will help to know what that something is. What does it do that you don't think will work offline? If it's using server-side languages then you'll still need to have a local web server installed (or put it on a server on the network).
  30. 1 point
    You want what to happen, an anchor to get created or edited or something? Like with most things, instead of finding something that tells you exactly how to do specifically what you want to do, you need to understand the basics and the theory yourself so that you can apply that to build what you want. You can start here, but there's a lot more information online about dragging and dropping. https://www.w3schools.com/html/html5_draganddrop.asp
  31. 1 point
    Maybe they don't have example files on their server for you to use. You can open any other editor and add video and track tags if you want to though, as long as there are files online somewhere that you can point to.
  32. 1 point
    Well it would using MS Paint, but using FastStone Photo Resizer, it will do multiple selected images, to a specific size proportionately, rename adding custom suffix like '_thumb', and save to alternative format, to a destination you chose.
  33. 1 point
    Really? maybe is a Spain hosting problem, because they show how to install here https://help.1and1.com/hosting-c37630/webspace-and-access-c85098/ssh-c37775/install-imagemagick-via-ssh-a649013.html
  34. 1 point
    It only shows the source of files in the same local filesystem, regardless of domain name. If, for some reason, it did load a file from a URL it would only be able to show what was returned by that URL through HTTP.
  35. 1 point
    You have to login to google and create a project then select get JavaScript API under MAPS, you are then create a API key, which you use in your coding. The Iframe embed is similar, but apparently you have to create a secondary API key to ref. After that they should both show. Just follow instructions.
×