Jump to content

All Activity

This stream auto-updates     

  1. Past hour
  2. ameliabob

    Simple download

    I am trying to get a url that returns a json file but nothing seems to work nor do I get any errors <html> <body> <h1>Trial of getting url</h1> <?php echo "Hello World!"; $url = "https://api.iextrading.com/1.0/stock/market/batch?types=quote&filter=symbol,companyName,latestPrice,latestSource&symbols=AMD,APVO,DHI,ERI,GERN,LUV,LX,NVCR,TAP,WAR"; $url="https://www.espn.com"; $ans = fopen($url, "r"); ?> </body> </html> It should return the following: AMD quote symbol "AMD" companyName "Advanced Micro Devices Inc." latestPrice 15.8 latestSource "Close" APVO quote symbol "APVO" companyName "Aptevo Therapeutics Inc." latestPrice 5.54 latestSource "Close" DHI quote symbol "DHI" companyName "D.R. Horton Inc." latestPrice 40.75 latestSource "Close" ERI quote symbol "ERI" companyName "Eldorado Resorts Inc." latestPrice 44.25 latestSource "Close"
  3. Today
  4. caradri

    = vs like

    hi. this was working until now. and the string is exactly like in database. the data type is nchar(30), and looks like in the database its fill the string with white spaces to get length 30. may the datatype do that problem? something can make a change?
  5. Ingolme

    = vs like

    The semi-colon will not break the query, it will simply be ignored. The = operator will only return a row if the entire field exactly matches what is being searched. If you want to find rows that contain the search string along with more content then you must use the LIKE operator. If you think the fields do match exactly, make sure that they don't actually have spaces, tabs or other invisible characters that might be interfering with the search.
  6. dsonesuk

    few checkbox checked, but count as one

    If you mean three different attribute named grouped value checkbox inputs of three of each <!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta name="viewport" id="viewport" content="target-densitydpi=high-dpi,initial-scale=1.0"> <title>Document Title</title> <style> #wrap {width: 20%; margin: 0 auto;} form {border:3px solid #ccc; padding: 15px; margin: 10px;} .single-count{} </style> </head> <body> <div id="wrap"> <form name="myForm" action="#"> <label>chkboxGrp1</label> <input class="single-count" type="checkbox" name="chkboxGrp1[]" value="1" /> <input class="single-count" type="checkbox" name="chkboxGrp1[]" value="2" /> <input class="single-count" type="checkbox" name="chkboxGrp1[]" value="3" /> <hr> <label>chkboxGrp2</label> <input class="single-count" type="checkbox" name="chkboxGrp2[]" value="4" /> <input class="single-count" type="checkbox" name="chkboxGrp2[]" value="5" /> <input class="single-count" type="checkbox" name="chkboxGrp2[]" value="6" /> <hr> <label>chkboxGrp3</label> <input class="single-count" type="checkbox" name="chkboxGrp3[]" value="7" /> <input class="single-count" type="checkbox" name="chkboxGrp3[]" value="8" /> <input class="single-count" type="checkbox" name="chkboxGrp3[]" value="9" /> </form> <div>Checkbox group total selected: <span id="chkboxGroupCount">0</span></div> <div>Selected: <span id="chkboxSelected"></span></div> </div> <script> var chkbox = document.getElementsByClassName('single-count'); for (var i = 0; i < chkbox.length; i++) { chkbox[i].addEventListener('click', chkboxGrpCount); } function chkboxGrpCount() { var inputNameArray = []; for (var i = 0; i < chkbox.length; i++) { var chkBoxNameStripSqrBraces = chkbox[i].name.replace('[]', ''); if (inputNameArray.indexOf(chkBoxNameStripSqrBraces) === -1 && chkbox[i].checked === true) { inputNameArray.push(chkBoxNameStripSqrBraces); } } document.getElementById('chkboxGroupCount').innerHTML = inputNameArray.length; document.getElementById('chkboxSelected').innerHTML = inputNameArray.toString(); } </script> </body> </html>
  7. dsonesuk

    = vs like

    If that is exactly what you use, then maybe you should try it without the semicolon within the SQL query
  8. caradri

    = vs like

    Hi, all. I have a strange issue, i think. i have a sql database and a simple select query "select * from tablename where columname='stringtosearch'; " this work fine until today, today only works with like: "select * from tablename where columname LIKE '%stringtosearch%'; " WHY???😭
  9. gordonisnz

    W3CSS sidebar, and footer issues

    Hello. This is a brand new website & i'm upgrading my website to use W3CSS in other pages & creating this brand new site. http://tv.kwister.com/index1.php I am having difficulty in setting up a page with a side menu, & middle / footer. Do not worry about colours, i'm only using the weird colours too see what I am doing. 1) My sidebar is a quarter of the screen (I may reduce it later on..). The main body of the page uses style="margin-left:25%" - Is it possible to allow the sidebar to be a variable with - to increase or decrease depending on the text included in the sidebar (with a bit of padding), and also the main part of the screen to auto increase too ? I used the w3-quarter and w3-rest css parts but when i put text in the main body, it gets "hidden" by the sidebar. Ive changed it to w3-row and w3-col using the GRID system, but the text in the main screen is still hidden. Can this be fixed ? 2) Also, with the footer. I cant seem to move it under both the side and main parts of the screen (teal color). The footer part only goes across the bottom of the main part of the screen. Is there a way to fix this without using "style" at all ? & just CSS3 ? (edit - Changed to http://tv.kwister.com/index1.php - Using sidebar. index.php does not use sidebar)
  10. Yesterday
  11. i can spell html5!

    styling my link pages

    sorry to have to ask such a noob question but here goes. my pages has the all the folders (7 deadly sins, you play too loose!, not understanding starting hands etc.) I'm going to need but I'm not sure how to reference them in css. each page will of course have slightly different styles going on and I'm not sure how to reference them in css. heres the code(s) <div class="vbar"> <div class="vbartitle">In The Beginning</div> <ul> <li><a href="7.html"> The 7 Deadly Sins</a></li> <li><a href="loose.html"> You Play Too Loose!</a></li> <li><a href="hands.html"> (Not Understanding) Starting Hands</a></li> <li><a href="oop.html"> Playing Out Of Posistion</a></li> <li><a href="sel.html"> Be More Selective </a></li> <li><a href="co.html"> Commitment</a></li> <li><a href="take.html"> Take Advantage</a></li> <li><a href="tilt.html"> Stop Tilting!</a></li> </ul> </div> and the css .vbar{ position:absolute; left: 434px; top: 87px; width: 200px; border:1px solid #999; margin:100px 0px 10px 12px; text-align: center; } .vbartitle{ background-color: #ADD8E6; padding: 12px; text-align: center; font-weight:bold; } .vbar ul { list-style:none; padding: 0px; margin: 0px; } .vbar ul li { list-style:none; padding: 0px; margin: 0px; } .vbar ul li a{ display:block; padding: 10px; color:#000; text-decoration:none; border-bottom:1 px solid #f1f1f1; } .vbar ul li a:hover{ color: white; background-color: #0000FF; border-bottom:1px dashed #000; }
  12. JMRKER

    few checkbox checked, but count as one

    Well, I'm glad it solved your problems, but I don't know how it did. Can you give an example of the HTML layout with 3 groups of 3 checkbox and show how clicking on 2 and 1 and 2 in each of the groups (A,B,C) makes a total of 9 checked boxes?
  13. Dayo

    ASK THE WEB MASTERS

    I am building a pure HTML & CSS Website and I want to add a page for visitors to download audio. In the web page i want the visitors to be able to search for the audios by Year, or Name or Alphabetically, how do i go about the code and arranging the audio in the html code i need an example.
  14. Dayo

    ASK THE WEB MASTERS

    I suggest this title for everyone who wants to develop a web page or write a code and needs an assistant in a certain point but can't get any lecture concerning that on any tutorial, the person can ask the question here for someone who has an experience in that to provide a solution.
  15. dsonesuk

    few checkbox checked, but count as one

    I don't see how that would work with 3 different named groups of checkboxes? it sums up selected checkbox values of groups, not the number of groups selected.
  16. Sigmahokies

    few checkbox checked, but count as one

    Hey, hey! I just fixed what I want. all i have to remove "+" from =. it count as one! Thank you so much!
  17. Sigmahokies

    few checkbox checked, but count as one

    That is not what I am asking for. I am asking for to have few checkbox have been checked, but count as one. For example, If I put nine checkboxes on website, then I divide nine checkboxes into three group: Three checkboxes in one group, then three checkboxes in second group, then three checkboxes in third group, suppose someone click checkboxes two out of three checkboxes in first group, click one out of three checkboxes in second one, then click two out of three checkboxes in third one, so script would count three checked because it showed someone did it all nine checkboxes which divided into three group that will count as three checked. Get it? Please forgive me, English is not my primary language, it is my second language. My primary language is ASL. Thanks, Gary
  18. Badchip

    Protect PHP renaming with a pin number

    Then I just need to change the PHP name periodically & automatically.
  19. warrens0017

    session_start(): cannot send session cache limiter

    It had to be BOM. I just deleted the file and recreated it with using just work and then copied and pasted it into a bran new accedit.php page. IDK why my editors were not able to detect the BOM but that was is. Thank you all for the help.
  20. justsomeguy

    Pivot and Summarizing Text Rows

    SQL doesn't work that way, each column has a single value. What you can do is do a query that shows you how many companies sell each product, and another query that shows which products are not sold by any company. You can do another one to list every company that sells a particular product. For one of them: SELECT p.usn, p.web_short_description, COUNT(*) AS num_sellers FROM products AS p INNER JOIN companyoffering AS o ON p.usn=o.usn GROUP BY p.usn, p.web_short_description This should list products not sold by anyone: SELECT * FROM products WHERE usn NOT IN (SELECT usn FROM companyofferings) This will do the same thing and may be faster depending on how many records are in the tables: SELECT * FROM products AS p WHERE NOT EXISTS (SELECT * FROM companyofferings AS o WHERE p.usn=o.usn) And then to list companies: SELECT * FROM companies AS c WHERE EXISTS (SELECT * FROM companyofferings AS o WHERE o.brand_id=c.brand_id AND o.usn=123) You'll need to enter the USN you want to figure out which companies sell in that query.
  21. justsomeguy

    session_start(): cannot send session cache limiter

    It's saying that the output starts on the line before you use session_start, and the only thing you're showing on that line is the opening PHP tag. Assuming there is not a space before the opening PHP tag, it's got to be the BOM. The BOM does not appear as a character in the text editor, but it's there when it saves the file, and like anything else outside of the PHP block, PHP will send all of that as output to the browser. You need to explicitly save without the BOM. In Sublime, that's File -> Save With Encoding -> UTF-8. When you open a file without a BOM in Sublime and just hit save, it will not add the BOM back if it isn't already there, you don't need to always save files like that after you do it once. Although other editors might add it back in without you telling it to.
  22. Last week
  23. dsonesuk

    session_start(): cannot send session cache limiter

    Do you call the header() function, use php cookies, anywhere in your other scripts.
  24. warrens0017

    session_start(): cannot send session cache limiter

    I used Visual Studios, NotePad++, Sublime Text; All of them show that there is no UTF-8 BOMs.
  25. justsomeguy

    Download full documentation database

    They don't make that available, although they've sold books at some point. I don't see those on their site right now though.
  26. iwato

    jQuery's slideToggle( ) Extrapolation

    Never mind. I got it. .show() => .slideToggle(0 It was so easy! No wonder, I could not figure it out. Roddy
  27. Ingolme

    session_start(): cannot send session cache limiter

    According to the error message, output started on line 1. It could be that your file is encoded as UTF-8 with a Byte-Order Mark (BOM). The BOM are three bytes that appear at the beginning of the file and may be invisible in your editor. To make sure this does not happen, open the file in a code editor and make sure that the encoding of the file is UTF-8 without a BOM.
  28. BACKGROUND: The following piece of code is a little tricky, because it requires insight into more than what is shown. So, please allow me to show and tell, rather than only tell, and invite you to click on the menu option Sponsor Overview under the subheading Visitor Profile in the navigation bar of the Grammar Captive mainpage. Once arrived click on either of the two items entitled Visits per Number of Pages or Visits per Time Spent and then click again on the same item. What shows and what disappears are different. Now, I well understand why this occurs, but everything that I have tried to correct for it has failed. Indeed, I would like the toggle to effectuate a complete disappearance of both explanation and data, rather than just the explanation. The CODE $(".so_clarify, #visits_per_number_pages, #visits_per_duration").css('margin', '1em 0').hide(); $(".so_param").mouseenter(function() { $(this).css({"cursor":"pointer","font-weight": "800","color":"#ffffff"}); }); $(".so_param").click(function(event) { var index = $(".so_param").index(this); $(".so_clarify").eq(index).slideToggle(function() { if (index == 8) { $("#visits_per_number_pages").show(); } else if (index == 9) { $("#visits_per_duration").show(); } }); }); $(".so_param").mouseout(function() { $(this).css({"cursor":"none","font-weight": "normal","color":"#fadb9d"}); }); Roddy
  29. warrens0017

    session_start(): cannot send session cache limiter

    I just verified that all the inc files do NOT have the session_start(). Yes this is at the VERY TOP before all HTML tags. Yes there is no line break.
  1. Load more activity
×