• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Variable checkbox items

Variable checkbox items 9 years 3 months ago #33870

Hello, again. I already made this post but I'm making a new one because I want to focus the solution to the problem in a different simpler way.

If you haven't read the previous post, here is the thing:

I want to make a checkbox with the items from a database. I have this code
//<code>
$user_id = 1;
$db =& JFactory::getDBO();
$db->setQuery("SELECT field FROM `teble` where id=" . $user_id);
$result = $db->loadObjectList();
 
foreach ($result as $r) {
$items .= $r->field . "\n";
}
}
 
return $items;
//</code>

Works fine, but I want guests to be able to submit the form, so I need to somehow send the $user_id variable through the URL.

ie: /index.php?user_id=10

So the Checkbox list is filled with the items of the user #10
The administrator has disabled public write access.

Variable checkbox items 9 years 3 months ago #33872

The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!