Web Development
Member Avatar

I have Apache2, php 7.2, and mysql installed. At the top of my index.php I have the following script:

<?php
session_start();
// start of script every time.

//  setup a …
Topic by larry29936

Try

$stmt = $pdo->prepare("INSERT INTO 'download' ('IP_ADDRESS', 'FILENAME') VALUES (?, ?)");

Note the small change from ") to )")

Software Development
Member Avatar

A long standing complaint with the standard progress bar control is that there is no easy way to display text. In spite of numerous requests, Microsoft has not included this …

Web Development
Member Avatar

I have created a table in a mySQL DB where users are going to a form and entering ratings on 6 Categories (5 Specific and 1 Overall) for a particular …

Web Development
Member Avatar

I need to deoubfuscate a javascript file which i need to change a link inside it can anybody help me how to do that?
I can upload the file also …

Software Development
Member Avatar

As part of a project to manage my collection of photos, I wanted to add the capability of displaying a series of files as thumbnails. This posed me with three …

Community Center
Member Avatar

As if Jeff Bezos isn't already rich enough. As someone who is at high risk because of a compromised immune system, I thought it might be a good idea to …

Topic by Reverend Jim

According to the FCC Regulations:

  • The FCC prohibits broadcasting false information about a crime or a catastrophe if the broadcaster knows the information is false and will cause substantial …
Geeks' Lounge
Member Avatar

Once harm has been done, even a fool understands it.
-- Homer

Topic by vegaseat

The evil in the world comes almost always from ignorance, and goodwill can cause as much damage as ill-will if it is not enlightened. People are more often good than …

Geeks' Lounge
Member Avatar

Anyone see any fun april fools pranks on the web today? I think most companies (I know Google has) have decided not to do it this year.

Databases
Member Avatar

My code has a query that looks like:

INSERT INTO table
VALUES (...)
ON DUPLICATE KEY UPDATE
    id = LAST_INSERT_ID(id),
    …

id is a PRIMARY KEY.

My question is that …

Member Avatar
Information Security
Member Avatar

A survey of attendees at Infosecurity Europe earlier this month showed 70 percent in favour of the dictionary definition (in this case the Cambridge Dictionary) of a hacker being amended. …

Member Avatar
Software Development
Member Avatar

When working with TCP client sockets I often find myself frustrated with the lack of event-driven support. I usually end up writing a whole bunch of code to determine disconnects, …

Geeks' Lounge
Member Avatar

How many have websites here or own websites here?

Topic by Mr.M

Yes it people like you whom I want indeed. To begin, when users login I'm pretty sure that passwords are not saved as is on the database. Correct? So
1) …

Software Development
Member Avatar

Hi good people of Danniweb,

I've looked at a lot of examples on line and I cannot figure out what is going wrong.

My program has to transfer a simple …

Meta DaniWeb
Member Avatar

Is anyone still encountering the problem of posts not going through?

bug
Information Security
Member Avatar

In the modern world, it’s easy to understand that data is absolutely essential to many corporations and organizations. There is an ever-growing need to understand the needs and desires of …

Topic by Neil_12

Also cheack for BRIWPED and see more

Geeks' Lounge
Member Avatar

How many have websites here or own websites here?

Web Development
Member Avatar

I have a download section in my index.php that I'd like to add a download counter to but have no idea how to accomplish this. The existing code works perfectly …

Topic by larry29936

Your code <a href="<?php echo "/{$file}";?>"> is a link to the actual .iso file you want them to download.

Instead, you want to create a new page such as download.php?file=123 …

Software Development
Member Avatar

When working with TCP client sockets I often find myself frustrated with the lack of event-driven support. I usually end up writing a whole bunch of code to determine disconnects, …

Geeks' Lounge
Member Avatar

Any dog parents out there? My sheltie just turned 6 months. She's suuuuuch a smart breed that I literally need to keep her mind occupied every moment throughout the day …

Computer Science
Member Avatar

What Are Voronoi Diagrams?

Voronoi Diagrams are an essential visualization to have in your toolbox. The diagram’s structure is a data-driven tessellation of a plane and may be …

Software Development
Member Avatar

Write a function that takes as argument a string containing multiple words and returns a string containing the same words in reverse order.
Eg., input = 'India is a democracy'; …

Topic by Aman_24

It's a very simple in single row:

string='India is a democracy'
print (' '.join([word for word in reversed(string.split(' '))]))
Programming
Member Avatar

how would one convert this to python?

Topic by Joseph_49

What does it do? And what would be the advantage of converting it to Python?

Web Development
Member Avatar

What is the difference between setting a cookie domain to www.site.com vs .www.site.com when I want to limit a cookie to the www subdomain?

Web Development
Member Avatar

My contact form starts with:

<form id="form1" method="POST" action="mail.php">

I'd like to replace the last line in my contact form:

<button type="submit" value="Send" style="margin-top:15px; margin-left: 500px; text-align: center;">Send Email</button>

with …

Topic by larry29936

Try <input type="image" src="images/button_send-email.png" alt="Email">

You can see according to W3 that type="image" creates a graphical submit button.

Software Development
Member Avatar

There are times when you need to make sure your counter starts at an odd or even number.

Even is pretty simple - counter = counter + modulus(counter). If counter …

Software Development
Member Avatar

Just trying to find out which of these five isprime functions is the fastest.

Geeks' Lounge
Member Avatar

I'm hoping that people will post unusual or little known facts here. It would be proper to include a link to a source for confirmation. Here's a start.

Speedy Gonzales …

Search Engine Strategies
Member Avatar

Just got a popup notification in my Google Search Console that says:

Your site has been switched to Mobile First Indexing
The majority of Google's crawl requests to …