121 Posts
deralex
8 years ago
Topic

Hi,

I have items that are grouped. I create a group, let's say "green", which is an article in fact. To "green" I attach an article "grass". "Green" is stored in #__cck_store_form_colors, "grass" is stored in #__cck_store_form_flowers. The connection is saved in #__cck_store_join_colors_flowers. It's important to keep that order. Everything fine so far.

For a special reason the user can add flowers vice versa. The item is created and saved in the database, without the join. How can I insert the join connection?

As a solution I could call a function in aftersave and fill the database. Then I need the id of the just saved article. How can I get that id within aftersave?

Hope you can help.

Alex

Get a VIP membership
1283 Posts
Bucklash
8 years ago
0
Level 1

Hi

If using afterstore then you can grab the id ... $config['pk']

changing-the-joomla-message-after-a-submission-of-a-seblod-form

    

using-code-pack

      

create-content-dynamiclly-using-code

121 Posts
deralex
8 years ago
0
Level 1

That's it! Thumbs up! Thank you!

Get a Book for SEBLOD