The Student Room Group

iDEA Silver Badge award..

I cant seem to get the answer for the iDEA the Digital Citizen Part Two Screen Shot 2019-03-13 at 20.41.30.png

Scroll to see replies

here for the same answer
Reply 2
$myFormData = escape_tags($myFormdata);insertIntoDatabase($myFormData) $
the answer is: $myFormData = escape_tags(myFormData);
$review = $_POST['review'];insertIntoDatabase($review);anyone know the answer for this code to pass review through escape tag
Original post by liv230496
$review = $_POST['review'];insertIntoDatabase($review);anyone know the answer for this code to pass review through escape tag

I don't know either, are you still stuck on this one or could you possibly help me???
Reply 6
Has anyone got the answer to this????
Reply 7
$myFormData = escape_tags($myFormData);

I put this and it worked so try it out
Original post by 18DG57
$myFormData = escape_tags($myFormData);

I put this and it worked so try it out

i will never forget you
image.jpg iDEA citizen silver badge, third star. Keeps saying I need to sanitise my variable but I don’t know what it means and I’m not sure what I’m doing wrong. Can anyone help me with this?
Original post by hesham64_c
the answer is: $myFormData = escape_tags(myFormData);


Original post by 18DG57
$myFormData = escape_tags($myFormData);

I put this and it worked so try it out


I tried it it doesnt work , what line and where should i put it
Original post by Rueben229
I don't know either, are you still stuck on this one or could you possibly help me???


Did you get the answer what was itt
The answer to sanitise the variable before it gets inserted into the database should be:

$myFormData = escape_tags($myFormData);
insertIntoDatabase($myFormData)

You only need to replace the first line with the escape_tags variable and replace $message to $myFormData.
Hope this helps!
(edited 3 years ago)
yeh i need help on that one toohave you got an answer??
The answer is:

$myFormData = escape_tags($myFormData);
insertIntoDatabase($myFormData)

P.S. I have already posted the answer three weeks ago on this forum and it's on #13 on this page.
(edited 3 years ago)
Original post by DOPEYSTRAW1125
i will never forget you


Original post by 18DG57
$myFormData = escape_tags($myFormData);

I put this and it worked so try it out

WRONG
Original post by tinyminy13
The answer to sanitise the variable before it gets inserted into the database
should be:

$myFormData = escape_tags($myFormData);
insertIntoDatabase($myFormData)

You only need to replace the first line with the escape_tags variable and replace $message to $myFormData.
Hope this helps!


ty so much
does anyone have the code for the business website hack? original code here=$review = $_POST[$'review'];insertIntoDatabase($review);
Original post by tinyminy13
The answer to it should be:

$review = escape_tags($review);
insertIntoDatabase($review)

You only need to replace the first line with the escape_tags variable.
Hope this helps!

it did not work
Reply 19
Original post by Leahliz_x
image.jpg iDEA citizen silver badge, third star. Keeps saying I need to sanitise my variable but I don’t know what it means and I’m not sure what I’m doing wrong. Can anyone help me with this?

For anyone who is stuck on this one.
This is the original code:
$message = $_POST['message'];
insertIntoDatabase($message);

You need to change it to:
$message = escape_tags($message);
insertIntoDatabase($message);

I realised I did everything but the square brackets have been the thing that has caused me to be stuck on this one for a while. So you need to change it to these brackets (). Its worked for me, let me know if it has worked for anyone of you guys!


Drop here!
(edited 3 years ago)

Quick Reply

Latest

Trending

Trending