I've noticed some websites that have a most viewed posts section. I am looking to add this functionality to the side bar.
How can you setup a method that determines how many posts have been selected by a user then add in the top 3 or so viewed posts?
For example here (towards the middle of the page in the sidebar, the most viewed): http://america.aljazeera.com/
Is there a bundle that incorporates this?
Or is there an easier method by using a count based on how many times a user clicks on a post?
No, I don't know anyBundle doing that.
To have the 3 most viewed article you need to add a field in your database which save how much the article is important.
You have severals ways of doing it, this is what comes to my mind:
First: You add an relation ViewedByWeek -> Post.
Foreach post, this entity keep how much it have been visited.
Everytime an user visit the page, you improve the number of visits of the post for the current week.
Then, you can find the most popular post in the week, in the month, in the year.
If you don't use anything related to the time, the information will not be changing much
Related
Good day kind crew. I haBe a issue. what I am trying to do is this: a tennis league with 5 divisions. These 5 divisions are located in everytown and those towns in states. I am using ACF and pods. On the state archive page. We would like to choose the state and then on the specific state page we would see the divisions terms. And when you click the division you see all post from that tterm. We have a custom template for the taxonomy but want to limit how many template pages we need to create. If we go with categories than we have to make a custom template for every town/division. Any suggestions on best logic for this making it easy to use on front end without losing admin organization. We set up category hiearcy but we're looking for a better way because we need to allow for user to fill out form and populate post. At this point we have decided to use categories unless someone has another option. Categories just feel sloppy on admin side with children. Thanks for your time.
I'm not sure I understand the question, and thus am not sure I'm on the right track with this answer.
I think you're looking for towns/divisions to have content that can be customized by users. There may be a more WP specific way to do this, but a simple way would be to have a db table with these elements associated with the post id, for example post_id, town_desc, town_mascot, etc. Then, in the WP template, run a query to see if custom elements exist. If not, echo some default text, otherwise echo the custom element text from the db. I think I'd also have the default text be different based upon the level, i.e. with states, divisions, and towns all different based on their level.
Your answer might lie in simply working with custom fields, perhaps with
https://wordpress.org/support/article/custom-fields/
Good day,
I need some advice if this is possible on wordpress? I have a classified site and I want to create a newsletter that would have multiple categories each category would just have a list of title that has links to the item page.
The hard part is I need a check box on the registration and user profile page that will enable them to select which category they want on their newsletter and uncheck which one they don’t need. The reason for this is the list on each category can be too many and users might not want to see listing about ex. community or announcement etc.
Another feature that I need is for paid listing to stay on the newsletter for the duration of its package and for free listing to only show the day it was posted even though it has 5 days to stay on the site
I am open to use any options like mailchimp, awebber etc. as long as it works
Ex.
Hot Deal <-Category
1.) New Arrival comfort footwear
Forsale <-Category
1.) Xbox one fresh inbox
2.) Ps4 brand new
Many thanks
There is a plugin
which will help you to make users subscribing to category.
That plugin lets a user subscribe and unsubscribe to posts within a certain category or categories.
Subscribers will recieve an e-mail with a link to the actual post.
And the post type may be anything like product or news etc ;)
But you may endup doing some customize coding to get what exactly you are looking for.
I'm putting together my own Wordpress theme for a very specific set of client requirements. I'm fine with front-end theme work, but I need some help with back end.
The task is kind of like a support site, with lots of Q and A's. I'm building a support site for a company, which means most Pages will be populated with many questions and associated answers.
The page Structure would be something like this:
Home Page (with links to Most recent Q+As added) and common sections
-How to use the app (10-20 Q+As on page)
-How to manage integrations (10-20 Q+As on page)
-Other page (10-20 Q+As on page)
-5-10x 'Other pages'
About Us
Contact Support
Requirements and my comments
-Each Q and A does not have it's own URL
This makes using Posts for Q and A's unattractive.
-Each Page is made up of a Table of Contents which allows quick scrolling to questions
An ideal solution would be some code on the page theme template which grabs each "Q and A" object within a certain category/section/identifier and load it to the page
-New questions and answers can quickly and easily be added
The ideal solution for support reps is that they can add a question and answer, and assign a category, rather than edit a huge page of questions.
-Order of Q and A's on page is important
Ideal solution should allow you to order the Q+As within their given category/section/other.
-On the home page, most recent Q+As added list exists
-Each Page of Q+As has a "last updated" date, which is the date the most recent Q+A was most recently modified.
Ideas I had
Posts or custom posts seemed like a good idea, but they create permalinks. But my "Pages" would actually be Category Archive pages. We don't want a Q+A to be be assigned two categories. Also, custom post ordering seems difficult. If we could suppress permalinks and ensure on category or section and find a way to order them - this could work.
FAQ Plugins
It seems like these all are a bit clunky and the amount of custom dev to re-skin on it might not be worth it, might be easier to do something totally custom.
Question:
does anyone have any ideas how this could be achieved?
The best thing is to use custom post types. Basically two custom post types, question and answer. Then each question can have categories tags and so on. Answers can have a custom field with question ID so you can easily get all the answers by question ID. If you need then not to have unique url, than create two files: single-question.php and single-answer.php and put 404 page code there so if user will get to the url of a single question or answer than he will see 404 error :)
On my website I have all kinds of products (gift ideas) and want to make them easier accessible for visitors.
The plan is to build a page called 'present finder', where you can select a price range, the persons age (kid, teenie or grownup) and tags referring to their interests (e.g. Design, Nature, Travel, Sports).
It should look something like this:
Link to how it should look
I doubt I would have any trouble building the GUI, or tagging all my posts but:
Question:
How do I make it work that as soon as options are changed (like tags
or price range), the right posts are being displayed underneath
instantly? I don't want to be forced to install a 'search' button and I dont want the page to reload every time the user adds a
tag or changes the price range.
Is there maybe a plugin that does exactly what I need so I don't have to build it from scratch?
I researched for over 40 min and couldn't find anything.
Thanks a lot for your help. Cheers!
Example page: http://giantcalculator.com/content/cartridge-filters
It’s very cumbersome to connect the ubercart view to a relevant content page. In the example above I have attached the view to the bottom; you can scroll down to see it. It is a tedius process though in which I have to create the view, then create a mini panel, include the view in the mini panel, then go to blocks page and add the mini panel to region (currently a region below the main content), then I have to configure the block so the view only appears on it’s one particular page.
This seems far too complicated and the particular region will soon have about 20 blocks inside it, though each only appearing on one page. Is there a better way to attach a view to its relevant content info, or vice versa?
I know the view creates a page of its own, and if I could add the content on top of the view that would be great. Or within the view itself, can the content be added somehow?
I'm almost ready to move forward with this site but I really need to find if there is a better method first. I'm posting this in a number of places and offering a $20 bounty via paypal to the first responder with best alternative that I end up using. (if there is one). Bounty may be shared if two or more people have the same response on different forums and I can't tell who was first, though when I do have an answer I'll promptly post it.
Other forums this will post include Drupal.org paid forum, Ubercart Bounty forum, aardvark, superuser and stackoverflow.
If I understand correctly, I think the piece of the puzzle you're missing is Views arguments. If you ever find yourself creating more than one view, where the only difference is the content (ie. based on taxonomy, or a certain CCK field), you probably want to use that as an argument in the view so it loads the correct content automatically.
I assume "cartridge filters" is a taxonomy term, and the page linked above is a node with this term applied. So you'd add a taxonomy arg to your view in the Views admin, and get it to pull the term from the current node. There are a bunch of tutorials out there on this, and here's a screencast: http://gotdrupal.com/videos/drupal-views-arguments
I'm also not sure why you're using mini panels. They're generally used for sets of blocks or other content to be displayed repeatedly, like a tabbed block or footer. It sounds like you just want a regular block display of the aforementioned view. You could also make this entire page a Panel.