Quick mod button doesn't show as well as the other 2

  • Sly036
  • Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 9
  • Thank you received: 0

Sly036 replied the topic: Quick mod button doesn't show as well as the other 2

hi !

i did look at that link you refer too, and here is what i done "aint a crack in all of this but i'm trying and learning".

ff_getSubmit('algo')
$this -> execPieceByName('ff_InitLib');
function ff_algo_init(element, condition)
{
switch (condition) {
case 'formentry':
break;
default:;
} // switch
} // ff_algo_init

//
Le code le plus ancien en dessous
function GeraHash($qtd){
//Under the string $Caracteres you write all the characters you want to be used to randomly generate the code.
$Caracteres = 'ABCDEFGHIJKLMOPQRSTUVXWYZ0123456789';
$QuantidadeCaracteres = strlen($Caracteres);
$QuantidadeCaracteres--;

$Hash=NULL;
for($x=1;$x<=$qtd;$x++){
$Posicao = rand(0,$QuantidadeCaracteres);
$Hash .= substr($Caracteres,$Posicao,1);
}

return $Hash;
}

//Here you specify how many characters the returning string must have
echo GeraHash(7);

i did take off <?php, and its a hiden field ! but doesn't work. where do i go wrong ?...

Or is it a better way and easiest way to get a algorythm code from the element field ?.
#237668
  • Posts: 5930
  • Karma: 118
  • Thank you received: 550

MarioPuco replied the topic: Quick mod button doesn't show as well as the other 2

Hey,

1) Create a element and give it name "PASS"
2) Go to your FormPieces > BeforeForm and add this code :
function GeraHash($qtd){
//Under the string $Caracteres you write all the characters you want to be used to randomly generate the code.
$Caracteres = 'ABCDEFGHIJKLMOPQRSTUVXWYZ0123456789';
$QuantidadeCaracteres = strlen($Caracteres);
$QuantidadeCaracteres--;

$Hash=NULL;
for($x=1;$x<=$qtd;$x++){
$Posicao = rand(0,$QuantidadeCaracteres);
$Hash .= substr($Caracteres,$Posicao,1);
}

return $Hash;
}

//Here you specify how many characters the returning string must have
echo GeraHash(7);

$this->execPieceByName('ff_InitLib');
ff_setValue('PASS', GeraHash(7));

That's it :)

Regards,
Mario

Satisfied with our Support ?
PayPal Tip
===============================================
Need to renew Pro Support?
Buy Here!
===============================================
Satisfied?
Consider a membership!
===============================================
Like us on Facebook
===============================================
#237684
  • Sly036
  • Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 9
  • Thank you received: 0

Sly036 replied the topic: Quick mod button doesn't show as well as the other 2

Hi !

Doesn't work :(

i tell you exactly what i did :

1 - created an element

2 - in properties selected "hidden filed"

3- in Label "code secret client"

4- in Name "PASS"

5- Advance tab click customizes

6- BeforeForm

7- entered the code like you specify.

8- save and global save

I have 2 more elements "name" & "last name" field

so when i filled the name and last name works great and i dont see the hidden one, but when i press submit it freezes. no thank you page.

if i take away the PASS field no problem ! i get the thank you page and i receive the form.

i tried the way si told me didn't work so then i tried before putting my code adding the frame work code before adding mine ! still dont work.

maybe you'll see an error in my doing by reviewing my steps.

Sorry taking so much of your time, i know you are really busy with all the request so thanks again for your time and effort :)

best regards
Sly
#237688
  • Posts: 5930
  • Karma: 118
  • Thank you received: 550

MarioPuco replied the topic: Quick mod button doesn't show as well as the other 2

Hi,

Can you send me your info to support@crosstec.org so I can check this out for you ?
I will get back to you asap when I see what's going on there.

Regards,
Mario

Satisfied with our Support ?
PayPal Tip
===============================================
Need to renew Pro Support?
Buy Here!
===============================================
Satisfied?
Consider a membership!
===============================================
Like us on Facebook
===============================================
#237689
  • Sly036
  • Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 9
  • Thank you received: 0

Sly036 replied the topic: Quick mod button doesn't show as well as the other 2

Done ! info sended
#237690
  • Eddy.vh
  • Eddy.vh's Avatar
  • Away
  • Gold Boarder
  • Gold Boarder
  • Posts: 236
  • Karma: 1
  • Thank you received: 26

Eddy.vh replied the topic: Quick mod button doesn't show as well as the other 2

Bonjour.

Je viens de tester le code indiqué par Mario, il fonctionne bien et le bouton d'envoi valide bien le formulaire.

Hello.

I just tested the code indicated by Mario, it works well and the send button validates the form.
#237691
Moderators: ForumSupporttomeperica
Time to create page: 0.071 seconds

New Icon Packs Category!

Crosstec is now offering icon packs.

If you are a paying subscriber, icon packs are automatically added to your account.

Check out our icon packs page!

Live Support Chat Opened!

Join our Discord chat here to receive live support and talk directly to the team!

Summer Sale!

50% discount on all of our extension subscription plans, templates and icon packs!

Get Your Subscription Here

News and Updates

Get informed about new downloads, updates and more in our News and Updates newsletter.

All Extensions Subscription

Get 1 year access to all of our current and future products and 1 year of professional support -- 99 for just 49! (Summer Sale)

No support per domain or website installation limits! Includes all of our current and future Joomla!® extensions, Joomla!® templates for the duration of your membership. This means, by purchasing an All Extensions Subscription you'll have it all covered!

Get it from here

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our subscription plans.

How to receive the discount:

Send us a quick email to sales@crosstec.org with a proof of purchase (for example a paypal receipt), await payment instructions and enjoy your membership!

Live Support Chat Opened!

Join our Discord chat here to receive live support and talk directly to the team!

Community Reward

Help us to create new extensions and plugins! With only $5 you help us a lot and get unlimited download access to all of our products, professional support and even more. Get your reward now!

Read More Here