This site uses cookies and similar technologies.

If you don't change browser settings, you agree to it.

I understand
61 Posts
Wolfgang Claus
14 days ago
3
Topic

Hi there,

I have some content all with the same category id , all of the same content type based on the joomla article content type.

For privacy protection reason, all content older than 6 weeks must be deleted.

So I wrote a user-plugin, which finds all older articles in the #__content table when a user logs in.

Then I tried to delete these contents by using the seblod method:

$content = new JCckContentArticle;
$content->delete( $pk );   // Here I use the id of my #__content- results as $pk.

But nothing happens. Maybe this method does not work in a user plugin?

I checked the jCckContentArticle-Object: it does exist. 

Any idea, what is wrong with this?

Thank you

Wolfgang

Get a Book for SEBLOD
13 days ago
2
Level 1

Hi Wolfgang,  

it's probably a permission issue.  

Have a look here : Manipulating Content: More methods, more capabilities


Regards.

61 Posts
Wolfgang Claus
13 days ago
0
Level 2

Thank you Lionel,

I will try this tonight and let you know the result.

Wolfgang  :-)

61 Posts
Wolfgang Claus
11 days ago
0
Level 2

I tested the permissions, but it didnt work. The object returns "false" to the delete command.

Now I set the state to -2. Maybe I will have the time to solve this later.

Wolfgang

Get a VIP membership