How to fix multiple SEO issues found in website audit – prioritization and implementation guidance [closed]

HIGH Priority Issues:

URL Canonicalization: Need to select primary URL and set up redirects

Keyword Optimization: Title tag, meta description, and heading tags need common keywords

Custom 404 Page: Missing custom 404 error page with helpful links

Structured Data: No structured data markup implemented

Render-blocking Resources: Page has render-blocking resources affecting performance

Image Format Optimization: Images not in modern formats (WebP, AVIF)

MEDIUM Priority Issues:

Social Media Integration: No social media API/AddThis integration

LOW Priority Issues:

SPF Record: Missing SPF record for email security

HSTS Header: Missing Strict-Transport-Security header

PHP script not reading set cookie in Safari OSX and iOS

Problem: verified cookie set in PHP and visible in developer tools is not detected by PHP for Safari. Same script is working fine in Chrome and Firefox.

Simplified example that illustrates the problem:

setcookie( 'cookiename', '1', time()+1200, '/' );

Reloading the page or loading other pages shows the cookie visible in the browser storage with the correct value in Safari. PHP on any page returns an empty $_COOKIE array but only in Safari.

var_dump( $_COOKIE );

array(0) {}

… in JS

document.cookie

I’ve read at least a dozen Safari cookie issues and solutions all over the web, including these:

$_COOKIE not working in Safari iOS

Not able to read cookie on JS side on Safari/iPhone

None appear to be relevant to the issue I’m facing.

TLDR: cookie is verified set correctly in Safari but PHP or JS to read it shows empty $_COOKIE array.

EDIT: suggested solution on the most similar problem I have found:
Use the assoc array options as detailed in docs: https://www.php.net/manual/en/function.setcookie.php

    setcookie( 'cookiename', '1', [
        'expires' => time()+1200,
        'path' => '/',
        'domain' => 'domain.com',
        'secure' => false,
        'httponly' => false,
        'samesite' => 'Lax',
        ]
    );

RESULT: Safari functioning as expected locally, but not on WPE server though the cookie is still visibly set but not read on subsequent page loads.

Laravel HasUuids trait causes conflicts

Laravel 11. I have a model which uses Laravel’s HasUuids trait:

use IlluminateDatabaseEloquentModel;
use IlluminateDatabaseEloquentConcernsHasUuids;

class Foobar extends Model
{
  use HasUuids;
  /* ... */
}

In PhpStorm (2025.1.0.1), the “use HasUuids” line has a red squiggly underline, and hovering over it shows this error:

Trait method ‘uniqueIds’ will not be applied because it collides with ‘HasUuids’

Trait method ‘resolveRouteBindingQuery’ will not be applied because it collides with ‘HasUuids’

Trait method ‘getIncrementing’will not be applied because it collides with ‘HasUuids’

Trait method ‘getKeyType’ will not be applied because it collides with ‘HasUuids’

Trait method ‘uniqueIds’ will not be applied because it collides with ‘HasUniqueStringIds’

Trait method ‘resolveRouteBindingQuery’ will not be applied because it collides with ‘HasUniqueStringIds’

Trait method ‘getIncrementing’ will not be applied because it collides with ‘HasUniqueStringIds’

Trait method ‘getKeyType’ will not be applied because it collides with ‘HasUniqueStringIds’

The collisions, I think, occur between the HasUuids trait (and the HasUniqueStringIds trait it in turn uses), and the Model class which FooBar extends. How can I remove this error report? Is it just a bug in PhpStorm?

PHP copy() function failed to overwrite file even executed as root in Alma linux

I have a PHP script that copies a file from one location to another, the script looks like this:

$success = copy('/tmp/source_test.txt', '/tmp/target_test.txt');
    if (!$success) {
        echo "Copy failed: " . error_get_last()['message'] . "nn";
    } else {
        echo "Copied OKnn";
    }

Both source_test.txt and target_test.txt exist and have the owner and permission set as follows:

  • source_test.txt (Owner: root:root; chmod: 644)
  • target_test.txt (Owner: php:wwwuser; chmod: 644)

I run the script on 2 server instances as ‘root’ by calling php /path/to/script.php, both instances are on Alma linux.

  • On the first instance, it works fine, the target_test.txt gets overwritten.
  • On the second instance, it fails with this message “Failed to open stream: Permission denied”.

It looks like the second is missing something or configuration that the PHP copy() function, even though being executed as root, does not have the permission to overwrite the target file.

Anyone experienced this problem before? Any advice is appreciated.

guide to simple php do not delete [closed]

this is the get based api needed

if($_SERVER['REQUEST_METHOD'] === "GET" && count($_GET) == 0)
{
    require_once "connect.php";
    $connection = connect();
    $sql = "";
    $result=$connection->query($sql)->fetch_all(MYSQLI_ASSOC);
    $connection->close();
    header("Content-type: application/json; charset=utf-8");
    http_response_code(200);
    echo json_encode($result, JSON_UNESCAPED_UNICODE);
}
else
{
    http_response_code(400);
}
?>

connect.php:

<?php
function connect()
{
    return new mysqli("localhost","root","","palyazatok");
}
?>

php, aka the main site where the things are seen:


 <?php
            $url = "full path to api file";
            $sv = file_get_contents($url);
            echo $sv;
        ?>

if needed in table:

<?php
            $url = "full path to api file";
            $sv = file_get_contents($url);
            $data = json_decode($sv);
        ?>

        <table class="table">
            <thead>
                <tr>
                    <th></th>
                    <th></th>
                    <th></th>
                </tr>
            </thead>
            <tbody>
                <?php
                    foreach($data as $row)
                    {
                        echo '
                            <tr>
                                <td>'.$row->sql column (ex. id).'</td>
                                <td>'.$row->sql column (ex. id).'</td>
                                <td>'.$row->sql column (ex. id).'</td>
                            </tr>';
                    }
                ?>
            </tbody>
        </table>

some more details details details dw bout it I am adding details to it please I beg you let me post these are all the details needed

the api part: !!NEEDED LATER WITH ADDING NEW!!

   <?php
   if($_SERVER['REQUEST_METHOD'] === "GET" && count($_GET) == 1 && isset($_GET['id']) && (int) $_GET['id'] > 0)
   {
       $id = (int) $_GET['id'];
       require_once "connect.php";
       $connection = connect();
       $sql = "";
       $result = $connection->query($sql)->fetch_all(MYSQLI_ASSOC);
       $connection->close();
       header("Content-type: application/json; charset=utf-8");
       http_response_code(200);
       echo json_encode($result, JSON_UNESCAPED_UNICODE);
   }
   else
   {
       http_response_code(400);
   }
   ?>

here is the frontend part, the forms is the dropdown:

