Skip to content

Hide file in directory

I want to hide files from sub directory From this mydomain.com/file/file.php To this mydomain.com/file/ Do you guys know how to do that? Answer In your home directory/.htaccess, add this line: This will do this work: mydomain.com/file/ => mydomain.com/file/file.php mydomain.com/foo/ => mydomain.com/foo/…

SELECT MAX query issue interval

I want to get the highest value in the last 1 day, but the query is not working. (date / time columns formatted by date). The data I want to query is in multiple headers. SELECT sign, date, price, MAX(…

converted to when using PHP DOMDocument

I’ve the following HTML code with a custom tag . It’s from “Custom Google Search Engine” to embed in a page. However, after parsing via PHP DOMDocument, …

wkhtmltopdf without creating a file in php

I have the wkhtmltopdf module in my Drupal which generates the pdf file by running the ‘wkhtmltopdf –options URL filename.pdf’ command using shell_exec function. The output of the file is fine, but I don’t want to store the pdf in the file system. I just want to show the output on the …

Sending mail with no required attachment Laravel 8

I’m working on a project in Laravel 8. I make a contact form that will be sent to my email address and contains name, email, message and attachment. Name, email and message are required but no attachment. When I send the form completely filled in (name, email, message and attachment) everything works fi…

Prevent truncating of preceeding zeros in Javascript

I am trying to pass variable to a JavaScript function that then makes an Ajax request using the variable. My problem is that if the value of the variable starts with zeros, the zeros are truncated. For example, if the value is 00056, what is sent for an Ajax call is 56 Here is what I am doing How do