Confirmation URL for HTML Form

Hello!
I am new to backendless and have some questions!

First, I saw in Messaging tab a confirmation email for new registred users.

I want to build something like that, and i hope it is working.

So my basic project:
If a user is entering his email in a form (data gets posted with php curl), then he receive a email with a url like the confirmation_url, but this email is leading to a html or php website.

There should be something like:
(with the get parameter)
Hello @username!

And if he entered data to this form it will be uploaded with REST-Api.

So my main question: How is it possible to send a custom url if somebody entered his email.
The url should be safe, like the confirmation_url.

Thanks for help!!!

Hello, @Fynn_Pfingsten.

Do you want to use the Codeless SDK for your app?

Regards, Nikita.

Hello,

if it is possible, then yes, why not!

Regards Fynn

@Fynn_Pfingsten,yes, you can create such a page using codeless.
Then I think you should check out our documentation. And watch a course of video tutorials on Codeless.

https://backendless.com/docs/codeless/index.html

Best Regards, Nikita.

Hi Fynn,

Is the confirmation URL in the email you need to send static or it should be composed individually for every user? What I didn’t quite understand is what’s behind that URL? What should it open? Our confirmation URLs open the confirmation page AND they also change the status of the user as confirmed. Please describe the functionality that should be behind the confirmation URL in your app.

Regards,
Mark

Hi!
Sorry for the bad description.
Youre right the confirmation URL is individually for every user.

Beyond the URL should be lets say a html or php file which and there is a form beyond.

For example:
A user puts his email in a form (like registration), then he gets an email with a url like the confirmation url. But the url is leading to the form. So lets say this is my page:

Hello @email (email is the email adress who gets the email)

Adress: This is an input field!!!
Phone: This is an input field!!!

Submit (Button)

When a user is submitting, then he post data to an data-table in the API.

I think the first way is the custom_url, the page is opening (get name) and if submit the form it post data to data-table in REST-Api.

I hope my problem is now clear, please give me a short reply
Thanks!!!

Let’s see if I understood correctly:

  1. User registers (for this you’d use Backendless registration API)
  2. Once registered on the backend, the user gets an email that greets the user and contains a URL
  3. When the user clicks the URL, a page opens up that contains a form.

Is that correct?

Regards,
Mark

Yes, but at step 3 i want to add that this is an specific form for the user (like confirmation url).
The Form should echo something like hello @username.
This is important, because if the user submits the form, the entry should be saved with the email-adress that gets the confirmation_url

Got it. Will the form be created in Backendless UI Builder and then the data is saved in the Backendless database?

Yes, I think i will do that, but i dont how to solve the further steps (confirmation_url, etc.)

Do you have an Idea?
Best regards!!

I’d start with creating a page with the form. To customize the page for a specific user, the page should be accepting a parameter, it can be anything that identifies the user, for instance, their email address or objectId. In UI Builder, these parameters are accessible through the Page Data block. For example, the logic below gets the value for the email parameter passed into the page:

Then in the URL for the page, you’d pass the email parameter like this:

<this part is skipped for brevity>/index.html?page=landing&email=foo@bar.com

Hope this helps.

Regards,
Mark

Thank you! I will try and test it and contact you again tomorrow.

Did you figure out how to get the set block? When you declare a variable, these blocks are created for you:

Yes, now is everything clear. Now i know the basics of you codeless.
But sorry for that, i have to ask you another question:

Unter the E-Mail tab, there is a title called: Substitution variables
Is it possible to add my own function/variable there?

I recommend that you create a custom template (see the documentation). With custom templates, you can define your own “substitution variables”, we call them dynamic text.

Hello, more and more my code is working!
I read the documentation about dynamic text but i dont know how to use it.
Can you show me an example for the above case (url_generation)?

Could you please describe what you already have in place? Add some screenshots - they are helpful in understanding what you got.

Regards,
Mark

Of course!

So this is acutally very basicly, but when i register a user, then he gets the email from template.
Now i want to add my “dynamic text” so if a user registred he gets the url which you described above.
But i dont want to use the object-id instead of the email adress, because else it is very easy to hack.
Or do you have an alternative like an token (similar to confirmation_url) which is safe and contains the needing information?!

Thanks. What is the name of your dynamic text variable in the template?