Announcement
Collapse
No announcement yet.
Giving categories unique ID's
Collapse
X
-
Glad to help and thanks for confirming that the code works.
- Top
- Translate
- Bottom
-
Originally posted by glennrocksvb View PostWith your changes, I think it can be easily done in the display_Forums_list template instead of doing it in JS.- Paste this code right after the <vb:each from="channels" value="channel"> line. (line 5 in vB 5.7.0)
HTML Code:<tbody id="category{vb:raw channel.nodeid}">
- Paste this code right before the last </vb:each> line. (line 97 and the last line in the template in vB 5.7.0)
HTML Code:</tbody>
The template change does work and your JS code works as well.
Cheers.
- Top
- Translate
- Bottom
- Paste this code right after the <vb:each from="channels" value="channel"> line. (line 5 in vB 5.7.0)
-
With your changes, I think it can be easily done in the display_Forums_list template instead of doing it in JS.- Paste this code right after the <vb:each from="channels" value="channel"> line. (line 5 in vB 5.7.0)
HTML Code:<tbody id="category{vb:raw channel.nodeid}">
- Paste this code right before the last </vb:each> line. (line 97 and the last line in the template in vB 5.7.0)
HTML Code:</tbody>
Last edited by glennrocksvb; 11-29-2022, 11:08 AM.
- Top
- Translate
- Bottom
- Likes 1
Leave a comment:
- Paste this code right after the <vb:each from="channels" value="channel"> line. (line 5 in vB 5.7.0)
-
Nice one darkboy245. But you need to use <tbody id="catsXXX"></tbody> to prevent generating invalid HTML markup. Table tags cannot have <li> tag as parent of <tr> tags.
- Top
- Translate
- Bottom
Leave a comment:
-
Originally posted by glennrocksvb View PostThis will require substantial changes to the display_Forums_list template. Changing the HTML structure will depend on how your intended style would look like.
Here is the code:
Code:$('.category-header').each(function() { $(this).nextUntil('.category-header').addBack().wrapAll('<li id="cats"></li>'); }); β
- Top
- Translate
- Bottom
Leave a comment:
-
This will require substantial changes to the display_Forums_list template. Changing the HTML structure will depend on how your intended style would look like.
- Top
- Translate
- Bottom
Leave a comment:
-
Originally posted by glennrocksvb View PostIt already has forum id.
The challenge in customizing the style is the entire list uses a single <table> tag. It would have been easier if each category and its forum channels is in its own <table>. Or better yet, to not use <table> tag.
I have a pure CSS mod to separate the forum category list in its "own table". It's not perfect due to the challenge mentioned above but here it is:
https://vbmods.rocks/forum/vbulletin...oud-compatible
- Top
- Translate
- Bottom
Leave a comment:
-
It already has forum id.
The challenge in customizing the style is the entire list uses a single <table> tag. It would have been easier if each category and its forum channels is in its own <table>. Or better yet, to not use <table> tag.
I have a pure CSS mod to separate the forum category list in its "own table". It's not perfect due to the challenge mentioned above but here it is:
https://vbmods.rocks/forum/vbulletin...oud-compatible
- Top
- Translate
- Bottom
Leave a comment:
-
Giving categories unique ID's
in vBulletin 4 categories are separated unlike vBulletin 5 which makes it harder to design the layout of the categories with CSS, looking for help to modify the display_Forums_list template in order to give each category a unique ID.
Example:
Thanks in advanceLast edited by glennrocksvb; 05-20-2022, 08:21 AM.Tags: None
- Top
- Translate
- Bottom
Latest Topics
Collapse
-
by webmsghow can I add the member name to the last post when browsing the list of threads in the forum instead of "last post" ?
thanksβ06-05-2023, 07:57 AM -
by PrometheusHello everyone,
Is there a way to make a WoltLab Suiteβ’ 5.5.12 vBulletin compatible?
would like to change the forum softw...06-06-2023, 10:39 AM -
by oldfanI have never edit the mobile skin before. Is it hard or easy? I don't see many tutorials on it either. You ski. For example, is it a downloadable skin...05-28-2023, 11:58 AM
-
by glennrocksvbGranting "Can Manage Topics" permissions to Moderators or other usergroups gives them the power to Move, Delete/Undelete, Open/Close, Approve/Unapprove,...05-27-2023, 11:57 PM
Leave a comment: