Hot answers tagged

4 votes
Accepted

How can I filter the Persian alphabet in PHP for Joomla 4?

Per documentation, WORD filter does not allow unicode characters: WORD: A string containing A-Z or underscores only (not case sensitive) https://api.joomla.org/framework-2/classes/Joomla-Filter-...
Sharky's user avatar
  • 10.8k
3 votes
Accepted

Link to Page & Pre-Filter Portfolio Items

I found the answer, thanks for the help @jamesgarrett The tabs were using shuffle.js so I needed to edit the page builder js file. jQuery(function($) { var $container = $('.sp-simpleportfolio-...
jonboy's user avatar
  • 3,593
3 votes

Link to Page & Pre-Filter Portfolio Items

By "anchor and jquery" you mean like the way bootstrap tabs work - ie. by letting the uri's fragment hit the id of the tab. But these tabs aren't set up like that. You can of course use jquery to ...
jamesgarrett's user avatar
  • 3,289
3 votes
Accepted

Manually render filter form fields in layout

Include group name as the second parameter in renderField(), e.g.: echo $this->filterForm->renderField('published', 'filter'); echo $this->filterForm->renderField('limit', 'list'); Or if ...
Sharky's user avatar
  • 10.8k
2 votes

Tags filter field - how to add custom "placeholder"?

Create a language override for the constant: JGLOBAL_TYPE_OR_SELECT_SOME_OPTIONS Extensions > Languages > Overrides Create a new override Type/paste "JGLOBAL_TYPE_OR_SELECT_SOME_OPTIONS" as the ...
Michael's user avatar
  • 593
2 votes

when calling "JRequest::get('FilterForm')" result is empty

This is the way to retrieve an input: $jinput = JFactory::getApplication()->input; $this->filterForm = $jinput->get('FilterForm', 'default_value', 'filter'); TIP: Take into account that if ...
Anibal's user avatar
  • 7,435
2 votes

State is not populated to my View

The meaning of $state = $this->get('State'); is $state = $model->getState(); where $model is the current model of your view. If your model is extending from JModelList, all your state ...
Nagarjun's user avatar
  • 2,991
2 votes
Accepted

Filter an IP address

For the time being, I've used PHP native filter_var with the FILTER_VALIDATE_IP filter, like so: return filter_var($ip, FILTER_VALIDATE_IP); I'm still of course open to other suggestions
Lodder's user avatar
  • 26.9k
2 votes
Accepted

Why does Joomla remove html tags from submitted text even when filter types are set to raw?

Using $_POST as array key in getArray() argument is producing a warning: Warning: Illegal offset type If your form is using form control (normally jform), you can get unfiltered data like this: $...
Sharky's user avatar
  • 10.8k
2 votes

Unset filter from user state

The solution I found was $app->setUserState($this->context . '.filter.search', ""); The context can be changed so you can also change filters from different models
Jbadminton's user avatar
2 votes

Smart search filter not working

Probably you didn't run the indexer that's why smart search doesn't show any results. Here are the steps you should follow for the smart search to work (probably you should go to the fifth step ...
Vassilis Theodoropoulos's user avatar
1 vote

Using form XML for custom filter and removing group definition

So this is what I ended up doing: $value = Factory::getApplication()->input->getInt('category'); $bookform = Form::getInstance('com_books.book', 'book'); $field = $bookform ->getField('...
Mike's user avatar
  • 341
1 vote

Server name removed from text when submitting JForm TinyMCE editor field

I think you answered your own question, there, so I'll just chime in with some extra detail. First, I only rarely use any of the js wysiwyg editors for precisely this sort of reason; the take away ...
Arlen's user avatar
  • 802
1 vote
Accepted

Filtering product query with two sets of filters. (J2Store)

You are better served to GROUP BY item then execute your qualifying id_filters, special_filters, and other_filters conditions on the aggregate data via the HAVING clause. For your db-fiddle demo... ...
mickmackusa's user avatar
  • 4,781
1 vote
Accepted

in Joomla 3.8 default search tools do not respond in my own component and cannot set and get state of the filters

I just spotted out my small but really basic, stupid mistake in my own code (above). So, of course I could not really expect that someone will come and stares at a lot of code and spot any mistake in ...
Zollie's user avatar
  • 2,896
1 vote
Accepted

How to preserve HTML input via wysiwyg into custom html module?

So, I didn't find out the mechanics of why this happens, but it does. I solved my problem by using this the Custom HTML Advanced module, which doesn't do any text filtering at all. Another solution ...
nizz0k's user avatar
  • 537
1 vote

How to preserve HTML input via wysiwyg into custom html module?

In your Joomla backend, go to Global Configuration >> Text Filters. Under the Super User row, select No Filtering from the dropdown menu.
Lodder's user avatar
  • 26.9k

Only top scored, non community-wiki answers of a minimum length are eligible