Jump to content

phppup

Members
  • Posts

    895
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by phppup

  1. It's not really a problem as I think a slightly different effect. CSS seems to slide the entire form into place like moving a cracker from behind a box, and JQuery seems to 'unravel' like a paper towel roll that falls from a table. If necessary, I will try to post code when time permits.
  2. In playing with a contact form that will "slide down" from a given point in the webpage, and I've found two attractive methods. CSS seems to accomplish the affect with an animation that carries the contents of my form up and down depending on a toggle button. I found a similar effect using JQuery's slideDown("slow") or slideUp("slow"). The JQuery seems like a smoother effect as it appears to 'unravel' but I am less comfortable with JQuery and connecting to outside libraries. Can this effect be duplicated more readily with CSS? Is there a simplified JQuery (or a plain JavaScript) method that I haven't found?
  3. phppup

    Gradient border

    I've considered and toyed with the second container idea, but the issue there is that the gradient ellipse is NOT distributed evenly on the "borders" of my vertically shaped div box (and this ALSO makes formatting text more challenging). The best alternative (similar effect) that I can compare to (and may be forced to use) would be a CSS button with a glow effect. The difference is that I want that trickling off effect to be contained within a specified boundary (a frame) rather than bleeding into the webpage. Ultimately, I would (hypothetically) have 2 rows of 3 divs each showing different products that are available (ie: ice cream pops, cups, cones, sundaes, cakes, weekly special). THANKS for helping.
  4. I am trying to achieve a BORDER that will have a gradient effect in itself. border: 24px radial-gradient(red 5%, green 15%, blue 60%); This isn't working. The colors are for testing, but ideally,I would have an effect running from a light blue to a darker blue (similar to the lever that adjust the cool temperature in an air conditioner) and they would outline a div box. A button with an edged border could work too The key is that I want the gradient to eminate from the center to the outside of the object, not along the border (think of a water droplet in a pond) PS: the radial gradient in a div with rounded corners just isn't aligning the way it's like it.
  5. @kicken Am I able to do this with .addEventListener ? I've tried several alterations of the following with no success. var inputs = document.getElementsByTagName('input'); for(var i = 0; i < inputs.length; i++) { if(inputs[i].type == 'submit') { inputs.addEventListener("click", alert(inputs[i].value); } }
  6. I have TWO buttons inside a form. <form onsubmit="return myFunc()"> myFunc displays a confirmation box after a button is clicked. The message would be different depending on which button is clicked, but when I use alert(event.srcElement.id); I am getting a result that indicates that the FORM has been clicked, not which button has been clicked. How can I get the button result in order to create an IF statement for comparisons?
  7. I'm trying to upload images to a directory, but it seems that no matter how small the file sizes, the largest quantity uploaded is 20. I vaguely recall mention of a 20 MB maximum, but for test purposes, most of these files are only a few KB each. Any insight on this? On a related note, I had written code to reduce file sizes, but since this affects the array of images selected, are they being counted at the original size or the smaller size that results as each file in the array passes through the size-reduction process?
  8. @Nolan81 Your two word response gives no indication as to what EXACTLY you feel is a poor approach with regard to my question. Further, you failed to elaborate or provide an alternative solution to any of the previous posts that were informative and appreciated. If you read my post, you will see that it concluded by saying Therefore, you should realize how worthless and idiotic your words were to me and this thread.
  9. I am assembling a website that utilizes PHP/MySQLi for sign up and access. The thought had occurred regarding what would be involved to augment this for usability as an app. I've only begin to scratch the surface, but any helpful advice would be appreciated.
  10. I've used PHP's mail function previously and I'm thinking of using it again. At one point, I recall getting success messages when the mail function completed, but discovered that certain emails were never received by recipients. After much troubleshooting, I discovered that the shared hosting server that I was using included quota limits on outboard emails. Essentially (if my understanding is correct), the PHP confirmation was accurate, but the actual messages (after hitting the quota) were never dispatched. How can I get confirmation that the intended email actually left the server? Further, can I determine that it wasn't filtered by the recipient's email provider or tagged as spam?
  11. I tried the link also, but got nowhere because I do not have a Google account. One thought: if the file is too large, can you move it in batches (maybe 1000 rows at a time)?
  12. @requinix Yes, I believe I tried that initially. It may have worked; but then it didn't. After hours of futile efforts, I decided to post here and wait for a reply. However, it was a Sunday afternoon and ALL my sports teams were losing. *another season of tears* LOL My tenacity got the better of me and deeper down the rabbit hole I went. I haven't come up with an adequate solution (and may never do so) since this was supposed to be just a 15- minute cosmetic effect. However, I wanted to do my part as a contributor to the forum and share what I discovered: It appears, per a variety of resources that There seem to be several JavaScript/jQuery work-arounds or some CSS tricks to enable a smooth usefulness on every instance of an event-type. For now, I think I've taken it as far as I am willing to go. But the next person should be aware that events and CSS animations are not necessarily completely compatible under the current rules that govern them.
  13. I'll skip the boring details and get to it. This CSS code runs an animation for an INFINITE period. I want it to ONLY run "on mouse over" or the equivalent. I've changed the duration without issue, but cannot get it to run when desired .obj { height: 90vmin; position: relative; width: 90vmin; > div { animation: growAndFade 3s infinite ease-out; /* lots of settings */ } } I've tried different variations of using .obj :hover{ height: 90vmin; position: relative; width: 90vmin; > div :hover{ animation: growAndFade 3s infinite ease-out; /* lots of settings */ } } but seem to be missing the correct implementation. Helpful responses, please.
  14. @kicken I thought I'd share this interesting revelation. While beginning to alter my code to implement your suggested approach I //commented out// some areas of code. That's when I noticed that the color designations on my editing tool were inconsistent. Long story short, it seems my code was stalling because ////var array = <?php echo json_encode($business); ?>; did NOT remove the code, COMPLETELY and in fact created a hiccup until I tried ////var array = <?php /** echo json_encode($business); **/ ?>; Thankfully, now my code is working. PS: had to post on this fashion as the editor would not display the leading backslashes
  15. After unsuccessful efforts at trying to obtain my GPS location from a self-written PHP script, I moved to a more local JavaScript code. When opened on my Android phone with a Chrome browser, I received an error Y0ZkNV. Is there a way to resolve this without changing my hosting to an HTTPS platform? My goal is to be able to access my current location on my phone's browser.
  16. @maxxdNot really sure what you mean, but the same code worked fine when run separately with my PHP array. It only displayed a problem when I incorporated it into my form.
  17. @kicken Not sure what you mean or how to approach this Why? Me neither, but I realized that this cause was JSON, and wasn't sure if I had missed an aspect of "special handling" that might be required to neutralize any effects (other than hashtags to remove it... LOL)
  18. Hello all. I had hardcoded if(document.getElementById("Item_01").checked == true){ document.getElementById("Set_01").style.display = "block"; } else { document.getElementById("Set_01").style.display = "none"; } This referenced items in a form that corresponded to values in a PHP array and all seemed to work well. But when I realized that expanding to multiple items in the array would mean manually re-writing these same lines for every item, it occurred to me that writing a single piece of code to engage the array with a FOR LOOP would be more effective (and reduce code). I searched the web and discovered that this could be the answer to incorporate into my function: var array = <?php echo json_encode($business); ?>; I tested at each step to avoid issues, but noticed that while things seemed to work well, they stalled when I refreshed my webpage. Is there a specific way to exit the JSON or disable it so that the page works properly every time (as it does WITHOUT this variable? Should I be using a different approach to connect JavaScript to a PHP array?
  19. @kicken Ahhhh, now I see it. So, with the parenthesis I can receive an input as you described. But without the parenthesis I am successfully limiting the totality of characters submitted to 1+48+1 (adding the first and last). At this point, I'm kinda okay with using only the American alphabet, but still want to accommodate complex names with apostrophes and hyphens (I'm still skeptical of names with underscores; and the few with numerals will need to come up with their own nickname ie:Musk's kid). Thanks for the info
  20. @kicken Yes. I am building a form and want PHP to "scold" users that try to submit junk. (It will be used internally by a staff group that needs to be reliied on and trusted. LOL) I realize the need to sanitize names and was going to simply require a-zA-z to eliminate numbers and characters. Then I realized that there are names with hyphens, apostrophes, and spaces, so down the rabbit hole I went. @requinix which left me with $pattern = "/^[A-Z]([a-zA-Z '&-]{1,48})*[A-Za-z]$/"; Is that the same as yours? Do my parentheses alter the outcome? So I guess, thanks to your assistance, I made progress after all. I just have to be more careful about using cut & paste BEFORE my coffee.
  21. @requinix Ok, I think I got it. $pattern = "/^([A-Z][a-zA-Z '&-]{2,4})*[A-Za-z]$/"; Please tell me if this is the [correct] solution that you eluded to. I moved the opening parenthesis to the middle section. Ironically, I may have inadvertently discovered something, as I altered the range for easier testing (but stumbled upon new conditions). Effectively, this modified range of 2,4 had to affect ONLY this mid-section of the string. So, the first character is [A-Z] And the last is [A-Za-z] So with the mid-section {2,4} a total of 3 characters will FAIL the test but 4 thru 6 pass, and then 7 or greater fails. Of course, a minimum of 1 will elevate the minimum to a total of 3 (if a special character is used) I did notice that 2 characters only (being first and last) will pass, but I imagine that adding a minimum to the last set of characters would correct that. My final solution is $pattern = "/^([A-Z][a-zA-Z '&-]{1,48})*[A-Za-z]$/"; Is this the same as your solution?
  22. @requinix Some deeper testing has revealed an unexpected issue. For test purposes I changed the range $pattern = "/^([A-Z][a-zA-Z '&-]{0,4})*[A-Za-z]$/"; and discovered that while the RegEx seems to have a few holes for what would be allowed, it is NOT returning 0 to keep the minimum requirement at two characters. In fact, a single uppercase A passed the test of acceptance.
  23. Well, of course (!of_course] Now, it's confirmed to my needs, but I still pose the question, since sometimes even testing does not reveal what a more educated eye can plainly see.
  24. Ahhhh, so that's the trick!! I used parenthesis (that seem to resolve the issue) but I'd like to avoid any unforeseeable surprised. $pattern = "/^([A-Z][a-zA-Z '&-]{1,48})*[A-Za-z]$/"; Please check to confirm that this working solution is the most correct implementation.
  25. Trying to utilize this expression $pattern = "/^[A-Z][a-zA-Z '&-]*[A-Za-z]$/"; to take name to start with a capital letter, allow some symbols or space, and then continue with more letters. How can I require the length of all characters be involved to be between 3 and 50 keystrokes? Ice tried {3,50} in several positions but none seem to be making the connection that I want. Thanks
×
×
  • Create New...

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.