0
If condition
I am new to PHP I was asking is there away I can use if left count =1 and rightcount=1 hide this button if not show this button from my database I have row of leftcount and rightcount
12 Réponses
+ 3
It may help if you can share your code here to improve clarity. Follow this guide below if you didn't know how to share links 👍
https://www.sololearn.com/post/74857/?ref=app
+ 5
I suggest that you perform these actions with javascript / jquery because it is easier to handle events and the DOM with this technology.
+ 3
Your problem is not clear? What is left count and right count?
+ 2
I'm sorry, but TBH I still find it hard to understand what you actually mean Abdifatah
But good luck anyways! 👍
+ 1
Ipang I mean I have a registration page which has forms inside email password number and they is section which has left and right which is radio button
+ 1
Abdifatah
I'm listening, tell some more information, so it all becomes very clear 👍
Even if I can't help you, additional information may help others who view this thread to understand your situation, and then they might help you ...
0
My problem is I want to hide a side form which has left and right so if two people join one click left and the other click right I don't want that left and right again to be shown the future people who want to join using that registration page
0
Leftcount and rightcount is when auser registered using someone else link his email will be updated that user his row which has left and right which displays the email of new users only 2 people can join one left and the other right
0
So I need if left is taken and right is taken then hide that left and right in the registration form
0
Before user reach that section I want to be hidden
0
Who ever join that he has two choose left or right in order to be save his details in my database
0
Use cookies
If the user clicks it:
setcookie('left_clicked', 'true', time() + (86400 * 30), "/");
If any user enters the page:
if(!isset($_COOKIE['left_clicked'])){
echo '<input type="checkbox" id="left">';
}