joomla3.0

Joomla 3 - How to get value from configuration file?

强颜欢笑 提交于 2021-02-07 11:44:06
问题 I'm building a custom component and I just want to get a value from the global config in my controller. I can't find any information about how to do this. Something like... $config = JFactory::getConfig(); $this->_db = $config->get('db'); 回答1: The documentation on how to do it is slightly outdated: http://docs.joomla.org/JFactory/getConfig But if you check the code they actually drop the ampersand function: https://github.com/joomla/joomla-cms/blob/staging/components/com_users/models

How to use prepare statements / bind values in a query in Joomla 3?

此生再无相见时 提交于 2021-01-27 14:13:57
问题 I'd like to know how to bind values in where clause. I have understood that is something that MUST be done for security reasons. $db = JFactory::getDbo(); $query = $db->getQuery(true); $query ->select("*") ->from($db->quoteName("food")) ->where("taste = :taste") ->bind(':taste', 'sweet'); $db->setQuery($query); $rows = $db->loadAssocList(); I'm getting this error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use

Auto fill form input fields from database using AJAX

烂漫一生 提交于 2020-04-11 07:40:12
问题 Can't get this to work and could use an extra pair of eyes to find what I'm doing wrong or what might be missing. I created a form using the RSForm Pro component for Joomla 3.3.1. The purpose of the form is to allow a user to file warranty claims on our products. If a user needs to file a repeat claim on a product then an input field is displayed with a button to retrieve data from the database and auto fill the owner's info for the user. For every claim submitted an "id" is generated. This

Auto fill form input fields from database using AJAX

谁说胖子不能爱 提交于 2020-04-11 07:39:09
问题 Can't get this to work and could use an extra pair of eyes to find what I'm doing wrong or what might be missing. I created a form using the RSForm Pro component for Joomla 3.3.1. The purpose of the form is to allow a user to file warranty claims on our products. If a user needs to file a repeat claim on a product then an input field is displayed with a button to retrieve data from the database and auto fill the owner's info for the user. For every claim submitted an "id" is generated. This

Joomla 3 Plugin Design

霸气de小男生 提交于 2020-01-26 04:16:20
问题 Does anybody know of any good references/tutorials for plugin/extension design for Joomla 3? I'm struggling to find up to date information. Specifically I want to make a plugin to extend the K2 registration functionality so information on how to integrate plugins with other Joomla extension would also be great! I'm reasonably proficient with php but I've only started to look at Joomla code so maybe that's worth considering! 回答1: For Joomla! specific information use the Joomla Docs website at

Joomla 3.2 Grouped List Custom Field List doesn't have SELECTED value

只愿长相守 提交于 2020-01-23 18:01:08
问题 I am trying to create a custom field form for template parameter for Joomla 3, by following instruction from this page Creating a custom form field type Here are my codes : class JFormFieldMy extends JFormField { protected $type = 'my'; public function getInput() { return '<select id="'.$this->id.'" name="'.$this->name.'">'. '<optgroup label="First">'. '<option value="1">One</option>'. '<option value="2">Two</option>'. '<option value="3">Three</option>'. '</optgroup>'. '<optgroup label=

Convert Joomla 2.5 template to 3.0

淺唱寂寞╮ 提交于 2020-01-11 02:06:10
问题 I have a custom joomla 2.5 template and I wish to convert it to Joomla 3.0. Currently the only method I found is how to convert a Joomla 1.5 to 2.5. Please guide me here because I have spent almost a month on this. I found a method http://docs.joomla.org/J3.1:Converting_A_Previous_Joomla!_Version_Template but I do not understand how to go about it. If you could also give a clear procedure on how to implement the steps in the link I have posted this would help me alot. 回答1: This answer may not

Need to control a plugin from front end to apply to article text only - is this Possible?

微笑、不失礼 提交于 2020-01-06 15:28:09
问题 I'm building a website for a voluntary group to support dyslexia-related learning difficulties and one of their aids is to change the text from plain black and white to multi-coloured, so that every nth character for example, the colour changes to a contrasting one. An example can be seen at: Colorise plugin [colorize] To change any text from plain to colorised, I have to edit the article and add the html tags like so. [/colorize] (I know the brackets are wrong.) To change back to plain, I

Errors while upgrading joomla 2.5 to 3.x.x

半世苍凉 提交于 2020-01-06 14:17:15
问题 I attempted to upgrade from joomla 2.5.11 to 3.2.3 which is latest right now. First of all I checked and upgraded all extensions - CB, k2, kunena, xmap (I did not upgrade xmap as I got errors so I left it, little one not important) to latest by going extensions manager -> update tab . Then going components-> joomla-> update update to 3.2.3. The update finished but I got an error about remember.php and could not access admin panel. Getting suggestions from Fatal error when updating joomla from

Jommla 3 Header Title Bar

江枫思渺然 提交于 2020-01-05 15:19:42
问题 Does anybody know how to add a header "Title Bar" in joomla 3 for where the title should go for an article? I have attached a picture of what I'm looking for. Thanks Title Bar Picture 回答1: By default you also can add for example a single line, we have a feature for Custom Page Heading on each Menu Item. If you have for example a menu item type Category Blog, this will works for the entire section, same thing for menu item type Single Article and so on. 回答2: It looks like the titles are being