Home
Download
Add-ons
Help
Forum
Organisation
Project
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
May 26, 2012, 09:21:55 AM
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Search:
Advanced search
Wollen Sie dem WebsiteBaker Team beitreten?
Nähere Informationen finden Sie unter
hier
und auf unserer
neuen Webseite
.
155535
Posts in
21713
Topics by
7737
Members
Latest Member:
chris85
WebsiteBaker Community Forum
English
Help & Support
(Moderators:
Argos
,
badknight
)
Looking for News backend pagination
Pages: [
1
]
Go Down
Author
Topic: Looking for News backend pagination (Read 1271 times)
Argos
Moderator
Offline
Posts: 2161
Looking for News backend pagination
«
on:
May 18, 2010, 10:01:56 AM »
Does anyone know how to create a pagination for the backend of the news module, just like the frontend? A client of mine posts about 5 news items each day, and the list in the backend is growing VERY big. I need some solution to group or paginate or archive the news items into smaller sections, instead of 1 long list.
Logged
Jurgen Nijhuis
Argos Media
Heiloo, The Netherlands
WB Showcase:
http://www.mywebsitebaker.com/pages/showcase.php?v&category_id=1242&count=30
----------------------------------------------------------------
Please don't request personal support, use the forums!
erpe
Offline
Posts: 2077
Re: Looking for News backend pagination
«
Reply #1 on:
May 18, 2010, 11:07:53 AM »
Very good idea.
I would like this too.
rgds
erpe
Logged
stories about
be part of the Tutorials-Project
visit the jQuery-Showroom
pcwacht
AddOn Development
Offline
Posts: 2859
Re: Looking for News backend pagination
«
Reply #2 on:
May 18, 2010, 03:37:12 PM »
Change the modify page so it'll include a jquery table with sort and filter options?
Would be much better to handle then the cumbersumb old way of showing it
Since the output allready goes in a table a jquery table insertion wouldn't be too hard and gives WB core development also a reason why they have included jquery in core files
John
PS I could create it if needed...
For a project I am working on some javascript enhanced tables at the moment :
still testing!!
standard javascript
http://www.scholenmarktamersfoort.nl/pages/opleding-denominatie-2.php
jquery
http://www.scholenmarktamersfoort.nl/pages/opleding-denominatie-3.php
Other javascript for menu's when there are more menustructures or for news grouped the groups can be initially opened or closed
http://www.scholenmarktamersfoort.nl/pages/opleiding--denominatie.php
Logged
http://www.ictwacht.nl
= Dutch ICT info
http://www.pcwacht.nl
= My first
both still work in progress, since years.....
erpe
Offline
Posts: 2077
Re: Looking for News backend pagination
«
Reply #3 on:
May 18, 2010, 03:48:45 PM »
Quote
WB core development also a reason why they have included jquery in core files
I am sure it would work with jQueryAdmin module too
I like your last example for the news module to open and close the grouped-entries.
But it didn't solve the problem that Argos talked about or did I miss something?
If you have busy posters you will have a very long module BE.
rgds
erpe
Logged
stories about
be part of the Tutorials-Project
visit the jQuery-Showroom
Argos
Moderator
Offline
Posts: 2161
Re: Looking for News backend pagination
«
Reply #4 on:
May 18, 2010, 03:56:45 PM »
Very nice 3rd example John! But I also fail to see the relevance to my question: how to prevent the news items forming a very long list in the
backend
when the news module is much used? A pagination like it has in the frontend would be very nice to start with. In fact, it's rather strange that it has frontend pagination, but no backend pagination. I hope that the same function could be applied easily to the backend as well, by some skilled WB coder...
Logged
Jurgen Nijhuis
Argos Media
Heiloo, The Netherlands
WB Showcase:
http://www.mywebsitebaker.com/pages/showcase.php?v&category_id=1242&count=30
----------------------------------------------------------------
Please don't request personal support, use the forums!
pcwacht
AddOn Development
Offline
Posts: 2859
Re: Looking for News backend pagination
«
Reply #5 on:
May 18, 2010, 04:07:10 PM »
There are pagination scripts allso available
The examples are there just to show how normal tables could be enhanced
There is a table-pager addon for tablesorter (jquery)
jquery.tablesorter.
pager for jquery.tablesorter-2.0.3 look here ->
http://tablesorter.com/docs/example-pager.html
So not so hard to do I think.
But another approach wich seems more intuitive for 'common' users would be to show
last x posts in a filterable - sortable table
Or maybe use the one you like to show posts per month or per period
Only drawback I can think of is with javascript (or jquery) one need to fetch the whole table before filtering etc could work wich could take some time
Next to this there are ajax enhanced tables wich load only so much per page
datagrid
http://phpbuilder.blogspot.com
comes to mind but maybe there are more.
in fact, by adding a javascript or jquery to the standard tabel is not so hard to do, is very easy
The datagriid nees some more thinking cause it will change the total backend look and feel (for the news module)
John
PS Not saying this IS THE solution, could be a solution
Logged
http://www.ictwacht.nl
= Dutch ICT info
http://www.pcwacht.nl
= My first
both still work in progress, since years.....
Argos
Moderator
Offline
Posts: 2161
Re: Looking for News backend pagination
«
Reply #6 on:
May 18, 2010, 04:15:26 PM »
I'm not sure why you come up with tabel sorting stuff...
I just need pagination to show 10 or 20 or 40 items per page, just like you can set for the frontend. Maybe because I'm not a coder, but I still don't see what your frontend tabel sorting has to do with news item pagination in the backend of the News module... I'm not looking for fancy filtering and searching stuff (who needs that in the backend anyway), but just a way to prevent the list and the page from becoming too long. The same goes for endless entries in much used form modules by the way, but those are other modules. I was just thinking about using the available frontend pagination function for the backend as well, or is that not possible?
«
Last Edit: May 18, 2010, 04:19:56 PM by Argos
»
Logged
Jurgen Nijhuis
Argos Media
Heiloo, The Netherlands
WB Showcase:
http://www.mywebsitebaker.com/pages/showcase.php?v&category_id=1242&count=30
----------------------------------------------------------------
Please don't request personal support, use the forums!
pcwacht
AddOn Development
Offline
Posts: 2859
Re: Looking for News backend pagination
«
Reply #7 on:
May 18, 2010, 04:31:45 PM »
Hmmm, maybe I was thinking too much of editing posibility of all entries in one screen, wich for me seems more logical then pagination.
Will look at pagination stuff, could be doable without altering databases by using preset from frontend
Imaging editing entries number x on page y, after saving the modified entry you might be brought back to startpage wich seems non-intiutive to me, need to think of a solution
Another idea might be to show x entries (posts and comments) on backend entry page with link to all entries (posts or comments)
Might allso work for forms btw
Or would a simple copy frontend pagination to backend be enough?
What about comments (when used? ) etc
John
Logged
http://www.ictwacht.nl
= Dutch ICT info
http://www.pcwacht.nl
= My first
both still work in progress, since years.....
Argos
Moderator
Offline
Posts: 2161
Re: Looking for News backend pagination
«
Reply #8 on:
May 18, 2010, 04:40:25 PM »
Right now for me personally a simple copy of the frontend pagination would be fine. It's just to limit the number of items per page to prevent long pages and long page load. News items are posted, and almost never edited afterwards. I never use comments for news items, and in fact I always remove the comment sections from the News module backend, as well as the groups function. I like it clean and as simple as possible. Often I remove the short entry editor field as well, because most of the times short intros are not used. Anyway, copy of frontend pagination would be fine for now. Slicker and more powerful options are welcome of course, but I don't need them myself right now.
Logged
Jurgen Nijhuis
Argos Media
Heiloo, The Netherlands
WB Showcase:
http://www.mywebsitebaker.com/pages/showcase.php?v&category_id=1242&count=30
----------------------------------------------------------------
Please don't request personal support, use the forums!
pcwacht
AddOn Development
Offline
Posts: 2859
Re: Looking for News backend pagination
«
Reply #9 on:
May 18, 2010, 05:13:50 PM »
k here you go
unzip and place the modify.php over the exisiting one in news module
Mind you, this modify.php is taken from WB280, not sure wich version etc you used
Major changes is copying the pagination stuff from view.php to modify.php, loosing the groups filter
Allso added some php stuff at the end of the news lists to show pagination
Have fun,
John
Logged
http://www.ictwacht.nl
= Dutch ICT info
http://www.pcwacht.nl
= My first
both still work in progress, since years.....
erpe
Offline
Posts: 2077
Re: Looking for News backend pagination
«
Reply #10 on:
May 18, 2010, 05:58:02 PM »
Hi John
thanks for that.
I tested it on a 2.8.1 and it seems to work fine.
It uses number of news entry for the frontend also for the backend, right?
rgds
erpe
Logged
stories about
be part of the Tutorials-Project
visit the jQuery-Showroom
pcwacht
AddOn Development
Offline
Posts: 2859
Re: Looking for News backend pagination
«
Reply #11 on:
May 18, 2010, 08:59:16 PM »
Yups, I just copied the code from view.php and made it work, nothing much.
If I have much more time I might try getting following to work:
1 - extend settings with backend numbers posts to show, number comments to show
2 - extend settings with use comments? yes/no
3 - change modify.php so it will -
- show number of posts (from settings)
- link to modify_posts wich will show all posts with sorting, searching etc
- show number of comments if wanted
- link to modify_comments wich will show all comments with sorting, searching etc
Seem like a nice project
Allso the news module is my favorite to adapt to various situations, look at vacatures page for example wich is basicly a modified newsmodule ->
http://www.meerwegen.nl/pages/vacatures.php
Sorry but it is in Dutch
In the backend there are preset fields wich can be choosen so a new entry takes only a few seconds.
Logged
http://www.ictwacht.nl
= Dutch ICT info
http://www.pcwacht.nl
= My first
both still work in progress, since years.....
Argos
Moderator
Offline
Posts: 2161
Re: Looking for News backend pagination
«
Reply #12 on:
May 18, 2010, 09:06:53 PM »
Wonderful job John, thanks very much for the quick solution!
I would love to see you work more on the News module, it's also one of my favorites. I also use it for different purposes, for example articles, event calendar, FAQ, business directory, etc.
Logged
Jurgen Nijhuis
Argos Media
Heiloo, The Netherlands
WB Showcase:
http://www.mywebsitebaker.com/pages/showcase.php?v&category_id=1242&count=30
----------------------------------------------------------------
Please don't request personal support, use the forums!
erpe
Offline
Posts: 2077
Re: Looking for News backend pagination
«
Reply #13 on:
May 18, 2010, 11:13:57 PM »
Quote
Seem like a nice project
yes, indeed.
Nice preset on your linked site.
I am curious to see the new news module work.
rgds
erpe
Logged
stories about
be part of the Tutorials-Project
visit the jQuery-Showroom
pcwacht
AddOn Development
Offline
Posts: 2859
Re: Looking for News backend pagination
«
Reply #14 on:
May 19, 2010, 07:48:20 AM »
k will do it.
Current features for a new newsmodule, wich I am aware of and could need and will implement:
backend: (numbers are for clarification nothing else)
1 - extend backend settings, use comments or not - use short_content or not
2 - initial backend page, show posts with pagination, search and sorting
3 - initial backend page, show link to new comments (if used) list page with pagination, sorting and searching
4 - extend post with keywords field (usable for newsitems like this and html meta tag keyword)
4a - loose groups, keywords is much more flexible then groups
4b - create primary grouplist of x items for easy select and set default selected
5 - extend post with written by field wich overrides wb user
6 - extend number of views (if viewed from frontend increase counter)
7 - last viewed (if viewed set current date)
8 - give module a sensible name wich could be easy changed (search replace) to create new module for specific changes
If you think of anything else let me know, maybe my humble skills are solid enough
John
Logged
http://www.ictwacht.nl
= Dutch ICT info
http://www.pcwacht.nl
= My first
both still work in progress, since years.....
Argos
Moderator
Offline
Posts: 2161
Re: Looking for News backend pagination
«
Reply #15 on:
May 19, 2010, 10:34:26 AM »
Wow! Sounds really great John! I can't wait
Can you explain a bit about:
Quote
4a - loose groups, keywords is much more flexible then groups
4b - create primary grouplist of x items for easy select and set default selected
I understand 4a, but then you talk about "primary grouplist" in 4b. What do you mean by that?
Logged
Jurgen Nijhuis
Argos Media
Heiloo, The Netherlands
WB Showcase:
http://www.mywebsitebaker.com/pages/showcase.php?v&category_id=1242&count=30
----------------------------------------------------------------
Please don't request personal support, use the forums!
Argos
Moderator
Offline
Posts: 2161
Re: Looking for News backend pagination
«
Reply #16 on:
May 19, 2010, 10:38:49 AM »
I guess it is a lot harder to do, but my dream is a News module that allows for custom fields, like you have done for your Vacatures version (which I guess have hardcoded fields). So the user can create custom fields, much like the form module, in the Settings. And those fields then appear in the item page when you create or edit an item. Well... I guess it's rather complex and complicated, but it would make the module even more flexible and powerful...
Logged
Jurgen Nijhuis
Argos Media
Heiloo, The Netherlands
WB Showcase:
http://www.mywebsitebaker.com/pages/showcase.php?v&category_id=1242&count=30
----------------------------------------------------------------
Please don't request personal support, use the forums!
pcwacht
AddOn Development
Offline
Posts: 2859
Re: Looking for News backend pagination
«
Reply #17 on:
May 19, 2010, 11:04:08 AM »
keywords, as I think of it at the moment
1 keywords like on pagesettings can be used in html and in simular pages, nothing tough here
2 fixed keywords, kind like the primary keywordlist wich only hold 10 or so keywords wich can be (multi)selected
think news will be used for programdescriptions
fixed keywords could be operating system (linux, windows, mcintosh etc) and license (freeware, gpl, commercial etc)
free keywords could be keywords about the content of the program wich could differ per article
by using the fixed keywords one could create groups, all windows or all windows AND gpl etc
Think of fixed keywords more as categories, but due to the way they are selected with a limited amount
Real life example, am working on a new scholenmarktamersfo
ort.nl
Each school has only ONE denomination, but has one or more education
the denomination is a dropdown, select only ONE
the education is a list (max 15) with multiselect on the rightside of the normal post modify page
Hmm, hope I clarified it a bit
Custom fields, thats why the module should be easy clonable,
ie, unzip module, search replace OLD_MODULE to NEW_MODULE
zip, and install
This way it is easy to customize with litle phpskills
Trouble with custom fields is that it will be never enough, nor will it fit everyones need
Will give it a thought though, maybe someone comes up with something.
John
PS When more ideas will come, or project get started I will start a new thread, or maybe this thread can be renamed so we don't clutter everything up.
Logged
http://www.ictwacht.nl
= Dutch ICT info
http://www.pcwacht.nl
= My first
both still work in progress, since years.....
pcwacht
AddOn Development
Offline
Posts: 2859
Re: Looking for News backend pagination
«
Reply #18 on:
May 19, 2010, 04:32:38 PM »
a picture says more then a thousend words....
In picture you'll see the use of fixed catagories on the right (opleidingen) and why amount is limited, page has a length
John
«
Last Edit: May 20, 2010, 07:33:02 AM by pcwacht
»
Logged
http://www.ictwacht.nl
= Dutch ICT info
http://www.pcwacht.nl
= My first
both still work in progress, since years.....
Argos
Moderator
Offline
Posts: 2161
Re: Looking for News backend pagination
«
Reply #19 on:
May 20, 2010, 08:46:02 AM »
Looking nice! I see what you mean by limited list of categories/groups/keywords. You could however position them horizontally, or use a multiple selection dropdown menu maybe?
Quote
Trouble with custom fields is that it will be never enough, nor will it fit everyones need
With custom field I meant that averyone can create his own fields, especially to be able to fit everyones needs. Just like in a form module you create an input form once, and than that input form shows up in each new news item. So everyone has the ability to create just the input fields he needs. And so it fits everyone. Or am I thinking too simple?
Logged
Jurgen Nijhuis
Argos Media
Heiloo, The Netherlands
WB Showcase:
http://www.mywebsitebaker.com/pages/showcase.php?v&category_id=1242&count=30
----------------------------------------------------------------
Please don't request personal support, use the forums!
pcwacht
AddOn Development
Offline
Posts: 2859
Re: Looking for News backend pagination
«
Reply #20 on:
May 20, 2010, 10:44:59 AM »
custom fields
So basicly you say:
determine basic needed fields (ie wysiwyg, title, active etc.) and add formmodule functionality to add/edit fields
The problem here lies:
- in settings, fieldloop etc, there you place [FIELDNAME] to output the field [FIELDNAME] changes when a user only looks at it
- a user removes a field wich is used, thus loosing data
My way is just clone the news module, tinker a bit with tables, modify, modify_post and save_post
this way a user can't ruïn it
I have been working on something wich uses the formmodule to generate frontend lists a few years back when wb was still in 2.6 series
Called modbuilder, was in may 2006, never really completed it when I understood the troubles with users
What it does was storing forms and using those to show lists and detail pages.
Can't remember where I was on that one
John
Logged
http://www.ictwacht.nl
= Dutch ICT info
http://www.pcwacht.nl
= My first
both still work in progress, since years.....
Argos
Moderator
Offline
Posts: 2161
Re: Looking for News backend pagination
«
Reply #21 on:
May 20, 2010, 11:06:42 AM »
Well, I was thinking on just adding 4 kind of fields as custom: shorttext, longtext (WYSIWYG), radio button, and select box. The Active, Title, and Date options would remain the same as now.
But I understand the issue with users ruining settings, that's why I always hide the settings from my clients
The form modification from years back, you talk about sounds also a nice project. Oh well, You should do whatever you may feel is best or needed most or easiest... Improving the default News module with the things you suggested into an "Advanced News" module would be most welcome for most users anyway, I think. Feel free to create another thread for that if you want, and I will move these last posts into that thread.
Logged
Jurgen Nijhuis
Argos Media
Heiloo, The Netherlands
WB Showcase:
http://www.mywebsitebaker.com/pages/showcase.php?v&category_id=1242&count=30
----------------------------------------------------------------
Please don't request personal support, use the forums!
Pages: [
1
]
Go Up
Jump to:
Please select a destination:
-----------------------------
General
-----------------------------
=> General Announcements
=> Security Announcements
=> Documentation
=> WebsiteBaker Website Showcase
=> Guest Area & Off-Topic
-----------------------------
English
-----------------------------
=> WebsiteBaker 2.9
===> Announcements
===> Help/Support
=====> Modules / Extensions
===> Suggestions
===> Software bugs
=> Help & Support
=> Modules
=> Droplets (PHP code for use with Droplet module) & Snippets (raw PHP code)
=> jQuery
=> Templates, Menus & Design
=> WebsiteBaker Language Files
=> WebsiteBaker 2.x discussion
=> WebsiteBaker 3
=> Archive (posts up to 2007)
-----------------------------
Deutsch (German)
-----------------------------
=> Ankündigungen
=> WebsiteBaker 2.9
===> Ankündigungen
===> Hilfe/Support
=====> Module / Extensions
===> Vorschläge
===> Softwarefehler
===> Erfahrungs und Testberichte
=> Hilfe/Support
=> Module & Snippets
=> Templates & Design
=> Tutorials
=> jQuery
=> Diskussion über WB
=> Off-Topic
=> Archiv für Themen bis 2007
-----------------------------
Nederlands (Dutch)
-----------------------------
=> Aankondigingen
=> Hulp & Ondersteuning
=> Niet-Terzake (Off Topic)
-----------------------------
Francais (French)
-----------------------------
=> Help/Support
-----------------------------
Italiano (Italian)
-----------------------------
=> Help/Support
-----------------------------
Bakery (WB shop module)
-----------------------------
=> Bakery English
=> Bakery Deutsch
-----------------------------
KeepInTouch (Multi Contact Module)
-----------------------------
=> KeepInTouch English
=> KeepInTouch Deutsch
Loading...