Jump to content

phppup

Members
  • Content Count

    373
  • Joined

  • Last visited

Community Reputation

0 Neutral

About phppup

  • Rank
    Advanced Member

Profile Information

  • Gender
    Not Telling

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. phppup

    create mp4 with screen recording

    Can I simply change the MP4 extension to AVI just to confirm functionality?
  2. phppup

    create mp4 with screen recording

    I opened the webpage in both Firefox and Chrome and got the same result. I'm going to conclude that since these are the same browsers that played the video from W3 (both while at their URL and after saving the file locally) that it is not a browser issue. How do I proceed regarding the codecs, or is their a simpler / more effective way to make a simple screen recording for use on a webpage?
  3. This is a first time effort to create a video of my local pc workstation screen. Attempt #1 utilized an application provided in Windows 10 to create the MP4 file. Attempt #2 was to convert a Powerpoint 2010 presentation into an MP4 file Both seemed to go well, and produced files then when clicked independently on the desktop, will play their clip. However, when called from a local webpage "No video with supported format" is the message displayed where the working video is expected. <video width="400" controls> <source src="mov_bbb.mp4" type="video/mp4"> <source src="mov_bbb.ogg" type="video/ogg"> Your browser does not support HTML5 video. </video> <video width="400" controls> <source src="Presentation2.mp4" type="video/mp4"> <source src="Presentation2.mp4" type="video/ogg"> Your browser does not support HTML5 video. </video> I borrowed a video clip from W3 and it seems to work fine, which leads me to believe that either I am creating a damaged file or the file is not truly MP4. The file PROPERTIES indicate it is MP4 in all instances. Where did I go wrong?
  4. phppup

    maybe I'm searching incorrectly?

    You are correct. Located the problem and remedies it. So, if I make the EMAIL column unique, how would I trigger an error message to the user when a duplicate email is entered, without querying the table?
  5. phppup

    maybe I'm searching incorrectly?

    More info..... Here is my original code that works well PRIOR to attempting to acquire the LAST INSERT ID: $query = "SELECT * FROM table WHERE email='$email' "; //checks that email is unique $result = mysqli_query($conn, $query); //RUNS the above query if (mysqli_num_rows($result) == 0) { //if no duplicates exist, then INSERT $sql="INSERT INTO $table..... etc etc } So the question remains, how do I retrieve the LAST INSERT ID without having duplicate entries into my table, and without restructuring my code too drastically (as to affect other portions that use the same CONN).
  6. phppup

    maybe I'm searching incorrectly?

    Fought with code until I eventually put this after my INSERT statement: if (mysqli_query($conn, $sql)) { $last_id = mysqli_insert_id($conn); echo "New record is: " . $last_id; } else { echo "Error: " . $sql . "<br>" . mysqli_error($conn); } I finally got the ID value, except all entries into the table are being duplicated from each single form submission. It appears that this is because $sql is being called twice. I even tried to put this into a function (didn't execute at all). How do I get to a single table posting?
  7. phppup

    maybe I'm searching incorrectly?

    I'll research this. Do the ID's then become 'attached'? Am I better off creating a single form that requests ALL the info and delegating it to post accordingly?
  8. I don't mean to bother you with silly questions, but I must be using the wrong search terms to find any viable answers to this. Hypothetical situation: I have a table [Customers] with with an auto-increment id, customer_name and email generated from a form. Now, I decide to expand my database to include customer-address and telephone number. I decide to create a second table named Contactinfo for this purpose (assuming this is a better database practice). As Customerinfo is generated, I want it to POST in association with the respective customer (assuming that 'id' is the best field for association). I need some examples and best practices to accomplish this. Examples, links, or preferred terminology would be great so I can attack this phase. Thanks.
  9. phppup

    a silly DATE question

    Okay, got it. Yes, dates are in table. I believe I used SQL previously and this will add to it. If I'm not mistaken, I also used a PHP adaptation to test outside of the table (so that I could get comfortable with it and see results more easily).
  10. phppup

    a silly DATE question

    Barand, will that work in PHP or is that SQL only? If only this were a leap year I could test it in real time. LOL
  11. phppup

    a silly DATE question

    On a related note, I now have the basics to send a message to people listed in a database on their birthdate. It has occurred to me: what is the best way to deal with people with February 29 as their birthday? While the most simple solution would be to just forget them, that seems unfair. LoL Would the more practical approach be coding along the lines of: if(today +1) = March 1, then also include 2/29 from birthdate column? Will something like that work? Is it practical? Is there a better way?
  12. phppup

    a silly DATE question

    I may implement it. But I thank you either way. Just fiddling around, so it's not a major component of anything I am working with. And I'm actually happy to see that my own thought process to develop my own script to overcome this was along similar lines. Although yours is much, much cleaner and concise.
  13. phppup

    a silly DATE question

    At this point I clearly have too much time on my hands, as I started to tinker with different DATE options. $originalDate = 2003-03-03; //March 3rd, 2003 is the day number 62 in that year $day_of_the_YEAR = date("z", strtotime($originalDate)); //provides the day of the year starting with ZERO on 01/01 echo "($day_of_the_YEAR + 1)"; //allows me to ADD the ONE to compensate for the ZERO that begins the counter This is all OK, but then I tried to incorporate the English ordinal suffix by using the date format mechanism S. Not only did it not work, but when I edited my code to: $day_of_the_YEAR = date("zS", strtotime($originalDate)); echo "($day_of_the_YEAR)"; //because it won't work at all with the PLUS 1 the result for echo $day_of_the_YEAR was 61rd [which is neither accurate for March 3 nor acceptable as the correct English ordinal suffix. Is there a remedy, or is this due to trying to combine a non-date with the S switch?
  14. phppup

    gelElemetsByClassName question

    Already worked around the issue with a simpler and more effective solution. Just wanted to see if I could pull off something fancy. More trouble than it was worth, but a good learning experience. Thanks again.
  15. phppup

    gelElemetsByClassName question

    Something else I learned now. I had a hunch, but i thought it was worth a try to see if I could use CLASS in similar fashion to getElementById. It seems the short answer is NO. Thanks.
×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.