HTML5 Data Bindings Support Product Page

Answered

Conditional jump triggered from a database value

11 years ago Chris Green posted:
I am trying to do the following and getting very muddled. Sorry to ask such simple questions.


  <?PHP If ($_POST["mailname"] ==?> "   <div data-binding-id="repeat3" data-binding-repeat="mailanme.data" data-binding-html="{{mailname}}"></div><?PHP ") 
			 { echo "Unfortunately it is taken, please 
				 <a href='/choosing_email/enteryourname.php'>Click Here</a> to choose another. Consider adding a number at the end if you wish to keep this name [br]";}
			else 
			{echo "We can confirm that your email address will be "."<span class='REDHeading'><font size='+1'>".$_POST["mailname"].$_POST["basename"]." " ;}?>

Replies

Replied 11 years ago
11 years ago Chris Green replied:
That smiley should be " )
Replied 11 years ago
11 years ago Teodor Kuduschiev replied:
Hello,
Please explain what exactly are you checking and what you try to achieve? It's not that simple to mix these codes as php code is being executed on the server, while the data bindings code is being executed clientside..
Replied 11 years ago
11 years ago Chris Green replied:
I have a page into which you enter a name which is then sent to a second page as $_POST["mailname"]. Here it is checked against the data base table to see if it exists. If it does, then the user is directed back to the previous page to choose again. If it does not exist then the user is directed to the next page where mailname is further processed and eventuslly sdded to the original table with other customer details after a payment is received via paypal
Replied 11 years ago
11 years ago Teodor Kuduschiev replied:
Replied 11 years ago
11 years ago Chris Green replied:
Hello Teodor
I am following this tutorial and discover it requires Bootstrap. I downloaded this and discovered that my Dreamweaver 11 is not supported. Is there any way of overcoming this so that I can complete the process
Replied 11 years ago
11 years ago Teodor Kuduschiev replied:
Hello Chris,
It does not require Bootstrap... We only are using it in the tutorial as it saves time. You can achieve the same using your own error messages.
Replied 11 years ago
11 years ago Chris Green replied:
Thank you
Replied 10 years ago
10 years ago Chris Green replied:
Hello Teodor

I still, even using the tutorial, cannot make this work. I cannot see why. It is getting very frustrating. I keep trying. I bind the submit button to data hide and after that there should according to the tutorial, be a little blue box in which to add an alert but this does not appear. Have a loo at foilfencing.com, select epeefencing.com and on the next page is the problem.
Replied 10 years ago
10 years ago Chris Green replied:
Now I have the button disappearing but the warning is always visible.
Replied 10 years ago
10 years ago Chris Green replied:
I have made the warning invisible unless needed but maybe I need another field under this in order for it to work.

Please advice

Regards
Chris
Replied 10 years ago
10 years ago Teodor Kuduschiev replied:
Hello Chris,
It is a little unclear what exactly did you do on your page - the page and the code look quite strange...
Please just follow the tutorial i sent you.
Replied 10 years ago
10 years ago Chris Green replied:
OK. Can I do this with only one field in the form.
Replied 10 years ago
10 years ago Teodor Kuduschiev replied:
Yes you can do this with one field.. you do not need more fields.
Replied 10 years ago
10 years ago Chris Green replied:
I have gone through the tutorial in fine detail and as far as I can see have not made mistakes.
It worked the first time but I cannot seem to get it to check the second name I enter.
chris and fred are in the database

foilfencing.com/db_test_teodor.php shows you the other names that are in the database.

Once agaian I appologise for needing so much help with what I presume are simple matters to others
Replied 10 years ago
10 years ago Chris Green replied:
It is appearing to work but for a circling and circling pair of arrows.

Sorry fred is not taken.

It is working so I will get on and get back to you when I have my next problem.

Next is to add captcha to the current page before it goes to the next page.
Replied 10 years ago
10 years ago Chris Green replied:
The little circling pair of arrows does not stop.

clicking the continue button does not take me to the next page

Please - can you tell me why?
Replied 10 years ago
10 years ago Chris Green replied:
The little circling pair of arrows does not stop.

clicking the continue button does not take me to the next page

Please - can you tell me why?
Replied 10 years ago
10 years ago Chris Green replied:
The little circling pair of arrows does not stop.

clicking the continue button does not take me to the next page

Please - can you tell me why?

Reply to this topic