01-04-2019, 10:22 AM
Absolutely. Happy to help. If any of it doesn't make sense, let me know. I can help with the sign up or whatever you need.
The following warnings occurred: | ||||||||||||
Warning [2] Undefined variable $unreadreports - Line: 26 - File: global.php(961) : eval()'d code PHP 8.2.25 (Linux)
|
Retrieving data from database
|
01-04-2019, 10:22 AM
Absolutely. Happy to help. If any of it doesn't make sense, let me know. I can help with the sign up or whatever you need.
01-04-2019, 10:39 AM
(01-04-2019, 10:22 AM)mudmin Wrote: Absolutely. Happy to help. If any of it doesn't make sense, let me know. I can help with the sign up or whatever you need. How would I go about it to get it like this: Monday: 4 Tuesday: 6 Wednesday: .. Thursday: .. Friday: .. Saturday: .. Sunday: .. Is there a line of code that i can just paste anywhere?
01-04-2019, 10:42 AM
Sure. Get rid of the entire table from <table to /table and paste this
https://pastebin.com/n0v0hQTC
01-04-2019, 10:44 AM
Wow! So simple...geeze
I'll definitely get back to you for that sign up, but I'm going to try it by myself first. Thanks again mudmin!
01-04-2019, 10:45 AM
Sure. No problem at all. And that's definitely the benefit of defining the days and writing that function. Once you have it, you can really do whatever you want with it.
Hello Mudmin,
Would it be possible to drop the weekday and just display the number of that particular weekday somewhere? Like...hide the weekday or something? I would like to display the number of spots available in a table. Something like this: Day | Time | Activity | Spots available Wednesday | 19:00 | yoga | 3 Friday | 10:00 | yoga | 5
01-10-2019, 09:23 AM
Let me see if I can help you a little better.
When I see that table, you're going from Wed to Friday. Are you saying that you want to only show days that have availability? So Thursday has no days available, so it's skipped? Also, do you expect to have multiple activities?
01-10-2019, 09:43 AM
no no, this was just a quick example.
It should be all days of the week...showing availability of each weekday. And yes, there will be several activities (Eventually). I will have to add extra columns to the users table for that. What would be great if I could just echo the availability numbers of any particular event anywhere i want
01-10-2019, 09:58 AM
Ok. So the way you're doing it will make it a little trickier to be more dynamic. Like what if you don't want to offer any dodgeball on Sundays or something like that? Do you want help making it dynamic?
01-10-2019, 09:59 AM
|