String Replace at Intervals has been submitted to Free Addons and should be available soon.
This is a coding utility which can be used to modify output strings. For example, you can add a <br /> or classname to every third occurrence of an element for formatting. This can be changed (dynamically, even) without touching the original generator.
There is also a version of the function which can handle single-level arrays as if they were strings, except that the string to be replaced cannot span across array element boundaries.
* You can replace every nth occurrence of a search string with another string.
* You can start replacement at any occurrence of the search string.
* You can start looking for occurrences of the search string at any position in the base string.
Probably most commonly, you could add a line break or clearing element at desired intervals to make a plain list of automatically generated items wrap cleanly at every third, fourth or whatever item. Or it could be used to give a different style to the elements that will be first or last in each row of a multi-row listing.
Could this plugin be used to generate "Dynamic" attributes? In other words - based on one attibute selection the next attribute would change to a different name/value (And Price!)
Or would there be a better way to do this?
No, this would not have anything to do with making attribute dependencies. For that you need javascript that interacts with the code. All this does is manipulate an output string.
I've studied this utility thoroughly, but being a newby at this, I can not find how to use it.
My menu is generated by means of the UL-generator, and what I would like is to have a clear:both inserted at the 5th and every following level2 of the menu... but how do I apply this module to do so?
See the pix (the frames are there for me to see what's happening when I change things)
I'm setting up a fixed menu on the home page (it's basically the dropdown menu without the drop down)
I now use 5 categories for testing, but in real life the site will have approx 20 categories.
In this case the Category 5 should be under Category 1;
How do I achieve this with your module?
I have no clue how and where to call it, and where to enter the variables...
Thanks in advance.
Moderation
Destination thread ID and reason are required when shown.
Report Post
Tell staff why this post should be reviewed.
Manage cookie preferences
Our cookie policy has been updated, so we need you to review your preferences and consent again.