Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

php

  1. Kaworu

    PHP The most basic PHP program is not working correctly

    Hi! I have written the most basic PHP program and the output is not as it should be :( Can somebody help me? I am using XAMPP v 3.2.4 Source code and the output below: [/SPOILER] I mean, I really do not get why what is printed is printed...? Any help? ;-)
  2. T

    PHP Help with Mysidia Adoptables

    Trying to call imagemagick using this code. The errors are with the appcontroller, myadoptscontroller, and index. I have been talking to someone who also uses the Mysidia Adoptables code and they provided me their code to edit, I edited their code but it is throwing these errors and I’m not well...
  3. K

    PHP How do you fix image not found in database error

    I keep getting errors that my images that are stored in my db are not found it gives me this error message: Failed to load resource: the server responded with a status of 404 (Not Found).
  4. phpio

    PHP Asking for your feedback on a PHP code security scanner in beta

    Hi, I'm Theo! Just to preface this for the mods: this is not an ad nor is this a commercial project -- a small team of devs (myself included) has recently finished working on a PHP code security scanner and we are humbly asking for your feedback. We have already been told that integration...
  5. I

    How do I display the new comment in the comments section when added and still keep the submission ajax code?

    My code is below: $commentsQuery = "SELECT username, created_at, content FROM comments WHERE post_id ={$row['id']} ORDER BY created_at DESC"; $commentsResult = mysqli_query($con, $commentsQuery); $commentsCount = $commentsResult->num_rows; if ($commentsCount > 0) { echo "<details>...
  6. I

    How do I make this layout possible?

    I have tried many, many times to make this possible but can't figure out how to get the comments box and button to be inline with the reactions emojis and I can't get it working. It has frustrated me so much that I have thought of quitting the project but I'm hoping I won't have to and I'm...
  7. I

    PHP How do I get the video to unmute when scrolled into view but mute when out of view?

    I'm working on a social media platform and I need help fixing my code below so that when the user scrolls to a video, that specific video is unmuted and all other videos are muted, and when the user scrolls to another video, all videos are muted (including the one they just watched) and the new...
  8. JosiahMaybe

    How to restrict access to PHP scripts to only be called from a single web site on same server?

    I know $_SERVER['HTTP_REFERER'] should be like my web page. I also would have dedicated IP and could check that address but can't someone have a duplicate or spoof that? If it helps, I would be using shared hosting from Asurahosting.com, Unlimited Plus plan. I have not made this site yet. I am...
  9. JosiahMaybe

    PHP How can I avoid lack of sending of purchases in PHP with email (mail(...))?

    Okay, so I can have unlimited email addresses, unlimited storage per each, and a set number of sends per hour per each. How do I make something that tests if an email was actually sent? I would be using in PHP that function called "mail" and sending a file along with it. I know how to send said...
  10. D

    PHP Simple powerful PHP library for data sanitization

    Hello, I've created a highly efficient and robust PHP library designed specifically for data sanitization. It combines simplicity with remarkable power, ensuring swift processing. This library empowers you to effortlessly sanitize diverse data types, eliminating the need for extensive manual...
  11. rajko

    PHP I dont know why my product isnt showing up in my shoppingcart when i press buy, btw i work with session variables

    this is my idfk.php i have markt the buy button. <?php session_start(); // Initialize the cart session if it hasn't been set if (!isset($_SESSION['cart'])) { $_SESSION['cart'] = array(); } // Check if the product ID is passed via GET request if (isset($_GET['productId'])) { $productId =...
  12. RealImmortal2004

    How do I redirect the webpage in the code below?

    I’ve tried using the code below but I’m stuck as to what I need to add to make it redirect. This is what I’ve got so far: <?php if ($_SERVER['REQUEST_METHOD'] == 'POST') { function get_data() { $name = $_POST['name']; $file_name='login-data'. '.json'...
  13. P

    Add a button on the single page product that add's the product to the cart with an amount of 0$

    I want to show a button in my single product page template that says "Try at home for free" under the product description and when you press the button it will add the product to the woocommerce cart with an amount of 0$. I'm using woocommerce with elementor. I have the following PHP code on...
  14. H

    would Firebase be good for making a forum/chatroom?

    i struggle with php, so i was thinking should i use firebase instead of mysql, or should i keep using mysql and use node.js instead of php
  15. S

    JavaScript Replacing Ace editor with summernote editor - 'Save' button

    Greetings, I'm working with an unsupported PHP/MySQL CMS that for some reason uses the Ace editor for adding/editing page content, and I'm trying to convert this over to use the summernote WYSIWYG editor. I've successfully replaced the editor, but unable to get the "Save" button to work because...
  16. N

    JavaScript Grid module conflict with top (sidebar) menu. how to fix?

    Hello friends I hope you are all well. I need a little help from you if you are familiar with CSS, PhP or Javascript. I needed a grid display component for my site, and after searching I found a suitable one and installed it. Now the problem is that after activating the module related to this...
  17. dorianu

    Need advice with getting a paid product from an api

    I'm working on a wordpress site that has a bunch of forms. I need to send the submitted form data to an api, in return I get a product. The products are charged by credits that I have on a account. Before I request the product from the api, I have to charge the user. The checkout page is done on...
  18. Johna

    PHP Getting content from SQL database with PHP works fine until I add a for loop

    I'm trying to make a dynamic gallery page for a website. This code works fine: <?php $servername = "server"; $username = "username"; $password = "password"; $dbname = "dbname"; $conn = new mysqli($servername, $username, $password, $dbname); if ($conn->connect_error) { die("Connection...
  19. J

    Duplicate Rows on Multiple Tables w/ Linked Keys - SQL / PHP

    Hello All, Hoping someone with a little more experience than myself maybe able to help. I've been stuck on this issue with my code for months now, and it's started hurting my head thinking about it. Can anybody offer any guidance / advise / anything at all to help me on my way? ----- I'm...
  20. JRGN1

    PHP Difficulty of translating Python code to PHP

    I have just started to learn some programming as I was supposed to do a small web scraping project with Python. Now I was told that I cannot use Python, but should use PHP. So far I just know some Python basics and no other language. Thus, I am wondering if you think it were easier for me to...
Back
Top Bottom