<?php
           $url = "entire path to api file";
           $sv = file_get_contents($url);
           $data = json_decode($sv);

           if(isset($_GET['id']) && trim($_GET['id']) !== "")
           {
               $id = (int) $_GET['id'];
               $url = "path to api?id=".$id;
               $sv = file_get_contents($url);
               $result = json_decode($sv);
           }
           else
           {
               $result = [];
           }
       ?>

       <form action="file.php" method="get">
           <select name="id" onchange="submit()">
               <option value="">--- choose ... ---</option>
               <?php
                   foreach($data as $d)
                   {
                       $s = isset($_GET['id']) && $_GET['id'] == $d->id ? "selected" : "";
                       $text = $d->id."sql fields you want to appear" ;
                       echo '<option value="'.$d->id.'" '.$s.'>'.$text.'</option>';
                   }
               ?>
           </select>
       </form>

       <?php
       if(count($result) == 0)
       {
           echo '<h3>womp</h3>';
           return;
       }
       ?>

       <table class="table table-bordered table-hover table-stripped table-success mt-3">
           <thead>
               <tr>
                   <th>Számlaszám</th>
                   <th>Dátum</th>
                   <th>Érték</th>
                   <th>Költség megnevezése</th>
               </tr>
           </thead>
           <tbody>
               <?php
                   foreach($result as $row)
                   {
                       echo '
                           <tr>
                               <td>'.$row->id.'</td>
                           </tr>
                       ';
                   }
               ?>
           </tbody>
       </table>

!$text = $d->id.”sql fields you want to appear” ;! in php adding values and string works with . so it will look like: $d->id.”Id “.name.” this data”; or smth like that the $s is referring to selected

deleting through api:

    <?php
