usa – Why does the online I94 form require VWP applicants to buy ESTA?

I am an EU citizen and I live in Canada. I will make a road trip to the United States next week. According to the CBP website, I do not need to renew my ESTA to do so.

Hoping to speed up the paperwork at the border a bit, I tried to complete and pay the I94 form in advance. However, the new online form does not let me do it, because I no longer have a valid ESTA.

Since ESTA is a capture of transparent money instead of a security measure (from the $ 14 fee, $ 10 will finance tourism ads and $ 4 will finance CBP), it seems that CBP is actively trying to deceive visitors to pay for something they don't pay & # 39; & # 39 ;. I don't need, am I missing something?

html: standard or common way to protect a destination email address from a contact form

I have a website with a minimum HTML-CSS-JavaScript contact form, but I want to hide the destination email address of that form from the HTML source code so that the users of the form cannot find it in the HTML source codes of their browsers Web .
I considered putting the destination email address in a configuration file and referring this configuration file in some way, but the reference itself could appear in the source code and expose the file that contains the email so that people can Examine that file and find the email.

What is the standard or common way to secure a destination email address of a contact form? – Show devexpress report in c # web form without using reportviewer

I have a report created in devexpress with which I want to show it without having to use the reportviewer.

public ReportPrintTool configura_print_tool(XtraReport report)
            ReportPrintTool p_tool = new ReportPrintTool(report);
            PrintingSystemBase ps = p_tool.PrintingSystem;
            PrintingSystemCommand() psc_disabled = new PrintingSystemCommand() { PrintingSystemCommand.ExportCsv, PrintingSystemCommand.ExportTxt,PrintingSystemCommand.ExportHtm,

            ps.SetCommandVisibility(psc_disabled, CommandVisibility.None);

            DevExpress.XtraPrinting.ExportOptions options = ps.ExportOptions;

            // Set Print Preview options.
            options.PrintPreview.ActionAfterExport = ActionAfterExport.AskUser;
            options.PrintPreview.DefaultFileName = "";
            options.PrintPreview.SaveMode = SaveMode.UsingSaveFileDialog;
            options.PrintPreview.ShowOptionsBeforeExport = false;

            // Set Image-specific export options.
            options.Image.Format = System.Drawing.Imaging.ImageFormat.Jpeg;

            // Set PDF-specific export options.
            options.Pdf.Compressed = true;
            options.Pdf.ImageQuality = PdfJpegImageQuality.Medium;
            options.Pdf.NeverEmbeddedFonts = "Tahoma;Courier New";
            options.Pdf.DocumentOptions.Application = "";
            options.Pdf.DocumentOptions.Author = "";

            // Set XLS-specific export options.
            options.Xls.ShowGridLines = true;
            options.Xls.SheetName = "Page 1";
            options.Xls.TextExportMode = TextExportMode.Value;

            // Set XLSX-specific export options.
            options.Xlsx.ShowGridLines = true;
            options.Xlsx.SheetName = "Page 1";
            options.Xlsx.TextExportMode = TextExportMode.Value;

            return p_tool;

Here when printing with the button:

  protected void ASPxButtonAceptar_Click(object sender, EventArgs e)
            string tipo_empresa = ASPxComboBoxTipoEmpresa.SelectedItem.Text;
            string empresa = ASPxComboBoxEmpresa.SelectedItem.Text;
            Vizualizar_Reporte vr = new Vizualizar_Reporte();
            Accidentabilidad plantilla = new Accidentabilidad(tipo_empresa, empresa);
            ReportPrintTool printTool = vr.configura_print_tool(plantilla);


Already when it reaches the printTool.ShowRibbonPreview line (UserLookAndFeel.Default);
It shows me this exception: Object reference not set to an instance of an object.

7 – Change the html and order of the system fields (pass / email / locale / etc) of the user edit form

I have changed a series of user-accessible forms to fit a specific style. To do this, I used a #after_build function that adds prefixes and suffixes to the fields, as well as some javascript. This was simple enough (and I hope it's the right way to do it, although I'm not sure).

However, when the user edit form appears, it does not behave like other forms. Default system fields, such as password, regional settings, email, etc., cannot be reordered and it seems that I cannot add prefixes or suffixes to insert my HTML.

I have read some things about using a template for forms through the hook_theme () function, however, I couldn't make Drupal use my template file for the user profile editing form, although it works well for other forms . This was a last resort, however, and I prefer other means if possible.

How do I correctly modify the design and html of the user profile editing form? Thanks for your time.

javascript – Error registering in a php, mysql, ajax form

I am trying to make a registration form with php, mysql and ajax.

The error is that the user does not register me in the database, I give all the parameters with the corresponding variables however it does not register anything in the database

I am using PDO, it happens that sending the submit via the button skips error and I do not understand why, thanks in advance = D

I also use google recaptcha, I have deleted the secret key for security reasons.
I would appreciate any suggestions to improve the security of the form!

PHP code:


require '../../config.php'; // datos de la base de datos, database data

function isNull($data){
    if (strlen(trim($data)) < 1) {
        return true;
    } else {
        return false;

function verifyPassword($pass1, $pass2) {
    if (strcmp($pass1, $pass2) !== 0) {
        return false;
    } else {
        return true;

function isEmail($email) {
    if (filter_var($email, FILTER_VALIDATE_EMAIL)) {
        return true;
    } else {
        return false;

function registerUser($username, $email, $password, $btc_wallet, $user_type){
    global $con;
    $stmt = $con->prepare("INSERT INTO usuarios (username, email, password, btc_wallet, user_type) VALUES(:username, :email, :password, :btc_wallet, :user_type)");
    $stmt->bindParam(':username', $username, PDO::PARAM_STR);
    $stmt->bindParam(':email', $email, PDO::PARAM_STR);
    $stmt->bindParam(':password', $password, PDO::PARAM_STR);
    $stmt->bindParam(':btc_wallet', $btc_wallet, PDO::PARAM_STR);
    $stmt->bindParam(':user_type', $user_type, PDO::PARAM_STR);

    if ($stmt->execute()) {
        return $con->insert_id;
    } else {
        return 0;

if (!empty($_POST)) {
    $giveBack = ();
    $user_type = 2;
    $secretKey = "google_secret_key";
    introducir el código aquí
    $username = $_POST('username');
    $btc_wallet = $_POST('wallet');
    $email = strtolower($_POST('email'));
    $clave = $_POST('password');
    $con_password = $_POST('con_password');
    $captcha = $_POST('grecaptcha');

    $search_user = $con->prepare("SELECT * FROM usuarios WHERE username='$username' LIMIT 1");
    $search_user->bindParam(':username', $username, PDO::PARAM_STR);

    //if (!captcha) $giveBack() = "Por favor, verifica el captcha";
    if (isNull($username) || isNull($btc_wallet) || isNull($email) || isNull($clave) || isNull($con_password)) $giveBack() = "Por favor, completa todos los campos.";
    if (!isEmail($email)) $giveBack() = "Email invalido";
    if (!verifyPassword($clave, $con_password)) $giveBack() = "Las contraseñas no coinciden";
    if ($search_user->rowCount() == 1) {
        # Usuario ya existe, proceder a enviar un mensaje
        $giveBack('usernameError') = "Este usuario ya existe";
        $giveBack('isLogin') = false;

    if (count($giveBack) == 0) {
        $response = file_get_contents("$secret&response=$captcha");
        $arr = json_decode($response, TRUE);

        if ($arr('success')) {
            # Creamos el hash para el password
            $password = password_hash($clave, PASSWORD_DEFAULT);

            $register = registerUser($username, $email, $password, $btc_wallet, $user_type);

            if ($register > 0) {
                # Recuperando el id
                $user_id = $con->lastInsertId();
                $_SESSION('user_id') = (int) $user_id;
                $giveBack('redirect') = '';
                $giveBack('isLogin') = true;
            } else {
                $giveBack() = 'Error al registrar';
        } else {
            $giveBack('errorToCheckCaptcha') = 'Error al comprobar el captcha';
} else {
    exit("Fuera de aquí");


Javascript code:

const url = 'http://localhost/faucet_st/api/user/signup/process-signup.php';

var username = document.getElementById("username").value;
var wallet = document.getElementById("btc_wallet").value;
var email = document.getElementById("email").value;
var password = document.getElementById("password").value;
var con_password = document.getElementById("con_password").value;

var data = {
    username: username,
    wallet: wallet,
    email: wallet,
    password: wallet,
    con_password: con_password,
    grecaptcha: grecaptcha.getResponse()

    type: 'POST',
    url: url,
    data: data,
    dataType: 'json',
.done((res) => {
.fail((e) => {
.always(() => {});


I would be grateful if you could help me with this problem, I have tried to solve it all day, but I did not find a solution, I will continue looking for the solution, but I appreciate any help from you.

html: I'm trying to make a file upload form for my website, I have a code but it doesn't work

I can't make this work. Am I doing something wrong?

  $extensions= array("jpeg","jpg","png");

  if(in_array($file_ext,$extensions)=== false){
     $errors()="extension not allowed, please choose a JPEG or PNG file.";

  if($file_size > 2097152) {
     $errors()='File size must be excately 2 MB';

  if(empty($errors)==true) {
     echo "Success";


  • Sent file:
  • File size:
  • File type:

the required variable "url" was not used in the form.

I imported a list, selected the exact platforms. But every time I execute the project, it stops sending after 2 URLs and gives this error "08:21:26: [-] 1/1 of the required variable" url "was not used in the form".
I have added multiple emails, multiple posts and multiple accounts per site.

SSL certificate – httpd and curl: Configure the https prom connection for a p12 file form client validation

I am displaying an httpd. I need to configure ssl to validate the client according to its client certificate.

To do that I have a p12 file containing private key, client certificate and ca chain certificates:

CA chain certificates:

➜ ~ openssl pkcs12 -in fitxers.p12 -cacerts -nokeys
Bag Attributes
Bag Attributes

Customer certificate:

➜ ~ openssl pkcs12 -in fitxers.p12 -clcerts -nokeys
Bag Attributes

Client's private key:

➜ ~ openssl pkcs12 -in fitxers.p12 -nocerts
Bag Attributes

To divide this p12 separate cert file and key files:

➜ ~ openssl pkcs12 -in container.p12 -nocerts -out client.key.pem
➜ ~ openssl pkcs12 -in fitxers.p12 -clcerts -nokeys -out client.crt
➜ ~ openssl pkcs12 -in fitxers.p12 -cacerts -nokeys -out cacerts.crt

So, from now on, I configured my httpd as:

SSLEngine On
SSLCACertificateFile /usr/local/apache2/conf/cacerts.crt

I am trying to make the connection using curl:

curl --cert client.crt --key client.key.pem https://localhost:8080/token -v
*   Trying
* Connected to localhost ( port 8080 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
Enter PEM pass phrase:
* successfully set certificate verify locations:
*   CAfile: /etc/ssl/certs/ca-certificates.crt
  CApath: /etc/ssl/certs
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.3 (IN), TLS Unknown, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, Unknown (8):
* TLSv1.3 (IN), TLS Unknown, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, Certificate (11):
* TLSv1.3 (OUT), TLS alert, Server hello (2):
* SSL certificate problem: unable to get local issuer certificate
* Closing connection 0
curl: (60) SSL certificate problem: unable to get local issuer certificate
More details here:

In the httpd server logs I get:

(Tue Sep 17 11:17:28.144219 2019) (ssl:info) (pid 8:tid 139871525332736) (client AH01964: Connection to child 68 established (server
(Tue Sep 17 11:17:28.148318 2019) (ssl:debug) (pid 8:tid 139871525332736) ssl_engine_kernel.c(2375): (client AH02645: Server name not provided via TLS extension (using default/first virtual host)
(Tue Sep 17 11:17:28.155178 2019) (ssl:info) (pid 8:tid 139871525332736) (client AH02008: SSL library error 1 in handshake (server
(Tue Sep 17 11:17:28.155569 2019) (ssl:info) (pid 8:tid 139871525332736) SSL Library Error: error:14094416:SSL routines:ssl3_read_bytes:sslv3 alert certificate unknown (SSL alert number 46)
(Tue Sep 17 11:17:28.155609 2019) (ssl:info) (pid 8:tid 139871525332736) (client AH01998: Connection closed to child 68 with abortive shutdown (server
(Tue Sep 17 11:19:01.114529 2019) (ssl:info) (pid 8:tid 139871448463104) (client AH01964: Connection to child 69 established (server
(Tue Sep 17 11:19:01.114667 2019) (ssl:debug) (pid 8:tid 139871448463104) ssl_engine_kernel.c(2354): (client AH02044: No matching SSL virtual host for servername localhost found (using default/first virtual host)
(Tue Sep 17 11:19:01.114674 2019) (ssl:debug) (pid 8:tid 139871448463104) ssl_engine_kernel.c(2354): (client AH02044: No matching SSL virtual host for servername localhost found (using default/first virtual host)
(Tue Sep 17 11:19:01.114679 2019) (core:debug) (pid 8:tid 139871448463104) protocol.c(2314): (client AH03155: select protocol from , choices=h2,http/1.1 for server
(Tue Sep 17 11:19:01.117705 2019) (ssl:info) (pid 8:tid 139871448463104) (client AH02008: SSL library error 1 in handshake (server
(Tue Sep 17 11:19:01.117827 2019) (ssl:info) (pid 8:tid 139871448463104) SSL Library Error: error:14094418:SSL routines:ssl3_read_bytes:tlsv1 alert unknown ca (SSL alert number 48)
(Tue Sep 17 11:19:01.117858 2019) (ssl:info) (pid 8:tid 139871448463104) (client AH01998: Connection closed to child 69 with abortive shutdown (server

I have also tried to use cacerts.pem with curl --cacert ./cacerts.pem --cert client.crt --key client.key.pem https://localhost:8080/token -v

Any ideas?

Is there any way to use an html / php form to dynamically set the parameters of an e-commerce product?

I am currently making a website for a courier company that has a very complicated way to process orders. I was previously using eForms, but I couldn't do what I needed.

At the end point there is a & # 39; product & # 39; Woocommerce that accepts all the information on the form and uses it to establish the price and parameters of an order. That fake product is added to a user's cart and they proceed to payment.

I have created the form using html and css, but currently I cannot understand how to send the data to the WooCommerce product. It was a feature of eForms, but I don't know how to do it from scratch.

github – AttributeError: the object & # 39; str & # 39; It has no attribute & # 39; form & # 39;

I am trying to run this script on my image for image classification using the CNN model:

import cv2
import tensorflow as tf

CATEGORIES = ("Banana", "Bare soil", "Okra", "Sugarcane")

def prepare(file):
    IMG_SIZE = 50
    img_array = cv2.imread(file, cv2.IMREAD_GRAYSCALE)
    new_array = cv2.resize(img_array, (IMG_SIZE, IMG_SIZE))
    return new_array.reshape(-1, IMG_SIZE, IMG_SIZE, 1)

model = tf.keras.models.load_model("CNN.model")

image = r"C:/Users/admin/Desktop/Final Train Dataset/Dataset/Test/one.jpg" #your image path

prediction = model.predict((image))
prediction = list(prediction(0))

But, getting the following error:

AttributeError: 'str' object has no attribute 'shape'