- Posts: 10
COMMUNITY FORUM
how i get the item ID
- iceasanka
- Topic Author
- Offline
- New Member
Less
More
11 years 3 months ago #114863
by iceasanka
how i get the item ID was created by iceasanka
B)
i want to get the current item id in back-end and the front-end (current mean opening item one)..how i get the value ? help
i want to get the current item id in back-end and the front-end (current mean opening item one)..how i get the value ? help
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
Less
More
- Posts: 15920
11 years 3 months ago - 11 years 3 months ago #114864
by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: how i get the item ID
Hello iceasanka,
You can use these variables:
You can use these variables:
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- iceasanka
- Topic Author
- Offline
- New Member
Less
More
- Posts: 10
11 years 3 months ago #114865
by iceasanka
Replied by iceasanka on topic Re: how i get the item ID
early i used this two codes but it returns 0 value , In back-end i want it for plugin
Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
Less
More
- Posts: 15920
11 years 3 months ago #114866
by Krikor Boghossian
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Replied by Krikor Boghossian on topic Re: how i get the item ID
These variables are for the front-end only.
As for the plugin I recommend having a look at getk2.org/extend/extensions/90-example-k2-plugin-for-developers
As for the plugin I recommend having a look at getk2.org/extend/extensions/90-example-k2-plugin-for-developers
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- iceasanka
- Topic Author
- Offline
- New Member
Less
More
- Posts: 10
11 years 3 months ago #114867
by iceasanka
Replied by iceasanka on topic Re: how i get the item ID
only i wan to get the item id in back-end , (the item number) ,how i get it ?
Please Log in or Create an account to join the conversation.
- iceasanka
- Topic Author
- Offline
- New Member
Less
More
- Posts: 10
11 years 3 months ago - 11 years 3 months ago #114868
by iceasanka
i want to get item id like this inside the my plugin
Replied by iceasanka on topic Re: how i get the item ID
<?php
echo $itemid
?>
i want to get item id like this inside the my plugin
Please Log in or Create an account to join the conversation.
- iceasanka
- Topic Author
- Offline
- New Member
Less
More
- Posts: 10
11 years 3 months ago #114869
by iceasanka
Replied by iceasanka on topic Re: how i get the item ID
hello Krikor Boghossian
do you have any idea????
:angry:
do you have any idea????
:angry:
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
Less
More
- Posts: 15920
11 years 3 months ago #114870
by Krikor Boghossian
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Replied by Krikor Boghossian on topic Re: how i get the item ID
nope, $itemid won't work try $item->id; and var_dump($item); to see all of it's attributes.
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- iceasanka
- Topic Author
- Offline
- New Member
Less
More
- Posts: 10
11 years 3 months ago #114871
by iceasanka
Replied by iceasanka on topic Re: how i get the item ID
i meanreturn the 0 value in back-end.i found it.
$item->id; and var_dump($item);
$id = (int)JRequest::getInt('cid');
Please Log in or Create an account to join the conversation.