if($_SERVER['REQUEST_METHOD'] === "POST" && count($_POST) == 1 && isset($_POST['id']) && (int) $_POST['id'] > 0)
{
    $id = (int) $_POST['id'];
    require_once "connect.php";
    $connection = connect();
    $sql = "DELETE FROM ... WHERE Id = '$id'";
    $result=$connection->query($sql)-> fetch_all(MYSQLI_ASSOC); ;
(if needed just repeat these two lines (if it needs to delete from multiple tables)
    $connection->close();
    header("Content-type: application/json; charset=utf-8");
    http_response_code(200);
    $result=[];
    echo json_encode($tomb, JSON_UNESCAPED_UNICODE);
}
else
{
    http_response_code(400);
}
?>

the php part to this:

<?php
        if ($_SERVER['REQUEST_METHOD'] === "POST" && isset($_POST['id']) && (int) $_POST['id'] > 0)
{
    $id = (int) $_POST['id'];
    $data = http_build_query(['id' => $id]);

    $context = stream_context_create([
        'http' => [
            'method'  => 'POST',
            'header'  => 'Content-type: application/x-www-form-urlencoded',
            'content' => $data
        ]
    ]);

    file_get_contents("full path again");

    header("Location: file.php", false, $context);
    exit;
}
    ?>

adding inserting into database (this is only one php file):

<?php
        if($_SERVER['REQUEST_METHOD'] === "POST" && isset($_POST['p_id'],$_POST['k_id'],$_POST['szszam'],$_POST['datum'],$_POST['ertek']))
        {
            $p_id = $_POST['p_id'];
            $k_id = $_POST['k_id'];
            $szszam = $_POST['szszam'];
            $datum = $_POST['datum'];
            $ertek = $_POST['ertek'];
            $sql = "INSERT INTO ... VALUES ('$szszam', '$datum', '$ertek', '$p_id', '$k_id')";
            require_once "connect.php";
            $kapcs = connect();
            $kapcs->query($sql);
            header("location:previous_file.php?id=$p_id");
            return;
        }
    ?>

        <?php
        //might need this multiple times
            $url = "api where it gave back json.php";
            $sv = file_get_contents($url);
            $data = json_decode($sv);
        ?>

        <form method="post" action="file.php">
            <select name="d_id" required>
                <option value="">--- choose ---</option>
                <?php
                    foreach($data as $d)
                    {
                        $txt = $d->id.' - '.......;
                        echo '<option value="'.$d->id.'">'.$txt.'</option>';
                    }
                ?>

body of the question, I do not need any more explaining, I can see through this just fine. please details details details details details

PHP Automatically Get GPS Coordinates Latitude, Longitude and Altitude Without $_POST[”]; and Insert Into Database [duplicate]

enter image description here

enter image description here

enter image description here

enter image description here

enter image description here

P.H.P. Automatically Get G.P.S. Coordinates Latitude, Longitude and Altitude Without $_POST[”]; and Insert Into Database.

So far I can get the G.P.S. coordinates through $_POST[”] and send the coordinates by variable execution into the database as well as by an fwrite(); into a file.

I can’t seem to figure out how to get the coordinates without $_POST[”]; and write something to automatically put the coordinates into the database upon every reload of the web page document.

I have already tried $_GET[”]; methods and it does not work.

/*
============================================================================================================
 +
 + IF: Internal Application: Display :: Location :: Log Global-Positioning-System Coordinates :: Manual
 +
 ============================================================================================================
*/

if ($_GET["Display"] == "LogGPS_Manual") {

echo ("
<FORM ACTION="?$_INTERNAL_APPLICATION_MODULE_MEMBER&#61;Control_Panel&amp;Display&#61;LogGPS_Manual" METHOD="POST">
      <INPUT TYPE="hidden" NAME="latitude" ID="latitude">
      <INPUT TYPE="hidden" NAME="longitude" ID="longitude">
      <INPUT TYPE="submit" NAME="submit" VALUE="Display and Log Current G.P.S. Coordinates">
</FORM>
 
<SCRIPT TYPE="text/javascript">
    function getLocation() {
        navigator.geolocation.getCurrentPosition(showPosition);
}
 
function showPosition(position) {
    document.querySelector('#latitude').value = position.coords.latitude;
    document.querySelector('#longitude').value = position.coords.longitude;
}
 
getLocation();
</SCRIPT>
");

/*
 ============================================================================================================
 + IF: Internal Application: Device Test :: Global-Positioning-System Coordinates :: Chip :: Input Form :: Variables HAVE Executed, Display: G.P.S. Chip Location
 ============================================================================================================
*/
 
if (isset($_POST['submit'])) {

$_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE                  = $_POST['latitude'];
$_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE                 = $_POST['longitude'];

echo ("
        <BR><HR WIDTH="25%" ALIGN="LEFT">
            Global-Positioning-System Coordinates :: Current
        <HR WIDTH="25%" ALIGN="LEFT">
            *&nbsp;Global-Positioning-System Coordinates :: Device :: Chip: Latitude: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE<BR>
            *&nbsp;Global-Positioning-System Coordinates :: Device :: Chip: Longitude: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE<BR>
            *&nbsp;Global-Positioning-System Coordinates :: Device :: Chip: Altitude To Sea-Level: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_ALTITUDE<BR>
            *&nbsp;Highlight and Copy Together: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE, $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE<BR>
");

/*
 ============================================================================================================
 + Database Management System Server :: Database :: Query :: Update :: Registered Member Account :: Global-Positioning-System :: Coordinates :: From :: Hyper-Text-Markup-Language :: Get Location
 ============================================================================================================
*/

$_Application_Module_Member_Control_Panel_DB_Query_UPDATE_MEMBER_ACCOUNT_GPS_HTML_XYZ           = $_GLOBAL_DATABASE_MANAGEMENT_SYSTEM_SERVER_DATABASE_CONNECTION->query("UPDATE {$_ACCESS_DATABASE_SERVER_DATABASE_TABLE_PREFIX}_members SET
member_location_device_html_gps_x='$_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE',
member_location_device_html_gps_y='$_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE'
WHERE member_username='$_GLOBAL_COOKIE_MEMBER_USERNAME'");

/*
 ============================================================================================================
 + IF: Database Management System Server :: Database :: Query :: Update :: Registered Member Account :: Global-Positioning-System :: Coordinates :: From :: Hyper-Text-Markup-Language :: Get Location
 ============================================================================================================
*/

if ($_Application_Module_Member_Control_Panel_DB_Query_UPDATE_MEMBER_ACCOUNT_GPS_HTML_XYZ) {

echo ("*&nbsp;The Current Global-Posititioning-System Coordinates Were Inserted Into This Registered Member Account Database Entry.<BR>");

} // [ + ] IF: Database Management System Server :: Database :: Query :: Update :: Registered Member Account :: Global-Positioning-System :: Coordinates :: From :: Hyper-Text-Markup-Language :: Get Location

/*
 ============================================================================================================
 + Write To File :: Registered Member Account :: Activity Log :: Raw Log :: Global-Positioning-System :: Coordinates :: H.T.M.L. :: Manual
 ============================================================================================================
*/

$_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_FIND_FILE_NAME        = "./Member/$_GLOBAL_COOKIE_MEMBER_USERNAME/Files/Document/Activity_Logging/$_GLOBAL_LOCAL_SERVER_DATE_NUMERICAL_YEAR_FULL/$_GLOBAL_LOCAL_SERVER_DATE_NUMERICAL_MONTH_FULL/$_GLOBAL_LOCAL_SERVER_DATE_NUMERICAL_MONTH_DAY_FULL/Log_Member_GPS_Coordinates_HTML_Manual.html";
$_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_OPEN_FILE_NAME        = fopen("$_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_FIND_FILE_NAME", "a");

$_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_RAW_FIND_FILE_NAME        = "./Member/$_GLOBAL_COOKIE_MEMBER_USERNAME/Files/Document/Activity_Logging/Log_Member_GPS_Coordinates_Raw_Manual.php";
$_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_RAW_OPEN_FILE_NAME        = fopen("$_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_RAW_FIND_FILE_NAME", "a");

/*
 ============================================================================================================
 + IF: Write To File :: Registered Member Account :: Activity Log :: Raw Log :: Global-Positioning-System :: Coordinates :: H.T.M.L. :: Manual
 ============================================================================================================
*/

if (fwrite($_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_OPEN_FILE_NAME, "
-----------------------------------------------------------------------------------------------<BR>
- Global-Positioning-System Coordinates Log Entry<BR>
-----------------------------------------------------------------------------------------------<BR>
* Global-Positioning-System Coordinates :: Timestamp :: Device :: This Web Server: $_GLOBAL_LOCAL_SERVER_DATE_STANDARD<BR>
* Global-Positioning-System Coordinates :: Timestamp :: Device :: Connected Device: <A HREF="$_SYSTEM_SERVER_NETWORKING_RESOLVER_TIMESTAMP_UNIX_EPOCH" TITLE=":: Open & Display :: The Official :: Unix-Epoch Timestamp Resolver :: For This Unix-Epoch Timestamp ::" TARGET="_NEW">$_GLOBAL_LOCAL_SERVER_TIME_UNIX</A><BR>
* Global-Positioning-System Coordinates :: Longitude: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE<BR>
* Global-Positioning-System Coordinates :: Latitude: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE<BR>
* Global-Positioning-System Coordinates :: Altitude: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_ALTITUDE<BR>
* Internet Protocol Address :: Device :: This Web Server :: <A HREF="$_SYSTEM_SERVER_NETWORKING_RESOLVER_WHOIS/$_GLOBAL_REMOTE_SERVER_ADDRESS" TITLE=":: Open & Display :: The Who-Is Data :: For :: $_GLOBAL_LOCAL_SERVER_ADDRESS ::" TARGET="_NEW">$_GLOBAL_LOCAL_SERVER_ADDRESS :: Port Number: $_GLOBAL_LOCAL_SERVER_PORT</A><BR>
* Internet Protocol Address :: Device :: Connected Device :: <A HREF="$_SYSTEM_SERVER_NETWORKING_RESOLVER_WHOIS/$_GLOBAL_LOCAL_SERVER_ADDRESS" TITLE=":: Open & Display :: The Who-Is Data :: For :: $_GLOBAL_REMOTE_SERVER_ADDRESS ::" TARGET="_NEW">$_GLOBAL_REMOTE_SERVER_ADDRESS :: Port Number: $_GLOBAL_REMOTE_SERVER_PORT</A><BR>
* Highlight and Copy Together: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE, $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE<BR>
* Google Maps: <A HREF="https://www.Google.com/maps/place/$_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE, $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE" TITLE=":: Open & Display :: Google Maps :: Global-Positioning-System Coordinates :: For :: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE, $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE" TARGET="_NEW">$_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE, $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE</A><BR><BR>
")) {

echo ("*&nbsp;The Current Global-Posititioning-System Coordinates Were Manually Inserted Into This Registered Member Account Log File.<BR>");

} // [ + ] IF: Write To File :: Registered Member Account :: Activity Log :: Raw Log :: Global-Positioning-System :: Coordinates :: H.T.M.L. :: Manual

/*
 ============================================================================================================
 + Close File :: Registered Member Account :: Activity Log :: Raw Log :: Global-Positioning-System :: Coordinates :: H.T.M.L. :: Manual
 ============================================================================================================
*/

fclose($_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_OPEN_FILE_NAME);

/*
 ============================================================================================================
 + IF: Write To File :: Registered Member Account :: Activity Log :: Raw Log :: Global-Positioning-System :: Coordinates :: P.H.P. :: Manual
 ============================================================================================================
*/

if (fwrite($_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_RAW_OPEN_FILE_NAME, "
-----------------------------------------------------------------------------------------------
- Global-Positioning-System Coordinates Log Entry
-----------------------------------------------------------------------------------------------
* Global-Positioning-System Coordinates :: Timestamp :: Device :: This Web Server: $_GLOBAL_LOCAL_SERVER_DATE_STANDARD
* Global-Positioning-System Coordinates :: Timestamp :: Device :: Connected Device: $_GLOBAL_LOCAL_SERVER_TIME_UNIX
* Global-Positioning-System Coordinates :: Longitude: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE
* Global-Positioning-System Coordinates :: Latitude: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE
* Global-Positioning-System Coordinates :: Altitude: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_ALTITUDE
* Internet Protocol Address :: Device :: This Web Server :: $_GLOBAL_LOCAL_SERVER_ADDRESS :: Port Number: $_GLOBAL_LOCAL_SERVER_PORT
* Internet Protocol Address :: Device :: Connected Device :: $_GLOBAL_REMOTE_SERVER_ADDRESS :: Port Number: $_GLOBAL_REMOTE_SERVER_PORT
* Highlight and Copy Together: $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE, $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE
* Google Maps: https://www.Google.com/maps/place/$_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LATITUDE, $_Application_Module_Member_Devices_POST_DEVICE_TEST_GPS_CHIP_LONGITUDE
")) {

echo ("*&nbsp;The Current Global-Posititioning-System Coordinates Were Manually Inserted Into This Registered Member Account Log File.<BR>");

} // [ + ] IF: Write To File :: Registered Member Account :: Activity Log :: Raw Log :: Global-Positioning-System :: Coordinates :: H.T.M.L. :: Manual

/*
 ============================================================================================================
 + Close File :: Registered Member Account :: Activity Log :: Raw Log :: Global-Positioning-System :: Coordinates :: P.H.P. :: Manual
 ============================================================================================================
*/

fclose($_Application_Module_Control_Panel_Log_Member_GPS_Coordinates_HTML_Manual_RAW_OPEN_FILE_NAME);

} // [ + ] IF: Internal Application: Device Test :: Global-Positioning-System Coordinates :: Chip :: Input Form :: Variables HAVE Executed, Display: G.P.S. Chip Location

} // [ + ] IF: Internal Application: Control Panel :: Registered Member Account :: Display :: Log Global-Positioning-System-Coordinates :: Manual :: Is: Activated

Elementor form and Tera wallet: Display an error message if the balance is insufficient

In my WordPress website, I’m using WooCommerce and Tera Wallet plugins. An Elementor form debits the customer wallet based on the option they choose. I would like to display an error message when the customer balance is insufficient.

Screenshots:

enter image description here

enter image description here

  • Small – 1000 Words. (0.80$)|0.80
  • Medium – 2000 Words. (0.90$)|0.90
  • Large – 3000 Words. (1.00$)|1.00

Current code that makes the discount in the user’s Tera wallet:

add_action( 'elementor_pro/forms/new_record', function( $record, $handler ) {
    // Nome do formulário (configure no Elementor, aba Avançado > Nome do formulário)
    $form_name = $record->get_form_settings( 'form_name' );
    if ( 'artigo_saldo' !== $form_name ) {
        return; // Evita interferir em outros formulários
    }

    // Captura os campos do formulário
    $fields = $record->get( 'fields' );

    // Verifica se o campo saldo_artigo foi preenchido
    if ( empty( $fields['saldo_artigo']['value'] ) ) {
        return;
    }

    // Converte o valor para float
    $valor = floatval( $fields['saldo_artigo']['value'] );

    // Pega o usuário logado
    $user_id = get_current_user_id();

    if ( $user_id && $valor > 0 ) {
        $descricao = 'Débito automático após envio do formulário de artigo';

        // Realiza o débito da carteira
        woo_wallet()->wallet->debit( $user_id, $valor, $descricao );
    }

}, 10, 2 );

Laravel Local Network Development – Fixing SSL and Asset Loading Issues on Ubuntu

I’m trying to run my Laravel project over the local network for development using the following command:

php artisan serve --host=192.168.1.88

The landing page loads fine, but when I try to log into the system, I encounter this error:

192.168.1.88:40062 Invalid request (Unsupported SSL request)

Additionally, assets (CSS/JS/images) are not loading properly after login.

I’m currently using Ubuntu OS, and this issue only happens after login — it seems like an SSL-related problem, even though I’m not using HTTPS explicitly.

What I suspect:

  • Laravel or the web server might be trying to redirect to HTTPS after login.
  • Some middleware (like RedirectToHttps) could be forcing HTTPS.
  • The asset URLs might be being generated as https:// instead of http:// in certain parts of the application.

What I’ve tried so far:

  • Confirmed APP_URL=http://192.168.1.88:8000 in my .env file.

  • Cleared config cache using:

    php artisan config:clear
    php artisan cache:clear
    php artisan route:clear

  • Restarted the Laravel server.

What I need:

  • A solution to disable any forced HTTPS redirection during local development.

  • A way to ensure assets load over HTTP when using php artisan serve without SSL.

  • Any config or server change required to fix the “Invalid request (Unsupported SSL request)” error.

Could you please help me identify and fix this issue?

Laravel Redirect Type Error when using livewire on middleware routes

I have fresh installed laravel application, I add Livewire on that project. After I install breeze with php artisan breeze:install then I choose livewire, I got error when I go to some routes with middleware on that route. For example, I go to /dashboard without login, I got type error like this

{closure:{closure:/project/bootstrap/app.php:33}:35}(): 
Argument #1 ($response) must be of type IlluminateHttpResponse,
 IlluminateHttpRedirectResponse given

but when I go to /dashboard after login, its run normaly.

This is my standard route for auth

Route::get('dashboard', [DashboardController::class, 'index'])
    ->middleware(['auth', 'verified'])
    ->name('dashboard');

And error is located at bootstrap/app.php on this line

$exceptions->respond(function (Response $response, Throwable $exception, Request $request) {
           

Is there any special function or code for routes using livewire in my case?

How to display a list of appointments with related user data in Symfony/Twig

‘m building an appointment management system in Symfony. I have an Appointment entity that relates to User entities for both student and teacher. I want to display a list of all appointments in a Twig template, showing the student’s first name, teacher’s first name, appointment time, and location. Additionally, I want to have links to edit and delete each appointment.

Here is my setup:

appointment/index.html.twig

<?php

namespace AppController;

use SymfonyBundleFrameworkBundleControllerAbstractController;
use SymfonyComponentHttpFoundationResponse;
use SymfonyComponentRoutingAttributeRoute;
use AppEntityAppointment; 
use AppEntityClasses;
use AppEntityUser;
use DoctrineORMEntityManagerInterface; 
use AppFormAppointmentTypeForm;
use SymfonyComponentHttpFoundationRequest;


final class AppointmentController extends AbstractController
{
 
#[Route('/appointment', name: 'app_appointment')]
public function read(EntityManagerInterface $entityManager): Response
{
    //Ophalen van alle boeken
    $appointments = $entityManager->getRepository(Appointment::class)->findAll();

    //Tonen van de juiste view (renderen)
    return $this->render('appointment/index.html.twig', [
        'appointments' => $appointments,
    ]);
}

//Functie om een boek toe te voegen verder op
#[Route('/create', name: 'app_create')]
public function add(Request $request, EntityManagerInterface $entityManager): Response
{
    $form = $this->createForm(AppointmentTypeForm::class);
    $form->handleRequest($request);
    if ($form->isSubmitted() && $form->isValid()) {
        $appointment = $form->getData();
        $entityManager->persist($appointment);
        $entityManager->flush();

        $this->addFlash('success', 'Het appointment is toegevoegd');

        return $this->redirectToRoute('app_appointment');
    }

    return $this->render('appointment/create.html.twig', [
        'form' => $form
    ]);
}


#[Route('/appointment/edit/{id}', name: 'app_appointment_edit')]
public function edit(Request $request, EntityManagerInterface $entityManager, int $id): Response
{

     $appointment = $entityManager->getRepository(Appointment::class)->find($id);
    $form = $this->createForm(AppointmentTypeForm::class, $appointment);

    $form->handleRequest($request);
    if ($form->isSubmitted() && $form->isValid()) {
        $appointment = $form->getData();
        $entityManager->persist($appointment);
        $entityManager->flush();

        $this->addFlash('success', 'Het appointment is toegevoegd');

        return $this->redirectToRoute('app_appointment');
    }

    return $this->render('appointment/create.html.twig', [
        'form' => $form
    ]);
}

#IsGranted[("ROLE_ADMIN")]
#[Route('/appointment/delete/{id}', name: 'app_appointment_delete')]
public function delete(EntityManagerInterface $entityManager, Appointment $appointment): Response {
    //We bereiden het wissen voor in de database
    $entityManager->remove($appointment);

    //We voeren de statements uit (het wordt nog gedelete)
    $entityManager->flush();

    //Uiteraard zetten we een flash-message
    $this->addFlash('success', 'appointment is gewist');

    //We maken een redirect naar de route om het aangepaste boek te tonen
    return $this->redirectToRoute('app_appointment');
}

}

appointment/index.html.twig

{% extends 'base.html.twig' %}

{% block title %}Hello AppointmentController!{% endblock %}

{% block body %}
<style>
    .example-wrapper { margin: 1em auto; max-width: 800px; width: 95%; font: 18px/1.5 sans-serif; }
    .example-wrapper code { background:rgb(17, 99, 153); padding: 2px 6px; }
</style>




<table class="table example-wrapper">
  <thead>
    <tr>
      <th scope="col">Student</th>
      <th scope="col">Teacher</th>
      <th scope="col">Location / Time</th>
         <th scope="col">Edit</th>
          <th scope="col">Delete</th>
    </tr>
  </thead>   
  <tbody>
      {% for appointment in appointments %}
    <tr>

      <td>  {{ appointment.student.firstName }}</td>
      <td>      {{ appointment.teacher.firstName }}</td>
  <td>   {{ appointment.time|date("F jS \a\t g:ia") }}, {{ appointment.location}}</td>

 <td><a class="nav-link" href="{{path('app_appointment_edit',  {'id': appointment.id }) }}">  Edit <span class="sr-only"></span></a></td>
  <td><a class="nav-link" href="{{path('app_appointment_delete',  {'id': appointment.id} ) }}">Delete <span class="sr-only"></span></a></td>




      </td>
    </tr>
        {% endfor %}
         <td><a class="nav-link" href="{{ path('app_create') }}"> Create   <span class="sr-only"></span></a></td>
  </tbody>
</table>


{% endblock %}

appointment/create.html.twig

{% extends 'base.html.twig' %}

{% block title %}Hello AppointmentController!{% endblock %}

{% block body %}
<style>
    .example-wrapper { margin: 1em auto; max-width: 800px; width: 95%; font: 18px/1.5 sans-serif; }
    .example-wrapper code { background: #F5F5F5; padding: 2px 6px; }
</style>

{{ form(form) }}
{% endblock %}

appointment.php

<?php

namespace AppEntity;

use AppRepositoryAppointmentRepository;
use DoctrineORMMapping as ORM;

#[ORMEntity(repositoryClass: AppointmentRepository::class)]
class Appointment
{
    #[ORMId]
    #[ORMGeneratedValue]
    #[ORMColumn]
    private ?int $id = null;

    #[ORMManyToOne(inversedBy: 'studentAppointments')]
    private ?User $student = null;

    #[ORMManyToOne(inversedBy: 'teacherAppointments')]
    private ?User $teacher = null;

    #[ORMColumn(length: 255)]
    private ?string $location = null;

    #[ORMColumn]
    private ?DateTime $time = null;

    #[ORMColumn(length: 255)]
    private ?string $topic = null;

    public function getId(): ?int
    {
        return $this->id;
    }

    public function getStudent(): ?User
    {
        return $this->student;
    }

    public function setStudent(?User $student): static
    {
        $this->student = $student;

        return $this;
    }

    public function getTeacher(): ?User
    {
        return $this->teacher;
    }

    public function setTeacher(?User $teacher): static
    {
        $this->teacher = $teacher;

        return $this;
    }

    public function getLocation(): ?string
    {
        return $this->location;
    }

    public function setLocation(string $location): static
    {
        $this->location = $location;

        return $this;
    }

    public function getTime(): ?DateTime
    {
        return $this->time;
    }

    public function setTime(DateTime $time): static
    {
        $this->time = $time;

        return $this;
    }

    public function getTopic(): ?string
    {
        return $this->topic;
    }

    public function setTopic(string $topic): static
    {
        $this->topic = $topic;

        return $this;
    }
}

Card item not displaying cards right after getting data [closed]

When I get my data from MySQL, I need to show it as a horizontal line with two buttons, next and previous, like in a Netflix movie. But when I get the data, it shows the image above the image.
I need it to show in one line and an image next to the image, not like this image above.
whats problem here idont found any solution?

<?php
session_start();
?>

<!DOCTYPE html>
<html lang="en">

<body>

   <div class="container">

               <div class="featurd-content">
                
               </div>

<?php
            $servername = "localhost";
            $username = "root";
            $password = "";
            $dbname = "login_register";

            // Create connection
            $conn = new mysqli($servername, $username, $password, $dbname);
            // Check connection
            if ($conn->connect_error) {
              die("Connection failed: " . $conn->connect_error);
            }
            $sql = 'SELECT * FROM movies ';
            $result = $conn->query($sql);

            
            if ($result->num_rows > 0) {
              // output data of each row
              while ($row = $result->fetch_assoc()) {

                
                
           ?>
         
         <section>

         <h4> watch noww</h4>
         <i class="bi bi-chevron-left"></i>
         <i class="bi bi-chevron-right"></i>
         

         
         
         <div class="cards">
            <a href="#" class="card">
            <img src="../image/<?php echo $row['movie_image']; ?>" alt="" class="poster">
            </a>
        
         </div>


        
         
         </section>

         <?php }
            } ?>
           

              <!-- </div> -->

 


    


    </div>

</body>
</html>

let left_btn=document.getElementsByClassName('bi-chevron-left')[0];
let right_btn=document.getElementsByClassName('bi-chevron-right')[0];
let cards=document.getElementsByClassName('cards')[0];

left_btn.addEventListener('click',()=>{

    cards.scrollLeft -=140;
})

right_btn.addEventListener('click',()=>{

    cards.scrollLeft +=140;
})




const arrows=document.querySelectorAll(".arrow");
const movieLists=document.querySelectorAll(".movie-list");

arrows.forEach((arrow,i)=>{

    const itemNumber=movieLists[i].querySelectorAll("img").length;
    let clickCounter=0;

    arrow.addEventListener("click",()=>{
        const ratio=Math.floor(window.innerWidth / 300);
        clickCounter++;
        if(itemNumber - (4 + clickCounter) + (4 - ratio) >=0){

            movieLists[i].style.transform=`translateX(${
            movieLists[i].computedStyleMap().get("transform")[0].x.value - 300}px )`;
        } else{
            movieLists[i].style.transform="translateX(0)";
            clickCounter=0;

        }
        
       
    });

    console.log(Math.floor(window.innerWidth/270));
});

// for light and dark theme----- start

const ball=document.querySelector(".toggle-ball")
const items=document.querySelectorAll(".container,.movie-list-title,.navbar-container,.sidebar,.left-menu-icon,.toggle,.login-text");

ball.addEventListener("click",()=>{

    items.forEach(items=>{
        items.classList.toggle("active")
    })

    ball.classList.toggle("active")
})

// for light and dark theme----- end



const wrapper=document.querySelector('.wrapper');
const loginLink=document.querySelector('.login-link');
const registerLink=document.querySelector('.register-link');
const btnPopup=document.querySelector('.btnLogin-popup');
const iconCClose=document.querySelector('.icon-close');

registerLink.addEventListener('click',()=>{
    wrapper.classList.add('active');
});

loginLink.addEventListener('click',()=>{
    wrapper.classList.remove('active');
});

btnPopup.addEventListener('click',()=>{
    wrapper.classList.add('active-popup');
});

iconCClose.addEventListener('click',()=>{
    wrapper.classList.remove('active-popup');
});
*{
    margin: 0%;
    padding: 0%;
    box-sizing: border-box;
}

body{
    width: 100%;
    height: 100vh;
    font-family: 'roboto',sans-serif;
}

.navbar{
    position: fixed;
    width: 100%;
    height: 50px;
    background-color: black;
   
    
}

.navbar-container{
    display: flex;
    align-items: center;
    
    padding: 0 50px;
    height: 100%;
    color: white;
    font-family: 'san',sans-serif;
}

.logo-container{

    flex: 1;
    
}
.logo{
    font-family: 'san',sans-serif;
    font-size: 30px;
    color: #4dbf00;
}

.menu-container{

    flex: 6;
   
}


/*

*/


  




.menu-list{

    display: flex;
    list-style: none; /*delete point from list */
}

.menu-list-item{
    margin-right: 30px;
}

.profile-container{

    flex: 2;
    display: flex;
    align-items: center;
    justify-content: flex-end; /*push item to right corner*/
    
}

.profile-text-container{

    margin: 0 20px;
}

.btnLogin-popup{
    color: white;
    text-decoration: none;
    cursor: pointer;
}
.profile-picture{

    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.toggle{
    width: 40px;
    height: 20px;
    background-color: white;
    border-radius: 30px;
    display: flex;
    align-items: center;
    justify-content: space-around;
    position: relative;
}

.toggle-icon{
    color: #4dbf00;
}

.toggle-ball{

    width: 18px;
    height: 18px;
    background-color: black;
    position: absolute;
    right: 1px;
    border-radius: 50%;
    cursor: pointer;
    transition:  0.5s ease-in-out;
}
/* .sidebar{

    width: 50px;
    height: 100%;
    background-color: black;
    position: fixed;
    top: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 60px;
    
} */


/* .left-menu-icon{
    color: white;
    font-size: 20px;
    margin-bottom: 40px;
} */

.container{
    background-color: #151515;
    min-height: calc(100vh - 50px);
    color: white;
    
}

/* .content-container{
    margin-left: 50px;

} */

.featurd-content{

    height: 50vh;
    padding: 50px;
    background: linear-gradient(to bottom,rgba(0,0,0,0),#151515), url('img/1.jpg');
}




 section{


    position: absolute;
    width: 100%;
    height: auto;
    padding: 0px 50px;
    bottom: 20px;
    color: white;
}

section .cards{


   position: relative;
   width: 100%;
   height: 200px;
   border: 1px solid white;
   margin-top: 10px;
   display: flex;
   align-items: center;
   overflow-x: auto;
   scroll-behavior:smooth ;
   

}

section .bi-chevron-left , .bi-chevron-right{

    position: absolute;
    top: 50%;
    left: 3%;
    width: 25px;
    height: 25px;
    background: gray;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 12px;
    cursor: pointer;
    transition: .3s linear;
    z-index: 999999999;
    opacity: 0;
}


section .bi-chevron-right{

   left: unset;
   right: 3%;
}

section:hover .bi-chevron-left{

    opacity: 1;
 }

 section:hover .bi-chevron-right{

    opacity: 1;
 }

section .cards::-webkit-scrollbar{


    display: none;
 }


section .cards .card{


    position: relative;
    min-width: 130px;
    height: 180px;
    /* border: 1px solid white; */
    border-radius: 8px;
    margin-right: 10px;
    background: black;
    transition: .3s linear;
    
  

 }

 section .cards .card .poster{


  width: 100%;
  height: 100%;
  border-radius: 8px;
  position: relative;

 }

 






.movie-list-container{

    
    padding:0 20px;    
}

.movie-list-wrapper{

    position: relative;
    overflow: hidden;
    /* background-color: #f5deb3; */

}

.media-scroller{

    display: grid;
    grid-auto-flow: column;
    /* gap: var(--size-3); */
    /* grid-auto-columns: 21%; */
    /* overflow-x: auto; */
}
.movie-list{

    display: flex;
    align-items: center;
    height: 300px;

    transform: translateX(0);   /*for moving slide */

    transition: all 1s ease-in-out ;
    
}


.movie-list-item{

    margin-right: 30px;
    position: relative;
    
}

.movie-list-item:hover .movie-list-item-img{

transform: scale(1.2);
margin: 0 30px;
opacity: 0.5;


}

.movie-list-item:hover .movie-list-item-title,
.movie-list-item:hover .movie-list-item-desc,
.movie-list-item:hover .movie-list-item-button{
    opacity: 1;
}



.arrow{

    font-size: 120px;
    position: absolute;
    top: 90px;
    right: 0;
    color: lightgray;
    opacity: 0.5;
    cursor: pointer;
}

.container.active{

    background-color: white;
}

.movie-list-title.active{

    color: black;
}



.navbar-container.active{
    background-color: white;
    color: black;
}

.sidebar.active{

    background-color: white;
}

.left-menu-icon.active{

    color: black;
}

.login-text.active{
    color: black;
}

.toggle.active{
    background-color: black;
}
.toggle-ball.active{
    background-color: white;
    transform:translateX(-20px) ;
    
}


.wrapper{
   position: absolute;
   top: 20%;
   left: 40%;
    /* position: relative; */
    width: 400px;
    height: 440px;
    /* background: transparent; */
    color: white;
    border: 2px solid rgba(255,255,255,.5);
    border-radius: 20px;
    /* backdrop-filter: blur(20px); */
    background-color: white;
    box-shadow: 0 0 30px rgba(0,0,0,.5);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    transform: scale(0);
    transition: transform .5s ease, height .2s ease;
}

.wrapper.active-popup{

    transform: scale(1);
}

.wrapper.active{

    height: 520px;
    
}

.wrapper .form-box{

    width: 100%;
    padding: 40px;
}





.wrapper .form-box.login{

    transition: transform .18s ease;
    transform: translateX(0);
   

}

.wrapper.active .form-box.login{

    transition: none;
    transform: translateX(-400px);

}

.wrapper .form-box.register{

    position: absolute;
     transition: none;
    transform: translateX(400px);
}


.wrapper.active .form-box.register{

    transition: transform .18s ease;
    transform: translateX(0);

}

.wrapper .icon-close{

    position: absolute;
    top: 0;
    right: 0;
    width: 45px;
    height: 45px;
    background: #162938;
    font-size: 2em;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    border-bottom-left-radius: 20px;
    cursor: pointer;
    z-index:1;
}

.form-box h2{

    font-size:2em ;
    color: #162938;
    text-align: center;
}

.input-box{

    position: relative;
    width: 100%;
    height: 50px;
    border-bottom: 2px solid #162938;
    margin: 30px 0;
}

.input-box label{

    position: absolute;
    top: 50%;
    left: 5px;
    transform:translateY(-50%);
    font-size: 1em;
    color: #162938;
    font-weight: 500;
    pointer-events: none;
    transition:.5s;
}

.input-box input:focus~label,
.input-box input:valid~label {

    top: -5px;
}

.input-box input{

    width: 100%;
    height: 100%;
    background: transparent;
    border: none;
    outline: none;
    font-size: 1em;
    color: #162938;
    font-weight: 600;
    padding: 0 35px 0 5px;

}

.input-box .icon{

    position: absolute;
    right: 8px;
    font-size: 1.2em;
    color: #162938;
    line-height: 57px;
}

.remember-forgot{

    font-size: 0.9em;
    color: #162938;
    font-weight: 500;
    margin: -15px 0 15px;
    display: flex;
    justify-content: space-between;

}

.remember-forgot label input{

    accent-color: #162938;
    margin-right: 3px;
}

.remember-forgot a{

    color: #162938;
    text-decoration: none;

}

.remember-forgot a:hover {

    text-decoration: underline;
}

.btn{

    width: 100%;
    height: 45px;
    background: #162938;
    color: white;
    border: none;
    outline: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1em;
    font-weight: 500;
    
}

.login-register{

    font-size: 0.9em;
    color: #163819;
    text-align: center;
    font-weight: 500;
    margin: 25px 0 10px;
}

.login-register p a{

text-decoration: underline;
}







@media only screen and (max-width:940px) {

    .menu-container{
        display: none;
    }
}
<?php
session_start();
?>

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link
        href="https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;400;500;700;900&family=Sen:wght@400;700;800&display=swap"
        rel="stylesheet">
        <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/all.min.css">
        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/font/bootstrap-icons.min.css">
       
        
     
    
    <link rel="stylesheet" href="styleee.css">

   
    <title> onc</title>
</head>
<body>


<?php

include 'signUp.php';
include 'login.php';

?>

   <div class="navbar">
        <div class="navbar-container">
             <div class="logo-container"><h1 class="logo">ONC</h1></div>   
             <div class="menu-container">
                <ul class="menu-list">

                   
                    <li class="menu-list-item">Home</li>
                    <li class="menu-list-item">Movies</li>
                    <li class="menu-list-item">series</li>
                    <li class="menu-list-item">popular</li>
                    <li class="menu-list-item">trends</li>
                    
                    
                </ul>
             </div> 
             
           
             <div class="profile-container">
                <!-- <img class="profile-picture" src="img/profile.jpg" alt=""> -->
                 
                <div class="profile-text-container">

                  <a class="btnLogin-popup"> Login</a>
                  
                </div>

                <div class="toggle">

                    <i class="fa-solid fa-moon toggle-icon"></i>
                    <i class="fa-solid fa-sun toggle-icon"></i>
                     <div class="toggle-ball"></div>
                </div>
             </div>  
        </div>
   </div>

   


   
   


   <div class="container">

               <div class="featurd-content">
                
               </div>



 

         <!-- <div class="movie-list-container"> -->

              
        

         

<?php
            $servername = "localhost";
            $username = "root";
            $password = "";
            $dbname = "login_register";

            // Create connection
            $conn = new mysqli($servername, $username, $password, $dbname);
            // Check connection
            if ($conn->connect_error) {
              die("Connection failed: " . $conn->connect_error);
            }
            $sql = 'SELECT * FROM movies ';
            $result = $conn->query($sql);

            
            if ($result->num_rows > 0) {
              // output data of each row
              while ($row = $result->fetch_assoc()) {

                
                
           ?>
         
         <section>

         <h4> watch noww</h4>
         <i class="bi bi-chevron-left"></i>
         <i class="bi bi-chevron-right"></i>
         

         
         
         <div class="cards">
            <a href="#" class="card">
            <img src="../image/<?php echo $row['movie_image']; ?>" alt="" class="poster">
            </a>
        
         </div>


        
         
         </section>

         <?php }
            } ?>
           

              <!-- </div> -->

        


        
           



              

           



       


    <div class="wrapper">

        <span class="icon-close">
        <ion-icon name="close"></ion-icon>
        </span>
        <div class="form-box login">
            <h2> Login </h2>
            <form action="index.php" method="post">
                <div class="input-box">
                    <span class="icon">
                    <ion-icon name="mail"></ion-icon>
                    </span>
                    <input type="email" name="email" required>
                    <label>Email</label>
                </div>

                <div class="input-box">
                    <span class="icon">
                    <ion-icon name="lock-closed"></ion-icon>
                    </span>
                    <input type="password" name="password" required>
                    <label>Password</label>
                   
                </div>

                <div class="remember-forgot">
                    <label> <input type="checkbox">Remember me</label>
                    <a href="#">Forgot Password </a>
                </div>

                <button type="submit" value="Login" name="login" class="btn">Login</button>

                <div class="login-register">
                    <p>Dont have an account? <a href="#" class="register-link">Register</a></p>
                </div>

           </form>
        </div>


<!--  -->
        <div class="form-box register">
            <h2> Register </h2>
            <form action="index.php" method="post">

            <div class="input-box">
                    <span class="icon">
                    <ion-icon name="person"></ion-icon>
                    </span>
                    <input type="text" name="fullname" class="form-control" required>
                    <label>Username</label>
                </div>

                <div class="input-box">
                    <span class="icon">
                    <ion-icon name="mail"></ion-icon>
                    </span>
                    <input type="email" name="email" class="form-control" required>
                    <label>Email</label>
                </div>

                <div class="input-box">
                    <span class="icon">
                    <ion-icon name="lock-closed"></ion-icon>
                    </span>
                    <input type="password" name="password" class="form-control" required>
                    <label>Password</label>
                   
                </div>


                <div class="input-box">
                    <span class="icon">
                    <ion-icon name="lock-closed"></ion-icon>
                    </span>
                    <input type="password" name="repeat_password" required>
                    <label>Password</label>
                   
                </div>

                <div class="remember-forgot">
                    <label> <input type="checkbox">i agree to the terms & condition</label>
                    
                </div>

                <button type="submit" value="Register" name="submit" class="btn">Register</button>

                <div class="login-register">
                    <p>Already bhave an account? <a href="#" class="login-link">Login</a></p>
                </div>

           </form>
        </div>



    </div>


   <script src="appp.js"></script>
   <script type="module" src="https://unpkg.com/[email protected]/dist/ionicons/ionicons.esm.js"></script>
   <script nomodule src="https://unpkg.com/[email protected]/dist/ionicons/ionicons.js"></script>

</body>
</html>

enter image description here

how to fill in entity field with logged in user with a certain role

->add('instructor', EntityType::class, [
                'class' => User::class,
                'choice_label' => 'name',
                'multiple' => false,
                'query_builder' => function (EntityRepository $er) {
                    return $er->createQueryBuilder('u')
                        ->where('u.roles LIKE :role')
                        ->setParameter('role', '%ROLE_INSTRUCTOR%');
                },
            ])

right now i only got a dropdown from all instructors

How to fix issue with executing multiple queries in SQLite3 using PHP ADOdb?

I’m trying to execute multiple SQL queries in a single request using PHP with the ADOdb library, and I’m having trouble getting the second query to run. Here’s the code I’m using to connect to an SQLite3 database:

require_once 'ADOdb/adodb.inc.php';

// Create a connection to the SQLite3 database
$db = NewADOConnection('sqlite3');

// Database path
$databasePath = 'test.db';
$db->Connect($databasePath);

// Trying to run multiple queries
$query = "PRAGMA table_info('test'); SELECT 1;";
$result = $db->Execute($query);
echo $result;
?>

What I’m trying to do:
I want to execute two SQL queries in a single execution: PRAGMA table_info(‘test’) and SELECT 1;.

The first query works, but the second query (SELECT 1;) does not return any result.

Problem:
When I run the above code, the first query (PRAGMA table_info(‘test’)) works fine and returns the table structure, but the second query (SELECT 1) doesn’t execute, and I don’t get any output for it.

I am not sure how to handle multiple queries in a single execution using ADOdb for SQLite3.

What I’ve tried:
I attempted running both queries in a single string, but only the first query seems to be executed.

I tried using separate calls for each query, but I still couldn’t figure out a way to make it work correctly.
Environment Details:
PHP version: [Add your PHP version here, e.g., PHP 7.4]

ADOdb version: [Add the version you’re using, e.g., ADOdb 5.20]

Database: SQLite3
What I’ve tried:
I’ve attempted running both queries in a single string as shown above, but only the first query (PRAGMA table_info(‘test’)) seems to work, and the second query (SELECT 1) is ignored.

I also tried running the queries separately but still encountered the issue.

Desired Result:
I expect the following results:

The first query (PRAGMA table_info(‘test’)) should output the table structure of the test table.

The second query (SELECT 1) should output the number 1.

Environment Details:
PHP version: [Your PHP version, e.g., PHP 7.4]

ADOdb version: [Your ADOdb version, e.g., ADOdb 5.20]

Database: SQLite3

Email have stopped being sent in OJS(open journal system) website

I am working on https://journal.iba-suk.edu.pk:8089/SIBAJournals/index.php/sjet. I am having an issue which is that emails have stopped being sent or they are no longer being sent since April 29. Therefore, we are unable to receive emails regarding new manuscript submission. We also can not receive forgot password email. I am running windows apache xamph php server. following is the code of my config.inc.php file

;;;;;;;;;;;;;;;;;;
; Email Settings ;
;;;;;;;;;;;;;;;;;;

[email]    
; Use SMTP for sending mail instead of mail()
 smtp = On

; SMTP server settings
; smtp_server = mail.example.com
; smtp_port = 25
 smtp_server = smtp.gmail.com
 smtp_port = 465

;smtp_port = 587


; Enable SMTP authentication
; Supported smtp_auth: ssl, tls (see PHPMailer SMTPSecure)
; smtp_auth = ssl
; smtp_username = username
; smtp_password = password
 smtp_auth = ssl
; smtp_auth = PLAIN
 
 smtp_secure = tls
 log_email=On
 smtp_username = *********
 smtp_password = *********
;
; Supported smtp_authtype: RAM-MD5, LOGIN, PLAIN, XOAUTH2 (see PHPMailer AuthType)
; (Leave blank to try them in that order)
; smtp_authtype =

; The following are required for smtp_authtype = XOAUTH2 (e.g. GMail OAuth)
; (See https://github.com/PHPMailer/PHPMailer/wiki/Using-Gmail-with-XOAUTH2)
; smtp_oauth_provider = Google
; smtp_oauth_email =
; smtp_oauth_clientid =
; smtp_oauth_clientsecret =
; smtp_oauth_refreshtoken =

; Enable suppressing verification of SMTP certificate in PHPMailer
; Note: this is not recommended per PHPMailer documentation
; smtp_suppress_cert_check = On

; Allow envelope sender to be specified
; (may not be possible with some server configurations)
 allow_envelope_sender = On

; Default envelope sender to use if none is specified elsewhere
 default_envelope_sender = [email protected]

; Force the default envelope sender (if present)
; This is useful if setting up a site-wide no-reply address
; The reply-to field will be set with the reply-to or from address.
; force_default_envelope_sender = Off

; Force a DMARC compliant from header (RFC5322.From)
; If any of your users have email addresses in domains not under your control
; you may need to set this to be compliant with DMARC policies published by
; those 3rd party domains.
; Setting this will move the users address into the reply-to field and the
; from field wil be rewritten with the default_envelope_sender.
; To use this you must set force_default_enveloper_sender = On and
; default_envelope_sender must be set to a valid address in a domain you own.
; force_dmarc_compliant_from = Off

; The display name to use with a DMARC compliant from header
; By default the DMARC compliant from will have an empty name but this can
; be changed by adding a text here.
; You can use '%n' to insert the users name from the original from header
; and '%s' to insert the localized sitename.
; dmarc_compliant_from_displayname = '%n via %s'

; Amount of time required between attempts to send non-editorial emails
; in seconds. This can be used to help prevent email relaying via OJS.
time_between_emails = 3600

; Maximum number of recipients that can be included in a single email
; (either as To:, Cc:, or Bcc: addresses) for a non-privileged user
max_recipients = 100

; If enabled, email addresses must be validated before login is possible.
require_validation = Off

; Maximum number of days before an unvalidated account expires and is deleted
validation_timeout = 14



 

Laravel TwillCMS: CSS and JS do not load twill in sub-directory

I’m trying to install Twill on a Laravel project hosted in a subdirectory, for example:
https://example.org/sub/

However, the CSS and JS assets from Twill are not loading properly. The application is trying to load them from the root domain like:

https://example.org/assets/twill/abc.js

But they should actually load from:

https://example.org/sub/assets/twill/abc.js

It seems that Twill is not respecting the subdirectory path when generating asset URLs.

What I’ve tried:
Updated .htaccess to handle the subdirectory path.

Attempted to configure Laravel’s APP_URL and asset() helper accordingly.

Checked Twill’s config files for any base URL setting.

My setup:

  • Laravel is installed in a subdirectory (/sub)
  • Apache2 on Ubuntu
  • Twill installed via Composer
  • I have tried adding /public to ASSET_URL still doesn’t works as the URL accessed by twill is different.

No issues with the main Laravel routing, just with Twill’s assets.

How can I make Twill correctly generate asset paths when Laravel is installed in a subdirectory?